Hi @antony joseph ,
Welcome to the microsoft TSQL Q&A forum!
Please refer to:
declare @table table(Date_col datetime2)
insert into @table values('2021-04-02 14:33:18.1166667'),('2021-04-05 18:47:21.9200000')
,('2021-04-03 10:54:36.5333333'),('2021-04-03 21:25:21.8166667')
select FORMAT(Date_col, N'yyMMdd') from @table
Output:
If you have any question, please feel free to let me know.
If the response is helpful, please click "Accept Answer" and upvote it.
Regards
Echo
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.