Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date Conversion
Message
De
28/06/2004 19:46:35
 
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Titre:
Date Conversion
Divers
Thread ID:
00918203
Message ID:
00918203
Vues:
34
I am having trouble with converting dates. I get the following message:

"Server: Msg 241, Level 16, State 1, Procedure sp_fy_gen, Line 31
Syntax error converting datetime from character string."

Part of Code below

"@tcp is the input parameter"

Declare @string varchar(12),
@bofy datetime

if month(tcp) > 9
set @string = '10/01/' + str(year(tcp))
set bofy = convert(datetime, @string, 101)
end if
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform