Copy values from one column to another in the same table

前端 未结 7 1649
别那么骄傲
别那么骄傲 2020-12-02 05:08

How can I make a copy values from one column to another? I have:

Database name: list
number | test
123456 | somedata
123486 | somedata1
232344 | 34
         


        
7条回答
  •  -上瘾入骨i
    2020-12-02 05:39

    UPDATE `table_name` SET `test` = `number`
    

    You can also do any mathematical changes in the process or use MySQL functions to modify the values.

提交回复
热议问题