Sorry for the silly question
Thanks and best regards
Rafael Mauricio Nami
There is no direct style to get just the year format. You can do one of the following:
select cast(year(current_timestamp) as char(4))
, cast(datepart(year, current_timestamp) as char(4))
, convert(char(4), current_timestamp, 112)
No comments:
Post a Comment