当 IDENTITY_INSERT 设置为 OFF 时,不能为表 'Leavewords' 中的标识列插入显式值。
说明:执行当前Web请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。异常详细信息:System.Data.SqlCli...
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.Data.SqlClient.SqlException: 当 IDENTITY_INSERT 设置为 OFF 时,不能为表 'Leavewords' 中的标识列插入显式值。
源错误:
行 566: catch (System.Data.SqlClient.SqlException e)
行 567: {
行 568: throw e;
行 569: }
行 570: }
源文件: D:\graduation\CodematicDemo_graduation\DBUtility\DbHelperSQL.cs 行: 568
堆栈跟踪:
[SqlException (0x80131904): 当 IDENTITY_INSERT 设置为 OFF 时,不能为表 'Leavewords' 中的标识列插入显式值。]
Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(String SQLString, SqlParameter[] cmdParms) in D:\graduation\CodematicDemo_graduation\DBUtility\DbHelperSQL.cs:568
Maticsoft.DAL.Leavewords.Add(Leavewords model) in D:\graduation\CodematicDemo_graduation\DAL\Leavewords.cs:61
Maticsoft.BLL.Leavewords.Add(Leavewords model) in D:\graduation\CodematicDemo_graduation\BLL\Leavewords.cs:39
Maticsoft.Web.Leaveword.Leaveword.SureBtn_Click(Object sender, EventArgs e) in D:\graduation\CodematicDemo_graduation\Web\Leaveword\Leaveword.aspx.cs:49
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565 展开
异常详细信息: System.Data.SqlClient.SqlException: 当 IDENTITY_INSERT 设置为 OFF 时,不能为表 'Leavewords' 中的标识列插入显式值。
源错误:
行 566: catch (System.Data.SqlClient.SqlException e)
行 567: {
行 568: throw e;
行 569: }
行 570: }
源文件: D:\graduation\CodematicDemo_graduation\DBUtility\DbHelperSQL.cs 行: 568
堆栈跟踪:
[SqlException (0x80131904): 当 IDENTITY_INSERT 设置为 OFF 时,不能为表 'Leavewords' 中的标识列插入显式值。]
Maticsoft.DBUtility.DbHelperSQL.ExecuteSql(String SQLString, SqlParameter[] cmdParms) in D:\graduation\CodematicDemo_graduation\DBUtility\DbHelperSQL.cs:568
Maticsoft.DAL.Leavewords.Add(Leavewords model) in D:\graduation\CodematicDemo_graduation\DAL\Leavewords.cs:61
Maticsoft.BLL.Leavewords.Add(Leavewords model) in D:\graduation\CodematicDemo_graduation\BLL\Leavewords.cs:39
Maticsoft.Web.Leaveword.Leaveword.SureBtn_Click(Object sender, EventArgs e) in D:\graduation\CodematicDemo_graduation\Web\Leaveword\Leaveword.aspx.cs:49
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询