Forum Moderators: open
We now appear to have hit the next "bottleneck" - Now IIS is working better, it seems that SQL Server is now the weak link ...
This is the error we get about once a day:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Driver's SQLAllocHandle on SQL_HANDLE_DBC failed
The piece of code where it is always happening is in an asp script run using server.execute in global.asa:
Set OBJdbConnection = Server.CreateObject("ADODB.Connection")
OBJdbConnection.Open "Driver={SQL Server};server=(local);database=master;uid=sa;pwd="
SQL ="SELECT * FROM Sites WITH (NOLOCK) WHERE Site = '"&session("site")&"'"
Set RSSite = OBJdbConnection.Execute(SQL)
we added "with (NOLOCK)" recently in the hope this would improve performance .. in fact we got the same error message before we added this ...
Anyone got any ideas as to how we might improve server stability?
Thanks for any insights ...
You might also want to explicitly name the fields you are calling in your SQL query, this will also speed things up.