Last Updated: May 28, 2016
·
150
· sivaschenko

Merging (concatenating) two values from one table

Sql for merging two fields text content into one field on the same table:

update thetable as firstpart join thetable as secondpart on firstpart.id = secondpart.id set firstpart.value = concat(firstpart.value, 'glue', secondpart.value) where firstpart.condition = 1 and secondpart.condition = 2;