Http connecton超时 [英] Http connecton Time out
本文介绍了Http connecton超时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
嗨
我已经为兴趣计算创建了存储过程,并且在从c#asp.net执行该查询时超时消息在30秒内出现,但是当我执行该存储过程时,花了2分钟来计算如何解决这个问题?
我没有设置连接超时..
Hi
I have created the store procedure for interest calculation and while executing that query from c# asp.net the time out message came on 30 seconds, but when i execute that store procedure it took 2 minutes to calculate how to solve this problem ?
I have not set the connection time out ..
推荐答案
尝试增加命令timout值。
Try increasing command timout value.
SqlCommand cmd = new SqlCommand()
cmd.CommandTimeout = 240;//seconds
还要检查是否可以在存储过程级别进行优化。
希望,它有助于:)
Also check if optimization can be done in the stored proc level.
Hope, it helps :)
这篇关于Http connecton超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文