I get the following message with this code
case when substring(New_Limit,11,1)=' ' then '0'+substring(New_Limit,1,10)
The 'then' bit is meant to concat the 0 and substring. Any help?
This means that your New_Limit
variable is a numeric value. You may want to put a CAST
to (n)varchar around it.
You try to cast it to a string type (varchar) first:
SUBSTRING(CAST(New_Limit AS varchar(38)), 11, 1)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With