Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Converting Date
Message
From
13/06/2008 11:23:04
 
 
To
13/06/2008 11:18:53
Jay Johengen
Altamahaw-Ossipee, North Carolina, United States
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Title:
Miscellaneous
Thread ID:
01323855
Message ID:
01323857
Views:
28
>
>	QUOTENAME (cast(DOB as varchar(254)),'"') AS DOB,
>
>
>This is the result of running the SQL:
>
>"Nov 14 1965 12:00AM"
>
>
>I need it like this:
>
>"19651114"
>
Take a look in CONVERT function in BOL
DECLARE @test DateTime
SET @TEst = GETDATE()

SELECT CONVERT(varchar(8),@Test,112)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform