I have a column of usernames I need to export as email addresses to csv. So I need to add the @domain.com after the username. I tried stuff like... UPDATE list SET user = user + '@domain.com' WHERE user = 'john' Code (markup): ...but that sets it to 0. PHP style gives an error: UPDATE list SET user = user . '@domain.com' WHERE user = 'john' Code (markup): Is this actually possible? If numeric additions are possible, string manupilation must be as well, right? Something like the SUBSTRING function but then more like PHPs str_replace I guess. REPLACE does it but not by character position. Any ideas?
You're close, should be UPDATE list SET user = concat(user, "@domain.com") WHERE user = "john" Code (sql):