This question already has an answer here:
We have an application which we recently upgraded and is having bad performance issues. Any ideas would be much appreciated.
The main issue is windows taking ages (minutes) to open because the initial query to fill their list boxes is taking so long. The second time a user opens the window its fine.
We would expect this to be application cacheing but we don't think so. We see similar problems using Crystal Reports and using command line SQL queries.
We have increased the RAM available to the database.
Another part of our business has a slightly different version of the same application and database and doesn't get this problem.
The time to complete a query can be 30 minutes for the first time in a session and 30 seconds for subsequent executions.