<?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; Interview Questions and Answers &#8211; Frequently Asked Questions &#8211; Day 7 of 31</title>
	<atom:link href="http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/</link>
	<description>Personal Notes of Pinal Dave</description>
	<lastBuildDate>Sat, 25 May 2013 01:31:40 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
	<item>
		<title>By: Narendra Kumar</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-311299</link>
		<dc:creator><![CDATA[Narendra Kumar]]></dc:creator>
		<pubDate>Mon, 09 Jul 2012 07:24:05 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-311299</guid>
		<description><![CDATA[SELECT      A.SalesOrderID,      A.OrderDate,      SQ.Max_Foo,      SQ.Max_Foo2 FROM      A LEFT OUTER JOIN      (      SELECT           B.SalesOrderID,           MAX(B.Foo) AS Max_Foo,           MAX(B.Foo2) AS Max_Foo2      FROM           B      GROUP BY           B.SalesOrderID      ) AS SQ ON SQ.SalesOrderID = A.SalesOrderID]]></description>
		<content:encoded><![CDATA[<p>SELECT      A.SalesOrderID,      A.OrderDate,      SQ.Max_Foo,      SQ.Max_Foo2 FROM      A LEFT OUTER JOIN      (      SELECT           B.SalesOrderID,           MAX(B.Foo) AS Max_Foo,           MAX(B.Foo2) AS Max_Foo2      FROM           B      GROUP BY           B.SalesOrderID      ) AS SQ ON SQ.SalesOrderID = A.SalesOrderID</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sourish Biswas</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-250453</link>
		<dc:creator><![CDATA[Sourish Biswas]]></dc:creator>
		<pubDate>Thu, 09 Feb 2012 14:21:20 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-250453</guid>
		<description><![CDATA[Can you please provide me an example of &#039;Multiple column sub-query&#039;]]></description>
		<content:encoded><![CDATA[<p>Can you please provide me an example of &#8216;Multiple column sub-query&#8217;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vinay Awasthi</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-182660</link>
		<dc:creator><![CDATA[Vinay Awasthi]]></dc:creator>
		<pubDate>Mon, 24 Oct 2011 05:31:34 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-182660</guid>
		<description><![CDATA[Hi Pinal,
I just wanted to know that if there is any procedure made earlier with encryption so is there any way to decrypt it. I really require help from you...

Is anybody here who can help me out from this situation.]]></description>
		<content:encoded><![CDATA[<p>Hi Pinal,<br />
I just wanted to know that if there is any procedure made earlier with encryption so is there any way to decrypt it. I really require help from you&#8230;</p>
<p>Is anybody here who can help me out from this situation.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-153167</link>
		<dc:creator><![CDATA[Ryan]]></dc:creator>
		<pubDate>Wed, 03 Aug 2011 13:02:34 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-153167</guid>
		<description><![CDATA[Regarding UPDATE_STATISTICS, the way I&#039;m reading it from the description, that the command &quot;updates the indexes&quot;.  To be more clear, it doesn&#039;t update the actual indexes like, for example, rebuilding an index does. Rather, it only updates the statistics on the target index, which is used by the query plan optimizer.]]></description>
		<content:encoded><![CDATA[<p>Regarding UPDATE_STATISTICS, the way I&#8217;m reading it from the description, that the command &#8220;updates the indexes&#8221;.  To be more clear, it doesn&#8217;t update the actual indexes like, for example, rebuilding an index does. Rather, it only updates the statistics on the target index, which is used by the query plan optimizer.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: madhivanan</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-149160</link>
		<dc:creator><![CDATA[madhivanan]]></dc:creator>
		<pubDate>Mon, 18 Jul 2011 14:20:27 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-149160</guid>
		<description><![CDATA[Here you go
http://blog.sqlauthority.com/2011/07/08/sql-server-interview-questions-and-answers-frequently-asked-questions-day-8-of-31/]]></description>
		<content:encoded><![CDATA[<p>Here you go<br />
<a href="http://blog.sqlauthority.com/2011/07/08/sql-server-interview-questions-and-answers-frequently-asked-questions-day-8-of-31/" rel="nofollow">http://blog.sqlauthority.com/2011/07/08/sql-server-interview-questions-and-answers-frequently-asked-questions-day-8-of-31/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chaitanya</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-148291</link>
		<dc:creator><![CDATA[Chaitanya]]></dc:creator>
		<pubDate>Thu, 14 Jul 2011 15:04:21 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-148291</guid>
		<description><![CDATA[Thanks for your well efforts.. to help..]]></description>
		<content:encoded><![CDATA[<p>Thanks for your well efforts.. to help..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chaitanya</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-148290</link>
		<dc:creator><![CDATA[Chaitanya]]></dc:creator>
		<pubDate>Thu, 14 Jul 2011 15:03:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-148290</guid>
		<description><![CDATA[Hi Sir, Iam not able to go Day 8 of 31? could you please provide the link..]]></description>
		<content:encoded><![CDATA[<p>Hi Sir, Iam not able to go Day 8 of 31? could you please provide the link..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dew Drop &#8211; July 7, 2011 &#124; Alvin Ashcraft&#039;s Morning Dew</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-146637</link>
		<dc:creator><![CDATA[Dew Drop &#8211; July 7, 2011 &#124; Alvin Ashcraft&#039;s Morning Dew]]></dc:creator>
		<pubDate>Thu, 07 Jul 2011 11:24:35 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-146637</guid>
		<description><![CDATA[[...] SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Day 7 of 31 (Pinal Dave) [...]]]></description>
		<content:encoded><![CDATA[<p>[...] SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Day 7 of 31 (Pinal Dave) [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Complete Downloadable List – Day 0 of 31 Journey to SQLAuthority</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-146600</link>
		<dc:creator><![CDATA[SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Complete Downloadable List – Day 0 of 31 Journey to SQLAuthority]]></dc:creator>
		<pubDate>Thu, 07 Jul 2011 08:44:52 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-146600</guid>
		<description><![CDATA[[...] SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Day 7 of 31 [...]]]></description>
		<content:encoded><![CDATA[<p>[...] SQL SERVER – Interview Questions and Answers – Frequently Asked Questions – Day 7 of 31 [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: pinaldave</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-146598</link>
		<dc:creator><![CDATA[pinaldave]]></dc:creator>
		<pubDate>Thu, 07 Jul 2011 08:33:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-146598</guid>
		<description><![CDATA[David,

Absolutely agree with your point. It can contain ORDER BY when used with TOP. 

It is not a small point but very good point, however there is always debate about why one need it. Keeping it on aside. I am updating the original blog post to refer to your comment.

Many thanks,
Pinal]]></description>
		<content:encoded><![CDATA[<p>David,</p>
<p>Absolutely agree with your point. It can contain ORDER BY when used with TOP. </p>
<p>It is not a small point but very good point, however there is always debate about why one need it. Keeping it on aside. I am updating the original blog post to refer to your comment.</p>
<p>Many thanks,<br />
Pinal</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: davidbridge</title>
		<link>http://blog.sqlauthority.com/2011/07/07/sql-server-interview-questions-and-answers-frequently-asked-questions-day-7-of-31/#comment-146597</link>
		<dc:creator><![CDATA[davidbridge]]></dc:creator>
		<pubDate>Thu, 07 Jul 2011 08:29:37 +0000</pubDate>
		<guid isPermaLink="false">http://blog.sqlauthority.com/?p=13305#comment-146597</guid>
		<description><![CDATA[&quot;A sub-query cannot contain an ORDER BY clause.&quot;

It can.

but you must include a top x. This is because the order of the sub query ressults in unimporatant to the parent query however if you only want to top 10 or top 10 percent of the sub query results based on a column in that subquery then you need the order by. Also applies to xml.

Its a small point but I thought it might be useful to someone.

Dave]]></description>
		<content:encoded><![CDATA[<p>&#8220;A sub-query cannot contain an ORDER BY clause.&#8221;</p>
<p>It can.</p>
<p>but you must include a top x. This is because the order of the sub query ressults in unimporatant to the parent query however if you only want to top 10 or top 10 percent of the sub query results based on a column in that subquery then you need the order by. Also applies to xml.</p>
<p>Its a small point but I thought it might be useful to someone.</p>
<p>Dave</p>
]]></content:encoded>
	</item>
</channel>
</rss>
