select YEAR('2002-09-30') : Year « Date Timezone « SQL Server / T-SQL






select YEAR('2002-09-30')

 


3>
4> select YEAR('2002-09-30')
5> GO

-----------
       2002

(1 rows affected)

 








Related examples in the same category

1.YEAR: return the year portion of a date
2.The DAY(), MONTH(), and YEAR() Functions
3.Using Functions in Queries