 




<?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/"
		>
<channel>
	<title>Comments on: SQL Scripting</title>
	<atom:link href="http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/feed/" rel="self" type="application/rss+xml" />
	<link>http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/</link>
	<description></description>
	<lastBuildDate>Thu, 23 May 2013 20:47:04 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>By: frankkulash</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/#comment-52155</link>
		<dc:creator>frankkulash</dc:creator>
		<pubDate>Thu, 06 Mar 2008 16:57:17 +0000</pubDate>
		<guid isPermaLink="false">#comment-52155</guid>
		<description><![CDATA[You&#039;ll to do something extra if your definition of &quot;the same&quot; does not correspond to the system&#039;s definition of &quot;=&quot;.  (The example of NULLs, above, is a special case of this.)

If a and b are strings, and you want to distinguish between capital and small letters, but the system doesn&#039;t (that is, if considers capital &#039;B&#039;  to be equal to small &#039;b&#039;), then you have to convert the strings to some other type where the difference in case does matter to the system.  In SQL Server, you might say:
&lt;pre&gt;
SELECT	c
FROM	x
WHERE	CAST (a AS VARBINARY (10)) = 
	CAST (b AS VARBINARY (10));
&lt;/pre&gt;

There may be some system somewhere that considers (e.g.) &#039;B&#039; stroed in a 10-character fixed-length column to be different that the same letter &#039;B&#039; stored in a 20-character fixed-length column.  In that case, you might have to explicitly convert the shorter one to the longer type, or do a separate test for length.]]></description>
		<content:encoded><![CDATA[<p>You&#8217;ll to do something extra if your definition of &#8220;the same&#8221; does not correspond to the system&#8217;s definition of &#8220;=&#8221;.  (The example of NULLs, above, is a special case of this.)</p>
<p>If a and b are strings, and you want to distinguish between capital and small letters, but the system doesn&#8217;t (that is, if considers capital &#8216;B&#8217;  to be equal to small &#8216;b&#8217;), then you have to convert the strings to some other type where the difference in case does matter to the system.  In SQL Server, you might say:</p>
<pre>
SELECT	c
FROM	x
WHERE	CAST (a AS VARBINARY (10)) = 
	CAST (b AS VARBINARY (10));
</pre>
<p>There may be some system somewhere that considers (e.g.) &#8216;B&#8217; stroed in a 10-character fixed-length column to be different that the same letter &#8216;B&#8217; stored in a 20-character fixed-length column.  In that case, you might have to explicitly convert the shorter one to the longer type, or do a separate test for length.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jlees</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/#comment-52088</link>
		<dc:creator>jlees</dc:creator>
		<pubDate>Wed, 05 Mar 2008 03:25:38 +0000</pubDate>
		<guid isPermaLink="false">#comment-52088</guid>
		<description><![CDATA[Also, don&#039;t the rules change if the item is a string ?]]></description>
		<content:encoded><![CDATA[<p>Also, don&#8217;t the rules change if the item is a string ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: frankkulash</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/#comment-52076</link>
		<dc:creator>frankkulash</dc:creator>
		<pubDate>Tue, 04 Mar 2008 21:33:28 +0000</pubDate>
		<guid isPermaLink="false">#comment-52076</guid>
		<description><![CDATA[If you consider a to be the same as b when they are both NULL, then the solution is a little more complicated.  Here&#039;s one way:

&lt;pre&gt;
SELECT	c
FROM	x
WHERE	a = b
OR	(a IS NULL AND b IS NULL);
&lt;/pre&gt;]]></description>
		<content:encoded><![CDATA[<p>If you consider a to be the same as b when they are both NULL, then the solution is a little more complicated.  Here&#8217;s one way:</p>
<pre>
SELECT	c
FROM	x
WHERE	a = b
OR	(a IS NULL AND b IS NULL);
</pre>
]]></content:encoded>
	</item>
	<item>
		<title>By: mrdenny</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/sql-scripting/#comment-52064</link>
		<dc:creator>mrdenny</dc:creator>
		<pubDate>Tue, 04 Mar 2008 19:17:29 +0000</pubDate>
		<guid isPermaLink="false">#comment-52064</guid>
		<description><![CDATA[Check out my SQL Server blog &quot;&lt;a href=&quot;http://itknowledgeexchange.techtarget.com/sql-server/&quot;&gt;SQL Server with Mr Denny&lt;/a&gt;&quot; for more SQL Server information.]]></description>
		<content:encoded><![CDATA[<p>Check out my SQL Server blog &#8220;<a href="http://itknowledgeexchange.techtarget.com/sql-server/">SQL Server with Mr Denny</a>&#8221; for more SQL Server information.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using memcached
Database Caching 3/10 queries in 0.041 seconds using memcached
Object Caching 309/315 objects using memcached

Served from: itknowledgeexchange.techtarget.com @ 2013-05-23 22:15:30 -->