September 22, 2005 at 4:40 am
I'm trying to concatenate the value of 2 varchar fields in the DTS source to a single field in the destination. Example: Select Lname + ', ' + Fname as Name. I'm getting an error that the + token is invalid. It works fine in query analyzer. What am I missing?
September 22, 2005 at 6:09 am
If you are writing the code as part of an ActiveX script, the & character is used to concatenate strings, not + (just to keep you on your toes)!
September 22, 2005 at 10:46 am
It was in a "copy column" task. I had tried using the & character also but it failed. I think the problem might be that my source is a DB2 table and the SQL must not support concatenation with its fields. I'm not familiar with the ActiveX script, but maybe I'll look into that and see if I can get it to work that way. Thanks.
September 22, 2005 at 1:04 pm
Dan,
You could import into a "staging" table with separate name columns, then concatenate as you move the data from there to your "real" table.
Greg
Greg
September 27, 2005 at 4:10 am
Thanks Greg. That's the solution I'll use!
Viewing 5 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy