简体   繁体   English

INSERT失败,因为以下SET选项的设置不正确:“ ARITHABORT”。

[英]INSERT failed because the following SET options have incorrect settings: 'ARITHABORT'.

I have an .net application and SQL Server 2005 in the back-end. 我在后端有一个.net应用程序和SQL Server 2005。 I have created the xml string for the bulk insert and passing that xml string to the SP. 我已经为批量插入创建了xml字符串,并将该xml字符串传递给SP。 That xml string is being converted to the table type Table in the SP with IDENTITY column. 该xml字符串将被转换为带有IDENTITY的SP中的表类型Table。 As soon as I run the code I get the following error 一旦运行代码,我将收到以下错误

INSERT failed because the following SET options have incorrect settings: 'ARITHABORT'. INSERT失败,因为以下SET选项的设置不正确:“ ARITHABORT”。 Verify that SET options are correct for use with indexed views and/or indexes on computed columns and/or query notifications and/or xml data type methods. 验证SET选项正确用于计算列的索引视图和/或索引和/或查询通知和/或xml数据类型方法。

But if I run the direct SP with the same parameters then it is working fine. 但是,如果我使用相同的参数运行直接SP,则可以正常工作。 Any idea? 任何想法?

在尝试执行命令之前,尝试将算术回合中止设置为关闭

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 UPDATE失败,因为以下SET选项的设置不正确:'ARITHABORT' - UPDATE failed because the following SET options have incorrect settings: 'ARITHABORT' 由于以下SET选项的设置不正确,导致由于INSERT而出错 - Getting Error as INSERT failed because the following SET options have incorrect settings 如何在Linq中为实体设置Arithabort? - How to set Arithabort on in Linq to Entities? 在存储过程中使用 SET ARITHABORT ON - Use SET ARITHABORT ON in stored procedure 无法打开文件,因为打开选项不正确 - cannot open the file because the open options are incorrect 如何使SqlConnection默认使用“SET ARITHABORT ON”? - How to make SqlConnection to use “SET ARITHABORT ON” by default? 为什么Linq查询将我的Arithabort选项设置为false? - Why is Linq query setting my Arithabort options to false? 并排配置不正确,导致应用程序启动失败 - application has failed to start because the side by side configauration is incorrect 应用程序无法启动,因为其并行配置不正确 - Application failed to start because its side-by-side configuration is incorrect 将数据插入两个表失败,因为违反了FK - INSERT data into two tables failed because FK violation
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM