Page is a not externally linkable
- Code, Content, and Presentation
-- Databases
---- querying several million records


LifeinAsia - 3:22 pm on Aug 23, 2006 (gmt 0)


Do you have your tables indexed? Have you re-indexed the tabels recently? What data type are the IDs? Are you pulling out just the fields you need or are you doing a "SELECT *" and pulling out a lot of data you don't need?

Have you confirmed that it's the actual query taking so long or might it be the processing of the ASP page as well? Depending on exactly what you're doing, it might also make sense to move the query from ASP into a stored procedure.

Another thought- does your DB server have enough memory/processing power? And are you using separate servers for your web server & SQL 2000?

[edited by: LifeinAsia at 3:24 pm (utc) on Aug. 23, 2006]


Thread source:: http://www.webmasterworld.com/databases_sql_mysql/3057237.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com