distributed - SQL Server 2005 Linked Server Query Does Not Return Expected Error -


i querying linked sql server , not getting error when querying locally.

something this:

select cast(columnname int) tablename

and this:

select cast(columnname int) servername.databasename.schema.tablename

the first query when run locally returns error 'arithmetic overflow error converting expression data type int.' because values out of range.

however, second query running different server, returns 'valid' rows.

i expect working designed, have googled , cannot find anywhere explains difference in behaviour when querying locally versus distributed. can point me in right direction? i'd know if there configuration option change this.

thanks in advance.

look @ set arithabort , set ansi_warnings options. when both off, overflow error suppressed , null returned instead. can set in (at least) 3 different places: connection, database or code. means can unexpected behaviour because set database option , forgot it, or using connection library sets options differently default. more information here:

http://msdn.microsoft.com/en-us/library/ms191203(v=sql.90).aspx


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -