Feb 13, 2004 #1 mayu03 Programmer Oct 3, 2003 91 US What is incorrect in this select? select Format('01/01/04','yyyymmdd')
Feb 13, 2004 #2 r937 Technical User Jun 30, 2002 8,847 CA the main thing that's wrong is that there is no such function in sql server and assuming there were, it is not guaranteed that the first parameter will be interpreted as a datetime value, rather than as a character string rudy http://r937.com/ SQL Consulting Upvote 0 Downvote
the main thing that's wrong is that there is no such function in sql server and assuming there were, it is not guaranteed that the first parameter will be interpreted as a datetime value, rather than as a character string rudy http://r937.com/ SQL Consulting
Feb 13, 2004 Thread starter #3 mayu03 Programmer Oct 3, 2003 91 US Can you tell me what function should I use? Upvote 0 Downvote
Feb 13, 2004 #4 r937 Technical User Jun 30, 2002 8,847 CA CONVERT rudy http://r937.com/ SQL Consulting Upvote 0 Downvote
Feb 13, 2004 #5 mimi2 Technical User Apr 2, 2002 407 CA is this ok ? PRINT Convert(Char(20), getdate(), 120) PRINT Convert(Char(20), getdate(), 111) Upvote 0 Downvote