Post by g***@pixelglow.comDatabaseA -- database default: ARITHABORT on
DatabaseB -- database default: ARITHABORT off
Make an OLEDB connection to DatabaseA. Then do a SELECT * FROM
DatabaseB.dbo.TableB. Does this now use ARITHABORT ON also?
The effective connection setting is inherited from the current default
database context (DatabaseA). Consequently, ARITHABORT is ON for this
query.
The rules for SET option precedence are listed in the Books Online
<createdb.chm::/cm_8_des_05_1ng3.htm>. In summary:
- explicit SET by application
- connection string specification
- ODBC DSN setting
- provider default setting
- database default setting
- server default setting
Post by g***@pixelglow.comMy difficulty is I'm using SQLXML and mostly XPath queries. I can set
ARITHABORT on using a SQL query but it will be invoked on each template
call, I'd rather set it once and for all in the connection which
hopefully will be pooled.
Another option is to specify ARITHABORT ON as the server default. This way,
ARITHABORT ON will be used set off at a higher level. You can use
sp_configure to specify ARITHABORT ON by turning on 'user options' bit 64.
--
Hope this helps.
Dan Guzman
SQL Server MVP
Post by g***@pixelglow.comPost by Dan GuzmanI don't believe there's a way to specify ARITHABORT ON in the
connection
Post by Dan Guzmanstring. However, you can turn this on as the database level default
with
Post by Dan GuzmanALTER DATABASE. You can also specify ARITHABORT ON at the server
level via
Post by Dan Guzmanthe 'user options' sp_configuration parameter.
The confusing thing for me is, isn't ARITHABORT a connection setting?
DatabaseA -- database default: ARITHABORT on
DatabaseB -- database default: ARITHABORT off
Make an OLEDB connection to DatabaseA. Then do a SELECT * FROM
DatabaseB.dbo.TableB. Does this now use ARITHABORT ON also?
My difficulty is I'm using SQLXML and mostly XPath queries. I can set
ARITHABORT on using a SQL query but it will be invoked on each template
call, I'd rather set it once and for all in the connection which
hopefully will be pooled.
Cheers,
Glen Low, Pixelglow Software
www.pixelglow.com