Date-
1. select DATEDIFF(MILLISECOND ,GETDATE()-1,GETDATE()) as milisecond
Time-
1. select right(convert(varchar(30),getdate(),121),12)
outpur-- 15:02:24.3424398
2. SELECT CONVERT(VARCHAR(16), SYSDATETIME(), 14)
outpur-- 15:02:24.3424398
1. select DATEDIFF(MILLISECOND ,GETDATE()-1,GETDATE()) as milisecond
Time-
1. select right(convert(varchar(30),getdate(),121),12)
outpur-- 15:02:24.3424398
2. SELECT CONVERT(VARCHAR(16), SYSDATETIME(), 14)
outpur-- 15:02:24.3424398
No comments:
Post a Comment