Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Strip time from datetime value

Status
Not open for further replies.

dibbo

Programmer
Nov 22, 2004
12
GB
I'm writing a query that pulls back various values, with one being a datetime value i.e. 2005-04-08 07:29:26.000 (dbo.tblScans.Scan_DateTime)

How do I strip the date off just to leave the time?

been looking at the convert function but can't get the correct syntax..

TIA
 
select convert(varchar, tblScans.Scan_DateTime, 101)
from tblScans

"I'm living so far beyond my income that we may almost be said to be living apart
 
dibbo,

Here's two FAQs that might come in handy for you:

FAQ183-5834
FAQ183-5842

-SQLBill

Posting advice: FAQ481-4875
 
Thanks for the assistance guys...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top