执行存储过程时出错,超时时间快到!
c#+SQL SERVER开发的系统,这前运行正常,最近出现如下错误:
[Exception: 执行存储过程时出错!
错误信息:
超时时间已到。在操作完成之前超时时间已过或服务器未响应。]
域名.DbServices.SqlDbService.ExecuteProcedureTable(String ProcedureName, DbParams Params)
域名.DbServices.DbService.ExecuteProcedureTable(String ProcedureName, DbParams Params)
数据库名.Common.File.WebFile.MakePhotoHtml(Int32 iPhotoID, String strAction, Boolean bIsRemakeAll)
数据库名.SystemAdmin.Photos.EditPhotos.LinkButtonCheckSelect_Click(Object sender, EventArgs e)
System.Web.UI.WebControls.LinkButton.OnClick(EventArgs e) +108
System.Web.UI.WebControls.LinkButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +138
System.Web.UI.Page.ProcessRequestMain() +1292
请问有人遇到过这样的问题吗? 不知是程序出错还是数据库系统问题?求助高手指点!!!!!
存储过程语句如下:
CREATE PROCEDURE dbo.ite_UpdateObjectState
(
@ObjectID int,
@StateName varchar(10),
@StateValue bit,
@ObjectType varchar(10)
)
AS
DECLARE @OriginalStateValue bit
DECLARE @NowStateValue bit
IF @ObjectType = 'Article '
BEGIN
IF @StateName = 'Check '
UPDATE Articles
SET IsCheck = @StateValue
WHERE ArticleID = @ObjectID
IF @StateName = 'Hide '
UPDATE Articles
SET IsDelete = @StateValue
WHERE ArticleID = @ObjectID
IF @StateName = 'Top '
UPDATE Articles
SET IsTop = @StateValue
WHERE ArticleID = @ObjectID
IF @StateName = 'Good '
UPDATE Articles
SET IsGood = @StateValue
WHERE ArticleID = @ObjectID
END
ELSE
BEGIN
IF @StateName = 'Check '
UPDATE Photos
SET IsCheck = @StateValue
WHERE PhotoID = @ObjectID
IF @StateName = 'Hide '
UPDATE Photos
SET IsDelete = @StateValue
WHERE PhotoID = @ObjectID
IF @StateName = 'Good '
UPDATE Photos
SET IsGood = @StateValue
WHERE PhotoID = @ObjectID
END
RETURN
GO
------解决方案--------------------先确定存储过程执行是否正常 直接在后台执行试试 如果没问题 再检查你的前台脚本
------解决方案--------------------LZ应该是最近有改过 Web.config 的配置了,连接有问题
存储过程本身是没有问题的
------解决方案--------------------中断代码,把调用存储过程的语句调试出来,直接在查询分析器中执行,如果没有问题,就是你前台代码的问题。
------解决方案--------------------