Probably cause someone may want to add +44 etc, or maybe 0800 REVERSE ...
"This e-mail is from Reed Exhibitions (Oriel House, 26 The Quadrant,
Richmond, Surrey, TW9 1DL, United Kingdom), a division of Reed Business,
Registered in England, Number 678540. It contains information which is
confidential and may also be privileged. It is for the exclusive use of the
intended recipient(s). If you are not the intended recipient(s) please note
that any form of distribution, copying or use of this communication or the
information in it is strictly prohibited and may be unlawful. If you have
received this communication in error please return it to the sender or call
our switchboard on +44 (0) 20 89107910. The opinions expressed within this
communication are not necessarily those expressed by Reed Exhibitions."
Visit our website at http://www.reedexpo.com
From: Lee Fortnam
To: 'database programming'
Sent: Tue Sep 26 08:27:32 2006
Subject: RE: [CF-Database] String Concatenation
Should have spotted that!!!
Nick, why would you use a character column in particular?
> I have a stored procedure where I am passing a var called @SMSCancel
> I need to pass this along with some other text into a nvarchar field,
> at the moment I have the following in my SP:
> -- insert the sponsor message
> INSERT INTO
> (ClientID, SponsorText)
> (@LocationID, 'To stop alerts, text No to +' + @SMSCancel + '.')
String concatenation only works on strings, therefore you have to CONVERT or
CAST your integer to a string.
@LocationID, 'To stop alerts, text No to +' + CAST(@SMSCancel AS char(12)) +
FWIW I would normally define a phone number as a character column in the
>- cfdeveloper Hosting provided by www.cfmxhosting.co.uk -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<