update field - add more data after last character
Posted on 2012-09-11
I know how to use the Update command to update a field with new information, but what if I want to add info to the field after the last character.
For Example, I have a string field were we store email addresses. I want to update a this field for a bunch of records, but I don't want to overwrite the data, instead I need to add to it at the end of the field. The existing data for each record will be different, so is important to leave the existing data alone and just add to it.
modifiy the current email field from this:
investor.i_email = firstname.lastname@example.org
investor.i_email = email@example.com; firstname.lastname@example.org
I know that for updating this field I would use the following command line argument:
UPDATE investor set i_email="email@example.com" WHERE taxid='11-1111111'
My guess is that to add to this field it would be just as simple but with a different command?
I tried the following but it did not work:
UPDATE investor set i_email = i_email + ';firstname.lastname@example.org' WHERE taxid='11-1111111'