Urgent Help Please!!!

Results 1 to 2 of 2

Thread: Urgent Help Please!!!

  1. #1
    Web Enthusiast Guest

    Default Urgent Help Please!!!

    Hi, i have a problem. I have an ASP page that basically takes the user-selected criteria from a form and displays the results after querying the database. The query does a join on some tables which have a couple of million records. The problem is that when hit the "Run Query" button on the form, the CPU usage is jumping up to around "90 - 100%". After the query returns the results, the usage goes back to the normal of around 15%. I really need to fix this problem because it is our production box and it is important that the performance is smooth. Could any body please suggest the possible causes and remedies at the earliest? Beyond making sure that all the database connections that have been opened, are closed, is there anything that i can control in the program.

  2. #2
    SPG Guest

    Default Alternate syntaxes?

    I don&#039t know if this will help you at all, but what if you altered your syntax a bit (which you didn&#039t include, so I&#039m guessing that you wrote it the easy and conventional way, as opposed to something like:<BR><BR>select a.col1, b.col2, c.col3<BR>from<BR>(alpha as a inner join<BR>(beta as b inner join<BR>(gamma as c inner join where c.criteria = &#039" & userCriteria & "&#039)<BR>on b.hook = c.hook where b.criteria = &#039" & userCriteria2 & "&#039)<BR>on a.hook = b.hook)<BR><BR>such that you&#039re removing records before the database does it&#039s massive join instead of after. Hopefully, anyway.<BR><BR>Additionally, you&#039ll want to increase your .cacheSize (there was an article recently...) and push your returned recordSet into an array with .getRows (there should be an article, even if there isn&#039t yet...) -- that will help on the post-select side of things, even if the SQL syntax ultimately doesn&#039t matter very much.<BR><BR>HiH.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts