Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error with Money datatypes
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Stored procedures, Triggers, UDFs
Divers
Thread ID:
00781948
Message ID:
00782241
Vues:
19
Hi Allan,

You're welcome.

>Sergey,
>
>Like always - right on the money! Thanks for your assistance yet again.
>
>Al
>
>>Hi Allan,
>>
>>When you concatenate string (char, nchar) with other data types, SQL Server may perform implicit conversion of those types to the char/nchar. In BOL CAST and CONVERT there's a chart that shows all explicit and implicit data type conversions allowed for SQL Server system-supplied data types. According to it, money data type can be converted to nchar only explicitly (CAST or CONVERT).
	(TransactionDetails.AmountMN Between '+
>>         CAST(@LowAmountMN AS nvarchar(32) + ' AND '+
>>         CAST(@HighAmountMN AS nvarchar(32)) + ')' +
I prefer always use explicit conversion so I can control result of it.
>>>
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform