Solved

How Can You Find Out If An Index Is Being Used Or Not In SQL Server?

Posted on 2011-03-01
6
267 Views
Last Modified: 2012-05-11
Is there a way to detect and or gather information that show what indexes are being used and how often the are being used in a SQL Server database?
0
Comment
Question by:Omega002
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 8

Expert Comment

by:Forefront_Data_Solutions
ID: 35012379
If you are using SQL Server 2005 or later, there are some useful queries you can use.  Check these out:
http://www.mssqltips.com/tip.asp?tip=1239
0
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 500 total points
ID: 35012430
if you haven't restarted your system for a while the following script will list out the indexes, you have to monitor them for few days bbefore you delete

 SELECT   * FROM      sys.indexes idx          JOIN      sys.dm_db_index_usage_stats ius ON idx.object_id = ius.object_id                                                       AND idx.index_id = ius.index_id          WHERE     idx.type_desc = 'nonclustered'                    AND ius.user_seeks = ( SELECT   MAX(user_seeks)                                           FROM     sys.dm_db_index_usage_stats                                           WHERE    object_id = ius.object_id                                                    AND type_desc = 'nonclustered' )      
0
 
LVL 41

Expert Comment

by:Sharath
ID: 35012535
0
Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

 

Author Comment

by:Omega002
ID: 35096339
can I also see this over a period of time like for the last 3 months?
0
 

Author Comment

by:Omega002
ID: 35166274
Is there a way to capture Index usage in SQL Server Over a daily, weekly, monthly and quarterly period?
0
 
LVL 41

Expert Comment

by:Sharath
ID: 35168803
No, you cannot. On a regular basis, if you can save the result of the query mentioned in the URL  to a temp table, you can have the history.
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
In this article we will learn how to fix  “Cannot install SQL Server 2014 Service Pack 2: Unable to install windows installer msi file” error ?
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question