Coupon code copied
Server Intellect
(855) 850-HOST

Toll Free 24/7/365        (4678)

Get help from a Microsoft Certified Engineer.

Intellect Connect

Technical problem with your Windows Hosting?

Let our Microsoft Certified experts handle the problem for you.

How do I Increase the Timeout Value in SQL?

There are two places where you can specify Timeout settings in SQL. One being during the actual initialization of the connection string, called “ConnectionTimeout“. This will effect any query made under this database connection string. The other option would be to specify it during the actual query command, called “CommandTimeout“.


Where conn is an ADODB.Connection object that is not yet open, the connectionTimeout property will indicate the amount of time, in seconds, to wait for an ASP application to initially connect to the data source. The default is 15 seconds; to override the default, use syntax as follows:

Set conn = CreateObject("ADODB.Connection")
conn.<strong>ConnectionTimeout</strong> = 120
conn.Open <connectionString>

CommandTimeout tells the server how long to wait, in seconds, for completion of any command sent to the data source. This value is editable before and after the connection has been opened. The default is 30 seconds, but you can override it like this:

Set conn = CreateObject("ADODB.Connection")
conn.Open <connectionString>
conn.<strong>CommandTimeout</strong> = 120

Note that you can also apply a commandTimeout value to a command object, and it will behave independent of the commandTimeout value associated with the connection object. So for specific stored procedures or other commands being executed explicitly through the ADODB.Command object, you could have a longer timeout than that of the connection object. The syntax for the command object is almost identical:

Set cmd = CreateObject("ADODB.Command")
cmd.<strong>CommandTimeout</strong> = 120
Having Problems with Windows Server?

Try our troubleshooting service

  • Microsoft Certified Engineers
  • Remote Log-in to Your Servers
  • End-to-End Troubleshooting

Our Certified Technicians have been supporting Microsoft® products for well over a decade.

Tell us where you are getting stuck

Get Help Now!

Having Trouble Solving This Problem?

Let our Microsoft® Certified Engineers fix it for you.
Just $50.00 one time fee.

Having Trouble Implementing This Solution?

Why not let our Microsoft® Certified Engineers do it for you.
Just $50.00 one time fee.

Request Immediate Expert Help

Interested in letting our experts solve your IT problems for you?
Get a free, no-obligations consultation with one of our experts today!

Call us at (855) 850-HOST


Start Your Order


This form does not accept free e-mail accounts. Please enter a business e-mail to submit it.

Submit Form Cancel

Please wait...

Submitting your info. This may take less than a minute.