Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Interesting difference in CAST vs CONVERT functions
Message
 
 
À
21/02/2008 07:38:02
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Versions des environnements
SQL Server:
SQL Server 2005
Divers
Thread ID:
01294297
Message ID:
01294708
Vues:
23
>BTW Cast and Convert indeed changes the type because you ask it to do exactly that.
>Cetin

I think I just posted it wrongly. I didn't forget the ) in my original code. The first Insert worked, but the second gave an error. So, I concluded that CAST indeed changed @counter variable type from int to char. But that's strange, I would assume the change of the resulting expression and not of the actual variable.

Or are you saying I probably indeed forgot the ) in the second insert command?

I'll re-check either later today or next days.

UPDATE. I think I indeed just forgot the ) in both insert statements. Strange that the first worked, though.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform