Hi,
I want to get time in hh:mi:ss.mmm format in SQL Server.... Please help.
Thank You...
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Pravin MorePosted Sep 23, 2011, 1:01 AM
You can get it by thuis way..............
select convert(varchar, getdate(), 114)
Output is like : 10:30:00:780
i hope it will work for you.
Thanx,
Pravin.
Jaganathan BantheswaranPosted Sep 23, 2011, 12:49 AM
Try like this
SELECT LTRIM(RIGHT(CONVERT(VARCHAR(24), GETDATE(), 113), 12))
AS HourMinuteSecond
GO