How to Increasing the Command Timeout in CodingHorror("my sql query").Execute();

396 Views Asked by At

I am trying to create a database backup and using CodingHorror to execute my command as below. CodingHorror("my sql query").Execute();

My database size is big and it takes about 2 minutes to complete the backup process when I executed my command in MSSQL. But while executing in my C# application, exception is thrown as below Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.

Is there any way to increase command timeout in Subsonic CodingHorror ?

1

There are 1 best solutions below

1
Mike Walsh On

CodingHorror uses the normal DataProvider so it should just use the timeout you've set in the connection string q.v. Timeout setting for SQL Server