<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: SQL SERVER &#8211; QUOTED_IDENTIFIER ON/OFF and ANSI_NULL ON/OFF Explanation</title>
	<atom:link href="http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/</link>
	<description>Notes of a SQL Server MVP and Database Administrator</description>
	<lastBuildDate>Sat, 21 Nov 2009 05:54:09 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: gemini twin</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-56427</link>
		<dc:creator>gemini twin</dc:creator>
		<pubDate>Mon, 05 Oct 2009 09:41:27 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-56427</guid>
		<description>SQL SERVER – QUOTED_IDENTIFIER ON/OFF and ANSI_NULL ON/OFF Explanation: 

i am using SQL server 2005 
in affect to what is said about ANSI NULL ON   and 
QUOTED IDENTIFIER ON,
I do not get NULL if i place empty records in tables
instead only an empty space appears

please givme more details  on these</description>
		<content:encoded><![CDATA[<p>SQL SERVER – QUOTED_IDENTIFIER ON/OFF and ANSI_NULL ON/OFF Explanation: </p>
<p>i am using SQL server 2005<br />
in affect to what is said about ANSI NULL ON   and<br />
QUOTED IDENTIFIER ON,<br />
I do not get NULL if i place empty records in tables<br />
instead only an empty space appears</p>
<p>please givme more details  on these</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: SQL SERVER - 2008 - Interview Questions and Answers - Part 4 Journey to SQL Authority with Pinal Dave</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-47467</link>
		<dc:creator>SQL SERVER - 2008 - Interview Questions and Answers - Part 4 Journey to SQL Authority with Pinal Dave</dc:creator>
		<pubDate>Thu, 26 Feb 2009 12:02:51 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-47467</guid>
		<description>[...] When SET QUOTED_IDENTIFIER is ON, identifiers can be delimited by double quotation marks, and literals must be delimited by single quotation marks. When SET QUOTED_IDENTIFIER is OFF, identifiers cannot be quoted and must follow all Transact-SQL rules for identifiers. (Read More Here) [...]</description>
		<content:encoded><![CDATA[<p>[...] When SET QUOTED_IDENTIFIER is ON, identifiers can be delimited by double quotation marks, and literals must be delimited by single quotation marks. When SET QUOTED_IDENTIFIER is OFF, identifiers cannot be quoted and must follow all Transact-SQL rules for identifiers. (Read More Here) [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: SQLAuthority News - Best Articles on SQLAuthority.com Journey to SQL Authority with Pinal Dave</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-47184</link>
		<dc:creator>SQLAuthority News - Best Articles on SQLAuthority.com Journey to SQL Authority with Pinal Dave</dc:creator>
		<pubDate>Tue, 24 Feb 2009 12:06:51 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-47184</guid>
		<description>[...] SQL SERVER - QUOTED_IDENTIFIER ON/OFF and ANSI_NULL ON/OFF Explanation [...]</description>
		<content:encoded><![CDATA[<p>[...] SQL SERVER &#8211; QUOTED_IDENTIFIER ON/OFF and ANSI_NULL ON/OFF Explanation [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jyothi P</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-42864</link>
		<dc:creator>Jyothi P</dc:creator>
		<pubDate>Tue, 16 Sep 2008 19:51:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-42864</guid>
		<description>When SET ANSI_NULLS is ON, all comparisons against a null value evaluate to UNKNOWN. (FALSE)
When SET ANSI_NULLS is OFF, comparisons of all data against a null value evaluate to TRUE if the data value is NULL
 When SET ANSI_NULLS is ON, 

a SELECT statement using WHERE Emp_Name= NULL returns zero rows even if there are null values in Emp_Name.

 A SELECT statement using WHERE Emp_Name NULL returns zero rows even if there are nonnull values in Emp_Name.

When SET ANSI_NULLS is OFF, the Equals (=) and Not Equal To () comparison operators do not follow the SQL-92 standard. 

A SELECT statement using WHERE Emp_Name= NULL returns the rows with null values Emp_Name. 

A SELECT statement using WHERE Emp_Name NULL returns the rows with nonnull values in the column. 

SET ANSI_NULLS also must be ON  for executing distributed queries  and when creating or manipulating indexes on computed columns or indexed views.

 If SET ANSI_NULLS is OFF, CREATE, UPDATE, INSERT, and DELETE statements on tables with indexes on computed columns or indexed views will fail. SQL Server will return an error listing all SET options violating the required values.

When executing a SELECT statement, if SET ANSI_NULLS is OFF, SQL Server will ignore the index values on computed columns or views and resolve the select as though there were no such indexes on the tables or views.

If you want a script to work regardless of the ANSI NULSS database option or the setting of SET ANSI_NULLS, use IS NULL and IS NOT NULL in comparisons that may contain null values.</description>
		<content:encoded><![CDATA[<p>When SET ANSI_NULLS is ON, all comparisons against a null value evaluate to UNKNOWN. (FALSE)<br />
When SET ANSI_NULLS is OFF, comparisons of all data against a null value evaluate to TRUE if the data value is NULL<br />
 When SET ANSI_NULLS is ON, </p>
<p>a SELECT statement using WHERE Emp_Name= NULL returns zero rows even if there are null values in Emp_Name.</p>
<p> A SELECT statement using WHERE Emp_Name NULL returns zero rows even if there are nonnull values in Emp_Name.</p>
<p>When SET ANSI_NULLS is OFF, the Equals (=) and Not Equal To () comparison operators do not follow the SQL-92 standard. </p>
<p>A SELECT statement using WHERE Emp_Name= NULL returns the rows with null values Emp_Name. </p>
<p>A SELECT statement using WHERE Emp_Name NULL returns the rows with nonnull values in the column. </p>
<p>SET ANSI_NULLS also must be ON  for executing distributed queries  and when creating or manipulating indexes on computed columns or indexed views.</p>
<p> If SET ANSI_NULLS is OFF, CREATE, UPDATE, INSERT, and DELETE statements on tables with indexes on computed columns or indexed views will fail. SQL Server will return an error listing all SET options violating the required values.</p>
<p>When executing a SELECT statement, if SET ANSI_NULLS is OFF, SQL Server will ignore the index values on computed columns or views and resolve the select as though there were no such indexes on the tables or views.</p>
<p>If you want a script to work regardless of the ANSI NULSS database option or the setting of SET ANSI_NULLS, use IS NULL and IS NOT NULL in comparisons that may contain null values.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Harinath_hyd</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-33774</link>
		<dc:creator>Harinath_hyd</dc:creator>
		<pubDate>Fri, 15 Feb 2008 11:47:10 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-33774</guid>
		<description>Hi 
in a query set ansi_nulls on 
and select the null coulmn is gives null value
if set ansi_nulls off also behave same.
then how to  know diff between the ansi_nulls on and off
do mail to me.

Thank you</description>
		<content:encoded><![CDATA[<p>Hi<br />
in a query set ansi_nulls on<br />
and select the null coulmn is gives null value<br />
if set ansi_nulls off also behave same.<br />
then how to  know diff between the ansi_nulls on and off<br />
do mail to me.</p>
<p>Thank you</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Brian</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-18326</link>
		<dc:creator>Brian</dc:creator>
		<pubDate>Fri, 09 Nov 2007 16:11:11 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-18326</guid>
		<description>I&#039;m a SQL beginner, and this stuff drives me crazy. However, we&#039;ve using &quot;is null&quot; instead of &quot;= null&quot; and it seems to work regardless of the setting. Try this. This shows the difference between the two approaches:

set ansi_nulls on

declare @myTab table (id int null, [name] varchar(10) null)

insert into @myTab (id,[name]) values (1, &#039;sam&#039;)
insert into @myTab (id,[name]) values (2, &#039;dave&#039;)
insert into @myTab (id,[name]) values (3, null)

select * from @myTab
select * from @myTab where [name] is null
select * from @myTab where [name] = null</description>
		<content:encoded><![CDATA[<p>I&#8217;m a SQL beginner, and this stuff drives me crazy. However, we&#8217;ve using &#8220;is null&#8221; instead of &#8220;= null&#8221; and it seems to work regardless of the setting. Try this. This shows the difference between the two approaches:</p>
<p>set ansi_nulls on</p>
<p>declare @myTab table (id int null, [name] varchar(10) null)</p>
<p>insert into @myTab (id,[name]) values (1, &#8217;sam&#8217;)<br />
insert into @myTab (id,[name]) values (2, &#8216;dave&#8217;)<br />
insert into @myTab (id,[name]) values (3, null)</p>
<p>select * from @myTab<br />
select * from @myTab where [name] is null<br />
select * from @myTab where [name] = null</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Prashant Pandey</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-13045</link>
		<dc:creator>Prashant Pandey</dc:creator>
		<pubDate>Tue, 18 Sep 2007 00:37:06 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-13045</guid>
		<description>Got it... I have Created a table with fields Id and Name then i inserted many values in that table and also inserted a NULL value. in the Name field
Then When i am rnning below querry it not returns any record to me.
SET ANSI_NULLS ON
SELECT Name FROM MyTable(Nolock) WHERE Name=NULL

AND
When iam running below querry it returns the row with NULL value
SET ANSI_NULLS OFF
SELECT Name FROM MyTable(Nolock) WHERE Name=NULL

So, If in case of null when ANSI_NULLS is on Wht are the benefits of this i think this is wrong caz it does not return any row which having null. Why this is present in SQL any Specific reasons, Where we use this.????</description>
		<content:encoded><![CDATA[<p>Got it&#8230; I have Created a table with fields Id and Name then i inserted many values in that table and also inserted a NULL value. in the Name field<br />
Then When i am rnning below querry it not returns any record to me.<br />
SET ANSI_NULLS ON<br />
SELECT Name FROM MyTable(Nolock) WHERE Name=NULL</p>
<p>AND<br />
When iam running below querry it returns the row with NULL value<br />
SET ANSI_NULLS OFF<br />
SELECT Name FROM MyTable(Nolock) WHERE Name=NULL</p>
<p>So, If in case of null when ANSI_NULLS is on Wht are the benefits of this i think this is wrong caz it does not return any row which having null. Why this is present in SQL any Specific reasons, Where we use this.????</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Prashant Pandey</title>
		<link>http://blog.sqlauthority.com/2007/03/05/sql-server-quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-13042</link>
		<dc:creator>Prashant Pandey</dc:creator>
		<pubDate>Tue, 18 Sep 2007 00:22:25 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/2007/03/05/quoted_identifier-onoff-and-ansi_null-onoff-explanation/#comment-13042</guid>
		<description>Can u please provide any example of both of these, So that more clearly we can understand these.</description>
		<content:encoded><![CDATA[<p>Can u please provide any example of both of these, So that more clearly we can understand these.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
