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 John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

quick convert date to string question

Status
Not open for further replies.

graabein

Programmer
Oct 9, 2002
186
NO
hi,

i've looked around the net for quite some time without finding the solution to this simple task... (i'm quite new to writing stored procedures and i haven't got any manuals), so please help me out:

i want to convert a datetime field to the following string: dd.mm.yy simple as that.

what's the fastest way of doing this?

cheers,
graabein
[afro]
 
I think this will do it...

CONVERT(VARCHAR(10),GETDATE(),104)

Replace GETDATE() with the date field



There are two ways to write error-free programs; only the third one works.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top