Incorrect ARITHABORT

  • I have defined an indexed view on a table and all the server side code is working fine. But when I want to insert, update or delete a record from VB via an ADO recoredset I get an error which says  ARITHABORT option has incorrect setting. What's wrong and how can I solve it?

  • Check the SQL connection settings. To run an insert/update/delete on the table ArithAbort must be set to ON. By default I believe that this is set to off, to change it you can either go through enterprise manager, right click, properties, connections and check the Arithmetic Abort checkbox, or as I prefer go through QA and run..

    USE MASTER

    GO

    EXEC SP_CONFIGURE 'show advanced options', 1

    RECONFIGURE

    EXEC SP_CONFIGURE 'user options', 64

    RECONFIGURE WITH OVERRIDE

    EXEC SP_CONFIGURE 'show advanced options', 0

    RECONFIGURE



    Shamless self promotion - read my blog http://sirsql.net

  • Thanks so much. It worked fine. Is there a way to set arithabort on per connection in VB if I dont want to change server settings?

  • You could run SET ARITHABORT ON before executing the statement. It's best to change it serverwide however as otherwise you will have to manually set this for every object that touches that view.



    Shamless self promotion - read my blog http://sirsql.net

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply