날짜별로 수정 날짜를 확인 functions
하고 stored procedures
함께 주문할 때 사용할 수 있습니다 .
SELECT 'Stored procedure' as [Type] ,name, create_date, modify_date
FROM sys.objects
WHERE type = 'P'
UNION all
Select 'Function' as [Type],name, create_date, modify_date
FROM sys.objects
WHERE type = 'FN'
ORDER BY modify_date DESC
또는 :
SELECT type ,name, create_date, modify_date
FROM sys.objects
WHERE type in('P','FN')
ORDER BY modify_date DESC
-- this one shows type like : FN for function and P for stored procedure
결과는 다음과 같습니다.
Type | name | create_date | modify_date
'Stored procedure' | 'firstSp' | 2018-08-04 07:36:40.890 | 2019-09-05 05:18:53.157
'Stored procedure' | 'secondSp' | 2017-10-15 19:39:27.950 | 2019-09-05 05:15:14.963
'Function' | 'firstFn' | 2019-09-05 05:08:53.707 | 2019-09-05 05:08:53.707