Thursday, February 9, 2012

asp.net 2.0 data base connection problem.....

we have Sql Server 2000 and Sql Server 2005 IN A SINGLE MACHINE.

when connecting with data base Sql Server 2000 with asp.net 2.0 application ,an error occur

"Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding."

can anyone suggest any idea to solve this problem...

thanking u.

Hi niladrisekharghosh,

Execute your query in your in Query Analyzer to see how long it takes.The default sql connection timeout is 30s so if it takes more than 30s to finish your query you have reset the timeout(or you have to optimize your query):

myCommand.CommandTimeout = 180 (more than 30s)

Hope it helps.

|||

You can increate the query timeout, on the connection there is a property called Timeout =

No comments:

Post a Comment