That's not a bug, this is how SQL works. Any expression (concatenation) involving NULL
returns NULL
.
You can either use coalesce()
to make sure that city
is not null or use the concat()
function which treats NULL
similar to an empty string:
UPDATE table
SET empresa = concat('NOMBRE ', city);