in reply to Alternative for multiple while loops to improve performance

SQL GROUP BY and HAVING clauses can help summarize and filter data significantly faster than running multiple queries in a while loop.

Also - LanX's suggestion of having appropriate INDEXes should improve performance.

SQL help would be off-topic for this forum, so I'm resisting requesting schema information, and a better problem description.

                As a computer, I find your faith in technology amusing.

  • Comment on Re: Alternative for multiple while loops to improve performance