Click here to Skip to main content
15,886,919 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Dear all,

What is the usage of CommandTimeout in IDbCommand?

Thanks.

What I have tried:

IDbCommand cmd = DataContext.Database.Connection.CreateCommand();
cmd.CommandText = storedProcedure;
cmd.CommandType = CommandType.StoredProcedure;
cmd.CommandTimeout = 0;
cmd.ExecuteNonQuery();
Posted
Updated 18-Sep-16 18:57pm
v3

What's issue in searching that in google.com or bing.com?
Here are few documentations regarding this-
IDbCommand.CommandTimeout Property (System.Data)[^]
SqlCommand.CommandTimeout Property (System.Data.SqlClient)[^]

Please let me know if there still some questions.
Thanks :)
 
Share this answer
 
Comments
Member 11919589 19-Sep-16 1:14am    
Thanks.
Quote:
The time (in seconds) to wait for the command to execute. The default value is 30 seconds.


IDbCommand.CommandTimeout Property (System.Data)[^]
 
Share this answer
 
Comments
Member 11919589 19-Sep-16 1:14am    
Thanks.
Karthik_Mahalingam 19-Sep-16 1:15am    
welcome

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900