Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 concat null yields null

Author  Topic 

odonnellt
Starting Member

4 Posts

Posted - 2004-06-03 : 09:06:54
I have turned this of using the following command:
exec sp_dboption 'wagggs','concat null yields null','false'
yet when i add a null value onto a non-null string it still returns null

is there any reason for this
when i use win-sql it works when i issue the following command:
set CONCAT_NULL_YIELDS_NULL off
but for some reason i can't use this in the application that i am running the queries from.

any ideas??

AndrewMurphy
Master Smack Fu Yak Hacker

2916 Posts

Posted - 2004-06-03 : 11:17:01
show us a code sample....with sample input data and (matching) expected + actual results.
your problem description is too terse to be easy to figure out what is wrong.
Go to Top of Page

acollins74
Yak Posting Veteran

82 Posts

Posted - 2004-06-03 : 11:23:45
I don't have an answer as to why but can offer a suggestion.
I always use the ISNULL(check_expression,replacement_value) whenever concat is being used b/c of being burned in the past.

Go to Top of Page

Naveen Vaila
Starting Member

1 Post

Posted - 2004-06-17 : 08:38:29
Thanks acollins74. I Rcently got the problem related to
Average the records and Concatinating the string. And your reply did a splendid job.
-------------------------------------------------
quote:
Originally posted by acollins74

I don't have an answer as to why but can offer a suggestion.
I always use the ISNULL(check_expression,replacement_value) whenever concat is being used b/c of being burned in the past.



Go to Top of Page
   

- Advertisement -