index - last use and update

Hi experts

Please, give me T-SQL
1. Get the last index update date (insert, update, delete)
2. Get the last date of use of the index

What I wish is to determine which indexes are not used to remove
enrique_aeoAsked:
Who is Participating?
 
Máté FarkasDatabase Developer and AdministratorCommented:
There is a built-in report in SQL Server Management Studio for this purpose:
Right click on your database >>> Report >>> Standard reports >>> Index Usage Statistics

In this report you can all the information you requested.

You can access these data with the following DMVs:
SELECT * FROM sys.dm_index_usage_stats
SELECT * FROM sys.dm_db_index_operational_stats (NULL, NULL, NULL, NULL)    

Open in new window

0
 
enrique_aeoAuthor Commented:
the day yesterday was reviewing the url that an expert put it, because they have erased? it could re-post?
0
 
enrique_aeoAuthor Commented:
The links provided were interesting, I need them.

I think if the expert does not put comments, should not eliminate, the expert should add any comments by the link.

Based on your experience, you definitely have the best articles I could find.
0
Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

 
Vitor MontalvãoMSSQL Senior EngineerCommented:
Another blind link comment deleted.
0
 
Vitor MontalvãoMSSQL Senior EngineerCommented:
Enrique, the links provided refers to the two DMV in Máté's comment.
I guess you know how to use a search engine to get more information about those DMV :)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.