Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Can you change command timeout via the connection?

Author  Topic 

ZLA
Starting Member

6 Posts

Posted - 2007-12-21 : 13:41:19
I know that connecttimeout and commandtimeout are separate entities. Is it possible to change the default command timeout value by changing the connection string?

I need to increase the command timeout and want to know if I can do it without changing my code and rebuilding my ASP.NET 1.1 web app.

Thanks in advance. -- ZLA

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2007-12-21 : 16:42:31
no. i learned that the hard way
http://weblogs.sqlteam.com/mladenp/archive/2007/01/31/60079.aspx

_______________________________________________
Causing trouble since 1980
blog: http://weblogs.sqlteam.com/mladenp
SSMS Add-in that does a few things: www.ssmstoolspack.com <- new version out
Go to Top of Page

ZLA
Starting Member

6 Posts

Posted - 2007-12-21 : 17:26:57
Thank you. I'll have to modify the code rather than just modify the web config value.
Go to Top of Page

jezemine
Master Smack Fu Yak Hacker

2886 Posts

Posted - 2007-12-21 : 17:51:24
while you are modifying the code, you might as well put the timeout value in web.config and have your pages read it from there so you don't hit this again...




elsasoft.org
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2007-12-21 : 22:56:33
While you are modifying code, check to see if your queries can be optimized. We've got one system that demands that queries take less than 2 seconds and we aren't talking about a small database. Increasing the command timeout is not an option for us but rather we've got to continuously keep up with performance tuning and optimizations.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/
Go to Top of Page
   

- Advertisement -