Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 5123

sys.dm_db_missing_index_details does not contain indexes recommended by the SSMS Estimated Execution Plan

$
0
0

Sometimes a user will complain about their query performance to which I'll copy the query to SSMS and then run the Estimated Execution Plan feature to see what the Optimizer is doing. Occasionally the Optimizer will recommend a missing index which does not exist in the sys.dm_db_missing_index_details DMV. I don't understand how these results can be different since the Optimizer is leveraged by the internal SQL engine when populating the DMV. Just to clarify the order of actions:

1) Restart the SQL instance

2) Run the user's problem query in SSMS until completion

3) Run the Display Estimated Execution Plan feature in SSMS for the same user query

4) Query the sys.dm_db_missing_index_details DMV

I would expect that any missing index suggested in #3 would also be returned in #4, but this is not the case. The same suggested index does not exist in #4. Any ideas as to what might cause this discrepancy?


Viewing all articles
Browse latest Browse all 5123

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>