<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx</link><description>Did you know that your SQL Server is keeping track of the indexes that it thinks you should create? The "missing index" DMVs in SQL are a really great new feature in SQL Server 2005 that (in my opinion) seem to have been underutilized so far. If you want</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#4543572</link><pubDate>Fri, 24 Aug 2007 17:42:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4543572</guid><dc:creator>Pablo Mugica</dc:creator><description>&lt;p&gt;Agree with the cool &amp;amp; magical of this feature (imagine avoiding errors in a group of people creating indexes @ a large datawarehouse). Thank You for the reminder about this.&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#5488689</link><pubDate>Wed, 17 Oct 2007 13:35:27 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5488689</guid><dc:creator>Duncan Millard</dc:creator><description>&lt;p&gt;Hi Bart, thanks for such a great heads-up.&lt;/p&gt;
&lt;p&gt;Just a slight note of caution to BizTalk users: I just ran this query on a box here and found lots of recommendations for adding indices in the BizTalk databases.&lt;/p&gt;
&lt;p&gt;People must not follow these recommendations on BizTalk! The BizTalk database is very carefully tuned by hand; any changes to these databases will potentially cause serious problems and PSS will most likely insist on step 1 of any troubleshooting being to set BizTalk database installations back to the out of the box install.&lt;/p&gt;
&lt;p&gt;As they say at: &lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/biztalk_core_engine/archive/2007/01/04/what-you-can-and-can-t-do-with-the-messagebox-database-server.aspx"&gt;http://blogs.msdn.com/biztalk_core_engine/archive/2007/01/04/what-you-can-and-can-t-do-with-the-messagebox-database-server.aspx&lt;/a&gt;, &amp;quot;(don't add indexes, columns, triggers, ... If you do you will hear silence when you call for help)&amp;quot;&lt;/p&gt;
&lt;p&gt;Hope this little bit of info is useful!&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Duncan&lt;/p&gt;</description></item><item><title>Dynamic Management Views</title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#6570341</link><pubDate>Wed, 28 Nov 2007 09:28:07 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6570341</guid><dc:creator>SELECT Star FROM Chad.Brain</dc:creator><description>&lt;p&gt;In my &amp;quot;APPLY Operator&amp;quot; post I used the example query below to illustrate the use of CROSS APPLY. I mentioned&lt;/p&gt;
</description></item><item><title>Missing Index DMVs</title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#7199629</link><pubDate>Tue, 22 Jan 2008 19:54:58 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7199629</guid><dc:creator>Troubleshooting and Tips - Cindy Gross</dc:creator><description>&lt;p&gt;SQL Server 2005 has some DMVs that will help you tune the system. The missing index DMVs track recent queries that could have benefited from an index that didn't exist. ...&lt;/p&gt;
</description></item><item><title>Which queries are missing indexes?</title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8474575</link><pubDate>Fri, 09 May 2008 00:06:52 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8474575</guid><dc:creator>My two cents</dc:creator><description>&lt;p&gt;One of the things I really enjoy when doing performance tuning on 2005 (I still work on a mix of several&lt;/p&gt;
</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8704246</link><pubDate>Tue, 08 Jul 2008 00:27:39 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8704246</guid><dc:creator>Phil Streiff</dc:creator><description>&lt;p&gt;I've been using your excellent &amp;quot;missing index&amp;quot; DMV for some time and just recently it has started throwing an error on one of my servers: &lt;/p&gt;
&lt;p&gt;&amp;quot;Arithmetic overflow error converting float to data type numeric.&amp;quot;&lt;/p&gt;
&lt;p&gt;Any idea what might be causing this and how I can possibly work around it by altering the script?&lt;/p&gt;
&lt;p&gt;SQL2005 Ent Ed, SP2, Windows 2003 Server&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Phil &lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8704461</link><pubDate>Tue, 08 Jul 2008 01:06:19 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8704461</guid><dc:creator>bartd</dc:creator><description>&lt;p&gt;I haven't run into that problem myself, but think I see what is causing it. &amp;nbsp;I've made a couple of minor changes to the query that should fix it; can you give it a try and let me know what you find? &lt;/p&gt;
</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8708984</link><pubDate>Tue, 08 Jul 2008 19:58:10 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8708984</guid><dc:creator>Phil Streiff</dc:creator><description>&lt;p&gt;Hi Bart:&lt;/p&gt;
&lt;p&gt;I recopied the script and ran it again but am still getting the same error. Only happens on one of my servers though. &amp;lt;weird&amp;gt;&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Phil &lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8709239</link><pubDate>Tue, 08 Jul 2008 21:02:14 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8709239</guid><dc:creator>bartd</dc:creator><description>&lt;p&gt;Phil, I've removed the attempted conversion of the improvement measure to decimal (it was just there for formatting, anyway). &amp;nbsp;Can you try once more? &amp;nbsp;You should no longer get the error, but if you do, ping me offline at bartd at micro soft dot com and we'll figure it out. &amp;nbsp;Thanks, Bart&lt;/p&gt;
</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#8717243</link><pubDate>Thu, 10 Jul 2008 18:02:20 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8717243</guid><dc:creator>Phil</dc:creator><description>&lt;p&gt;Hi Bart:&lt;/p&gt;
&lt;p&gt;That seemed to fix the problem. The script runs successfully now and returns expected results.&lt;/p&gt;
&lt;p&gt;However, the highest 'improvement_measure' is now displaying '9.84239188405347E+36' so, I guess this is where the formatting gets lost. I'm not quite sure how to interpret that number now, but it's obviously a big one.&lt;/p&gt;
&lt;p&gt;Thanks again,&lt;/p&gt;
&lt;p&gt;Phil&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9011492</link><pubDate>Wed, 22 Oct 2008 21:35:44 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9011492</guid><dc:creator>Robert McLaws</dc:creator><description>&lt;p&gt;Everyone,&lt;/p&gt;
&lt;p&gt;If you want to import the results into Excel for analysis, you need to change Line 10 from this:&lt;/p&gt;
&lt;p&gt;+ ISNULL (' INCLUDE (' + mid.included_columns + ')', '') AS create_index_statement,&lt;/p&gt;
&lt;p&gt;to this:&lt;/p&gt;
&lt;p&gt;+ ISNULL (' INCLUDE (' + mid.included_columns + ')”', '”') AS create_index_statement,&lt;/p&gt;
&lt;p&gt;Otherwise, the SQL statement jacks with the columns in the comma-separated file.&lt;/p&gt;
&lt;p&gt;HTH&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9173984</link><pubDate>Thu, 04 Dec 2008 10:16:14 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9173984</guid><dc:creator>SQLDeveloper</dc:creator><description>&lt;p&gt;Thanks for the script for missing indexes, I used that a few times. And I found it very useful. Since it gathers all those statistics by using the activity on the database.&lt;/p&gt;
&lt;p&gt;Thanks again&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9470632</link><pubDate>Wed, 11 Mar 2009 18:28:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9470632</guid><dc:creator>Neel</dc:creator><description>&lt;p&gt;Thank you very much. This has improved my query performance a lot :)&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9540849</link><pubDate>Thu, 09 Apr 2009 20:37:58 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9540849</guid><dc:creator>joetig</dc:creator><description>&lt;p&gt;Is There a way to find the object \ query that caused the generation of the missing index entry in the dmv&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9910510</link><pubDate>Wed, 21 Oct 2009 11:45:25 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9910510</guid><dc:creator>Laerte Junior</dc:creator><description>&lt;p&gt;I&amp;#180;m sorry my english, was by google&lt;/p&gt;
&lt;p&gt;I have to disagree on some points. I had a recent experience that the situation could not use DTA and the DMV's were fantastic&lt;/p&gt;
&lt;p&gt;Each situation has its application, both DTA and DVM's.&lt;/p&gt;
&lt;p&gt;&amp;quot;The missing index DMVs don't take into account the overhead that new indexes can create (extra disk space, slight impact on insert/delete perf, etc). DTA does take this into account, however. &amp;quot;&lt;/p&gt;
&lt;p&gt;I belive they not been made for that. In this case we have the DTA and this type of type of analysis &amp;nbsp;I prefer to do this without automatic recommendations.&lt;/p&gt;
&lt;p&gt;&amp;quot;The &amp;quot;improvement_measure&amp;quot; column in this query's output is a rough indicator of the (estimated) improvement that might be seen if the index was created. &amp;nbsp;This is a unitless number, and has meaning only relative the same number for other indexes. &amp;nbsp;(It's a combination of the avg_total_user_cost, avg_user_impact, user_seeks, and user_scans columns in sys.dm_db_missing_index_group_stats.) &amp;quot;&lt;/p&gt;
&lt;p&gt;The Avg_user Impact is near to close. Very near with the Real&lt;/p&gt;
&lt;p&gt;(I did a lot of tests with a 4TB database )&lt;/p&gt;
&lt;p&gt;&amp;quot;The missing index DMVs don't make recommendation about whether a proposed index should be clustered or nonclustered. &amp;nbsp;This has workload-wide ramifications, while these DMVs focus only on the indexes that would benefit individual queries. &amp;nbsp;(DTA can do this, however.)&amp;quot;&lt;/p&gt;
&lt;p&gt;Like I said , I belive they not been made for that too. For this we have another DMV&amp;#180;s and DTA like you said.&lt;/p&gt;
&lt;p&gt;And particularly for me, the definition of the index cluster is very focused on their specific business rule as discussing when the normalization is good or not. Is good when you answer your business.&lt;/p&gt;
&lt;p&gt;Won't recommend partitioning.&lt;/p&gt;
&lt;p&gt;Yes, this is a problem really.&lt;/p&gt;
&lt;p&gt;&amp;quot;It's possible that the DMVs may not recommend the ideal column order for multi-column indexes.&amp;quot;&lt;/p&gt;
&lt;p&gt;No, By ton of tests I Did ALWAYS the columns suggested in multi-column indexed was correctly, by your selectivity.&lt;/p&gt;
&lt;p&gt;A very interesting point to see is that the DMV's return a run &amp;nbsp;statistics and cost per query &lt;/p&gt;
&lt;p&gt;of not benefited from this index as the actual load in your environment. The DTA does not.&lt;/p&gt;
&lt;p&gt;If you have a third-party software that makes many queries dynamically by the application, &lt;/p&gt;
&lt;p&gt;you have to get the queries by profiler and run &amp;nbsp;in the DTA. &lt;/p&gt;
&lt;p&gt;And to know which query is being accessed more (number) is complicated by the profiler. &lt;/p&gt;
&lt;p&gt;For DMV use user_seeks.And it is a REAL number to your environment workload&lt;/p&gt;
&lt;p&gt;I believe that we can not go out creating indexes with the DMV's, but also by the DTA. &lt;/p&gt;
&lt;p&gt;It's all a question of the situation that you will use one or the other. &lt;/p&gt;
&lt;p&gt;But surely they were a goal of time sql server&lt;/p&gt;
&lt;p&gt;This is my feedback about the DMV&amp;#180;s.&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://www.simple-talk.com/sql/performance/reducing-io-with-the-missing-indexes-dmvs/"&gt;http://www.simple-talk.com/sql/performance/reducing-io-with-the-missing-indexes-dmvs/&lt;/a&gt;&lt;/p&gt;</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9932253</link><pubDate>Thu, 03 Dec 2009 22:53:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9932253</guid><dc:creator>bartd</dc:creator><description>&lt;p&gt;Thanks for the comment, Laerte. &amp;nbsp;You make good points, and for the most part I agree with you. &amp;nbsp;It wasn't my intent to imply that the DMVs are &amp;quot;bad&amp;quot; and DTA is &amp;quot;good&amp;quot;. &amp;nbsp;I just wanted to make sure that people knew the relative strengths and weaknesses of each tool so that they can deploy each in the proper circumstances. &amp;nbsp;&lt;/p&gt;
</description></item><item><title>re: Are you using SQL's Missing Index DMVs? </title><link>http://blogs.msdn.com/bartd/archive/2007/07/19/are-you-using-sql-s-missing-index-dmvs.aspx#9932284</link><pubDate>Fri, 04 Dec 2009 00:16:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9932284</guid><dc:creator>bartd</dc:creator><description>&lt;p&gt;@joetig, &lt;/p&gt;
&lt;p&gt;&amp;gt;&amp;gt; Is There a way to find the object \ query that caused the generation of the missing index entry in the dmv &amp;lt;&amp;lt;&lt;/p&gt;
&lt;p&gt;Not directly, but there's an approximate technique for doing this that was shared by Leo Pasta at &lt;a rel="nofollow" target="_new" href="http://sqlblogcasts.com/blogs/leopasta/archive/2008/05/08/which-queries-are-missing-indexes.aspx"&gt;http://sqlblogcasts.com/blogs/leopasta/archive/2008/05/08/which-queries-are-missing-indexes.aspx&lt;/a&gt;. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;HTH! &lt;/p&gt;
</description></item></channel></rss>