Get Updated Tables & Procedures Names from Database - SQL Server


----how many days before you need
declare @day int
set @day=15


SELECT name FROM sys.objects WHERE type = 'P'
AND DATEDIFF(D,modify_date, GETDATE()) < @day


SELECT name FROM sys.objects
WHERE type = 'U'  AND DATEDIFF(D,modify_date, GETDATE()) < @day


SELECT name,type FROM sys.objects
WHERE type = 'U' AND  DATEDIFF(D,modify_date, GETDATE()) < @day

Comments

Popular posts from this blog

GROUP BY, CUBE, ROLLUP and SQL SERVER 2005

How to get content of Ckeditor & Fckeditor using Javascript

How to Fix Error- Sys.WebForms.PageRequestManagerTimeoutException - The server request timed out