Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Is there a way to figure out what data is rarely accessed on my SQL Server databases?

So we’re exploring our options in terms of migrating our SQL Server database to another engine. A question that we’ve been asked when talking with other providers is how much of our stored information could potentially live in cold storage / archives.

Is there a way to figure this out through SSMS or any other third party tools?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

You can use sys.dm_db_index_usage_stats view, but it is cleared on server restart, so might not be sufficiently reliable.

Look at all datetime columns, eg.

SELECT t.name,
  (SELECT Max(v) 
   FROM (VALUES (last_user_seek), (last_user_scan), (last_user_lookup),   (last_user_update)) AS value(v)) as [MaxDate]
FROM sys.dm_db_index_usage_stats us 
join sys.tables t
on t.object_id = us.object_id
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading