Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 gettime from sql server as a string

Author  Topic 

pelegk2
Aged Yak Warrior

723 Posts

Posted - 2006-11-29 : 05:22:01
how can i get the timefrom sqlserver as a string?
thnaks in advance
peleg

Israel -the best place to live in aftr heaven 9but no one wan't to go there so fast -:)

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-11-29 : 05:40:40
SELECT CONVERT(VARCHAR, GETDATE(), xxx)

For values of xxx, read about CONVERT function in Books Online.


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2006-11-29 : 09:39:43
If you use front end application like Vb, you can make use of Format function

Format(date,"HH:MM:SS")

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -