Timeout after 6 hours (SqlCommand object)
From: Elyo Ravuna (msdn_at_nebim.com.tr)
Date: 03/01/04
- Next message: Sébastien: "'System.Data.EvaluateException' problem"
- Previous message: Miha Markic [MVP C#]: "Re: OleDbDataAdapter.Update and DBase IV"
- Next in thread: Kevin Yu [MSFT]: "RE: Timeout after 6 hours (SqlCommand object)"
- Reply: Kevin Yu [MSFT]: "RE: Timeout after 6 hours (SqlCommand object)"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 1 Mar 2004 07:26:08 -0800
I set SqlCommand.CommandTimeout to 24 hours. However I get a timeout after about 5-6 hours.
Dim SqlConnection As New SqlConnection("data source=.;Integrated security=sspi")
Dim SqlCommand As New SqlCommand("waitfor delay '10:0:0'", SqlConnection)
SqlConnection.Open()
SqlCommand.CommandTimeout = 3600 * 24
SqlCommand.ExecuteNonQuery() 'Throws an exception after about 6 hours.
The exact error message is:
"Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding."
It seems that something like approximately 6 hours is hard-coded somewhere, or it is the default value of something. How can I run a stored procedure that takes more than 6 hours to complete?
I would be very glad to hear a response from Microsoft.
Sincerely.
Elyo Ravuna
- Next message: Sébastien: "'System.Data.EvaluateException' problem"
- Previous message: Miha Markic [MVP C#]: "Re: OleDbDataAdapter.Update and DBase IV"
- Next in thread: Kevin Yu [MSFT]: "RE: Timeout after 6 hours (SqlCommand object)"
- Reply: Kevin Yu [MSFT]: "RE: Timeout after 6 hours (SqlCommand object)"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|