how to display last modified record from sqlserver table?
how to display last modified record from sqlserver table?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
VasanthPosted Apr 6, 2010, 5:32 AM
Last record update for all tables in the database ,SELECT OBJECT_NAME(OBJECT_ID) AS DatabaseName, last_user_update,*
FROM sys.dm_db_index_usage_stats
WHERE database_id = DB_ID( DBName')
AND OBJECT_ID=OBJECT_ID('test')
For table structure modification ,select [name],create_date,modify_date from sys.tablesWHERE create_date <> modify_date ORDER BY modify_Date
Please mark as answer , if it helps you.