Sample Header Ad - 728x90

Make SqlClient default to ARITHABORT ON

39 votes
6 answers
37412 views
First things first: I'm using MS SQL Server 2008 with a database at compatibility level 80, and connecting to it with .Net's System.Data.SqlClient.SqlConnection. For performance reasons I've created an indexed view. As a result, updates to tables referenced in the view need to be done with ARITHABORT ON. However, the profiler shows that SqlClient is connecting with ARITHABORT OFF, so updates to those tables are failing. Is there a central configuration setting to make SqlClient use ARITHABORT ON? The best I've been able to find is to manually execute that each time a connection is opened, but updating the existing code base to do this would be a fairly large task so I'm keen to find a better way.
Asked by Peter Taylor (531 rep)
May 3, 2011, 04:17 PM
Last activity: Feb 2, 2023, 08:14 AM