When you think ASP, think...
Recent Articles
All Articles
ASP.NET Articles
Message Board
Related Web Technologies
User Tips!
Coding Tips

Sample Chapters
Commonly Asked Message Board Questions
JavaScript Tutorials
MSDN Communities Hub
Official Docs
Stump the SQL Guru!
XML Info
Author an Article
ASP ASP.NET ASP FAQs Message Board Feedback
Print this page.
The SQL Guru Answers your Questions...

Today's question comes from Irete P.:


I'd like to know the last date all of the tables in a database were updated. Is there some stored procedure I can use?

Thank You,
Irete P.


Sort of. The sysobjects table contains the creation date of the table - a column called crdate, I believe.

But I'm guessing that you'd like to know the last date/time the *data* in the table was updated. Sorry, you'll have to do this manually by creating an INSERT/UPDATE trigger on the table that modifies the "last updated" date in another table - probably some sort of master "last updated" table that you've created.

You could also add a "last updated" column to every table and have a trigger update that. Then you could select the max value out of the column.


Read Other SQL Guru Questions

ASP.NET [1.x] [2.0] | ASPFAQs.com | Advertise | Feedback | Author an Article