<?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: Join Effects With UPDATE	</title>
	<atom:link href="https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/feed/" rel="self" type="application/rss+xml" />
	<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/</link>
	<description></description>
	<lastBuildDate>Thu, 04 Aug 2016 13:59:06 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.3</generator>
	<item>
		<title>
		By: Krishnamurthy K		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2722</link>

		<dc:creator><![CDATA[Krishnamurthy K]]></dc:creator>
		<pubDate>Thu, 04 Aug 2016 13:59:06 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2722</guid>

					<description><![CDATA[Hi Rob,
I have query in PDW.when I try update null data(where the column doesn&#039;t accept null) it is throwing me &#034;object reference not set&#034; error for few packages and for few packages it is throwing me &#034;column has null value&#034; error.why this is so.
Thank you]]></description>
			<content:encoded><![CDATA[<p>Hi Rob,<br />
I have query in PDW.when I try update null data(where the column doesn&#8217;t accept null) it is throwing me &quot;object reference not set&quot; error for few packages and for few packages it is throwing me &quot;column has null value&quot; error.why this is so.<br />
Thank you</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Dixie S.		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2721</link>

		<dc:creator><![CDATA[Dixie S.]]></dc:creator>
		<pubDate>Fri, 22 Jan 2016 03:04:53 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2721</guid>

					<description><![CDATA[You have a point there! I&#039;m not saying I won&#039;t make a mistake and I&#039;ll be even more careful after reading your post. &#160;I tend to use Update with a join only for the simplest of queries, joining on PK, FK. &#160;Otherwise, I use subqueries or Merge (with a CTE) to prevent the danger of two rows being found in the source to update one row of the target. &#160;
Yours is the best explanation I&#039;ve read about the various ways of writing and Update statement!
Thank you for your reply. &#160;]]></description>
			<content:encoded><![CDATA[<p>You have a point there! I&#8217;m not saying I won&#8217;t make a mistake and I&#8217;ll be even more careful after reading your post. &nbsp;I tend to use Update with a join only for the simplest of queries, joining on PK, FK. &nbsp;Otherwise, I use subqueries or Merge (with a CTE) to prevent the danger of two rows being found in the source to update one row of the target. &nbsp;<br />
Yours is the best explanation I&#8217;ve read about the various ways of writing and Update statement!<br />
Thank you for your reply. &nbsp;</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Rob Farley		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2720</link>

		<dc:creator><![CDATA[Rob Farley]]></dc:creator>
		<pubDate>Thu, 21 Jan 2016 07:32:49 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2720</guid>

					<description><![CDATA[Hi Dixie,
What do you do if you need to reference the table twice in your FROM clause? Would that persuade you to update the alias? 
By updating the alias, you remove any doubt about which table in the FROM clause is the base table, although you can do it in your style if there is no ambiguity. Hopefully you&#039;ll never update a table which isn&#039;t mentioned in either the FROM or WHERE clause, but if you always update the alias, you&#039;ll be safe from that potential mistake.
If you never make a mistake, any pattern is safe enough, right?]]></description>
			<content:encoded><![CDATA[<p>Hi Dixie,<br />
What do you do if you need to reference the table twice in your FROM clause? Would that persuade you to update the alias?<br />
By updating the alias, you remove any doubt about which table in the FROM clause is the base table, although you can do it in your style if there is no ambiguity. Hopefully you&#8217;ll never update a table which isn&#8217;t mentioned in either the FROM or WHERE clause, but if you always update the alias, you&#8217;ll be safe from that potential mistake.<br />
If you never make a mistake, any pattern is safe enough, right?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Dixie S.		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2719</link>

		<dc:creator><![CDATA[Dixie S.]]></dc:creator>
		<pubDate>Thu, 21 Jan 2016 05:47:36 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2719</guid>

					<description><![CDATA[Regarding using the full table name in the update clause instead of an alias: &#034;Because you have the potential to update a table which isn’t mentioned in the FROM clause, you could find yourself inadvertently updating every row in Production.Product. &#034;
Will you please explain this a little more? -- I&#039;m not sure I understand it.
Is the danger only if you make a mistake and don&#039;t type the exact same table name in the From clause as in the Update clause? &#160;I prefer this syntax because to me, it&#039;s clearer to have the table name, rather than an alias, &#160;in the Update clause.
But then, to save some typing, I alias the tables in the From clause. 
You can imagine how surprised to find my &#034;style&#034; in the unsafe category!
These characteristics of the Update statement are news to me and I appreciate your taking the time to share your insights!]]></description>
			<content:encoded><![CDATA[<p>Regarding using the full table name in the update clause instead of an alias: &quot;Because you have the potential to update a table which isn’t mentioned in the FROM clause, you could find yourself inadvertently updating every row in Production.Product. &quot;<br />
Will you please explain this a little more? &#8212; I&#8217;m not sure I understand it.<br />
Is the danger only if you make a mistake and don&#8217;t type the exact same table name in the From clause as in the Update clause? &nbsp;I prefer this syntax because to me, it&#8217;s clearer to have the table name, rather than an alias, &nbsp;in the Update clause.<br />
But then, to save some typing, I alias the tables in the From clause.<br />
You can imagine how surprised to find my &quot;style&quot; in the unsafe category!<br />
These characteristics of the Update statement are news to me and I appreciate your taking the time to share your insights!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Rob Farley		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2718</link>

		<dc:creator><![CDATA[Rob Farley]]></dc:creator>
		<pubDate>Wed, 20 Jan 2016 05:41:41 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2718</guid>

					<description><![CDATA[Yeah, I think most people have patterns they use, and don&#039;t necessarily think about what might happen if they change the pattern. I&#039;m glad you enjoyed it, Robert (and you, Gan!).]]></description>
			<content:encoded><![CDATA[<p>Yeah, I think most people have patterns they use, and don&#8217;t necessarily think about what might happen if they change the pattern. I&#8217;m glad you enjoyed it, Robert (and you, Gan!).</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Robert L Davis		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2717</link>

		<dc:creator><![CDATA[Robert L Davis]]></dc:creator>
		<pubDate>Wed, 20 Jan 2016 04:31:11 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2717</guid>

					<description><![CDATA[Thanks for participating. Great article. I never actually realized that the table in the UPDATE clause could differ from the table in the criteria of the query. Never considered it. I have always used UPDATE x From dbo.Table x JOIN ....]]></description>
			<content:encoded><![CDATA[<p>Thanks for participating. Great article. I never actually realized that the table in the UPDATE clause could differ from the table in the criteria of the query. Never considered it. I have always used UPDATE x From dbo.Table x JOIN &#8230;.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Gan Davnarrain		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2716</link>

		<dc:creator><![CDATA[Gan Davnarrain]]></dc:creator>
		<pubDate>Sun, 17 Jan 2016 12:43:32 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2716</guid>

					<description><![CDATA[Very useful and instructive article. Thanks.]]></description>
			<content:encoded><![CDATA[<p>Very useful and instructive article. Thanks.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Rob Farley		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2715</link>

		<dc:creator><![CDATA[Rob Farley]]></dc:creator>
		<pubDate>Thu, 14 Jan 2016 05:58:44 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2715</guid>

					<description><![CDATA[Ah - typo. Missed the word &#034;once&#034;. You can only update each row one time in an update, even if the query makes it feel like you&#039;re doing it multiple times.]]></description>
			<content:encoded><![CDATA[<p>Ah &#8211; typo. Missed the word &quot;once&quot;. You can only update each row one time in an update, even if the query makes it feel like you&#8217;re doing it multiple times.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: RichB		</title>
		<link>https://lobsterpot.com.au/blog/2016/01/12/join-effects-with-update/#comment-2714</link>

		<dc:creator><![CDATA[RichB]]></dc:creator>
		<pubDate>Thu, 14 Jan 2016 03:51:26 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.lobsterpot.com.au/?p=3556#comment-2714</guid>

					<description><![CDATA[Hi...
Curious about:
&#034;If you’re doing an UPDATE, you can only update a single row in that table, no matter what kind of impact your FROM clause might want to have on the base table.&#034;
Not entirely sure I&#039;ve followed what you are saying.]]></description>
			<content:encoded><![CDATA[<p>Hi&#8230;<br />
Curious about:<br />
&quot;If you’re doing an UPDATE, you can only update a single row in that table, no matter what kind of impact your FROM clause might want to have on the base table.&quot;<br />
Not entirely sure I&#8217;ve followed what you are saying.</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
