insert multiple data with data already in db

1

Well, I'm having a problem adding values in db. I want to add a value in a field that already has a value, without deleting the value that is there, but joining the two values separated by a comma. I know it has something to do with implode, but I've tried a lot of things and it does not work.

    
asked by anonymous 14.09.2017 / 20:08

1 answer

2

I think this resolves:

UPDATE tabela SET coluna = CONCAT(coluna , ',' , novovalor) WHERE coluna = x

    
14.09.2017 / 20:32