Site Sponsored By: SQLDSC - SQL Server Desired State Configuration
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.
I want to turn on ansi_null so I won't get records with nullin the results. The query : SET ANSI_NULLS ONGOselect [ProductID], [Color]from [Production].[Product]WHERE [Color] IS NULLGOThe results:ProductID Color1 NULLand I still get records with null in the results ..What is wrong?
tkizer
Almighty SQL Goddess
38200 Posts
Posted - 2015-04-10 : 17:21:37
WHERE Color IS NOT NULLOr maybe I'm not understanding what you want.Tara KizerSQL Server MVP since 2007http://weblogs.sqlteam.com/tarad/
Sh12345
Starting Member
4 Posts
Posted - 2015-04-11 : 04:54:36
I have an example of another query with ansi_nulls:http://xpode.com/ShowArticle.aspx?ArticleId=599in this example the ansi_nulls are on and it returns 0 for all the records where the value is null...In my query i did the same - I turned on the ansi_nullsand I have "color" column where I have null values . And I still didnt get 0 , I got records with nulls..So.. dont know what...is wrongtnx for the response