Mark Green
SSCrazy
Points: 2085
More actions
August 16, 2006 at 11:38 am
#114607
How do I concat the letter 'A' to the start of every string that is found in a column?
PW-201837
SSC-Insane
Points: 20805
August 16, 2006 at 11:43 am
#655310
T-SQL string concatenation simply uses the '+' operator.
SELECT 'A' + YourColumnName
FROM YourTableName
August 16, 2006 at 11:48 am
#655313
Can I put that in an UPDATE statement?
Update: Sorry .... I can .... I need to go to bed I think.
Ray M
Points: 21093
August 16, 2006 at 1:02 pm
#655334
update mytable
set myfield = 'A' + myfield
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply