Solving a timeout error for SQL query

后端 未结 5 2037
星月不相逢
星月不相逢 2020-12-16 20:52

I am getting this error:

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

5条回答
  •  -上瘾入骨i
    2020-12-16 21:46

    SqlDataAdapter adp = new SqlDataAdapter();
    adp.SelectCommand.CommandTimeout = 0;  // Set the Time out on the Command Object
    

提交回复
热议问题