Monday, 13 February 2023

SQL get data by date conditions

 select * from tbl_UserAccessEntities

 where DATEPART(yy, ModifiedOn) = 2023


 SELECT * FROM tbl_UserAccessEntities WHERE  CONVERT(VARCHAR, ModifiedOn , 120) LIKE '2023-02-13%'



To know latest Procedures crated in sql

SELECT * FROM sys.objects WHERE type='p' ORDER BY modify_date DESC


SELECT name, create_date, modify_date 

FROM sys.objects

WHERE type = 'P'


SELECT name, crdate, refdate 

FROM sysobjects

WHERE type = 'P' 

ORDER BY refdate desc

No comments:

Post a Comment

Best UI