Mike Levan
SSChampion
Points: 14201
More actions
June 30, 2008 at 4:16 pm
#71626
how can i get only year from a datetiem datatype.
I need only year from this 2003-01-13 00:00:00.000
Sean Matthews
SSC Veteran
Points: 244
June 30, 2008 at 4:25 pm
#836413
year(date)
Steve Jones - SSC Editor
SSC Guru
Points: 736255
July 1, 2008 at 7:58 am
#836696
year() is what I'd use, but datepart() works as well.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply