Sql server get Year, Month and Day part of date

SELECT YEAR(SYSDATETIME())

SELECT MONTH(SYSDATETIME())

SELECT DAY(SYSDATETIME())

Leave a Reply

Your email address will not be published. Required fields are marked *