Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. The statement has been terminated

后端 未结 20 2194
臣服心动
臣服心动 2020-11-22 10:23

I have many users on my web site (20000-60000 per day), which is a download site for mobile files. I have remote access to my server (windows server 2008-R2).
I\'ve

20条回答
  •  隐瞒了意图╮
    2020-11-22 10:48

    In your code where you run the stored procedure you should have something like this:

    SqlCommand c = new SqlCommand(...)
    //...
    

    Add such a line of code:

    c.CommandTimeout = 0;
    

    This will wait as much time as needed for the operation to complete.

提交回复
热议问题