﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 2008 / T-SQL (SS2K8)  / Help On Execution Plan Status / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Wed, 22 May 2013 20:39:50 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>[quote][b]Shadab Shah (11/30/2012)[/b][hr]So my basic question is, how does the query analyzer decide when to used ClusteredIndexScan and when to used ClusteredIndexSeek.[/quote]It will often consider both alternatives.  It estimates the cost of each and chooses the one that appears cheapest (according to the model it uses).  There are a number of detailed factors that affect the cost calculation, and overall plan selection, but that's a basic answer to your basic question.</description><pubDate>Sat, 01 Dec 2012 22:38:54 GMT</pubDate><dc:creator>Paul White</dc:creator></item><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>[quote][b]ScottPletcher (11/30/2012)[/b][hr][quote][b]Grant Fritchey (11/30/2012)[/b][hr]And the indexes have to be selective enough to be useful for a seek or you'll get scans. Same things apply to non-clustered indexes too.For lots more detail on query tuning and execution plans, take a look at my books (listed below).[/quote]Not for clustered indexes.  SQL can do a seek on a clustered index even if you're SELECTing 99% of the rows.[/quote]More correctly, not for any index that covers the query. A covering nonclustered index can and will be used for a seek up to 100% of the rows.</description><pubDate>Fri, 30 Nov 2012 12:49:36 GMT</pubDate><dc:creator>GilaMonster</dc:creator></item><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>[quote][b]Grant Fritchey (11/30/2012)[/b][hr]And the indexes have to be selective enough to be useful for a seek or you'll get scans. Same things apply to non-clustered indexes too.For lots more detail on query tuning and execution plans, take a look at my books (listed below).[/quote]Not for clustered indexes.  SQL can do a seek on a clustered index even if you're SELECTing 99% of the rows.</description><pubDate>Fri, 30 Nov 2012 12:28:46 GMT</pubDate><dc:creator>ScottPletcher</dc:creator></item><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>And the indexes have to be selective enough to be useful for a seek or you'll get scans. Same things apply to non-clustered indexes too.For lots more detail on query tuning and execution plans, take a look at my books (listed below).</description><pubDate>Fri, 30 Nov 2012 09:22:55 GMT</pubDate><dc:creator>Grant Fritchey</dc:creator></item><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>Seek when there's a SARGable predicate (&amp;lt;column&amp;gt; &amp;lt;comparison operator&amp;gt; &amp;lt;expression&amp;gt;) on the index key columns. Scan if there isn't. Very, very simplified, but that's the basics.</description><pubDate>Fri, 30 Nov 2012 08:12:24 GMT</pubDate><dc:creator>GilaMonster</dc:creator></item><item><title>RE: Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>Paul White's blog series will pretty much any question you could ever think of on this.[url]http://www.sqlservercentral.com/articles/SQL+Server+2008/71019/[/url]</description><pubDate>Fri, 30 Nov 2012 08:04:02 GMT</pubDate><dc:creator>Dennis Post</dc:creator></item><item><title>Help On Execution Plan Status</title><link>http://www.sqlservercentral.com/Forums/Topic1391318-392-1.aspx</link><description>Hi All,I am a newbie in SQL Server and like exploring it. Currently i was working with some  complex queries and happen to see there Execution Plan. I saw that there were some Clustered index which were 'ClusteredIndexSeek' and Some Clustered Index as 'ClusteredIndexScan'. So my basic question is, how does the query analyzer decide when to used ClusteredIndexScan and when to used ClusteredIndexSeek.</description><pubDate>Fri, 30 Nov 2012 07:52:29 GMT</pubDate><dc:creator>Shadab Shah</dc:creator></item></channel></rss>