在我的表格中有 4 列
Product_id1 Product_id2 Product_id3 Product_id4
2 4 5 5
3 2 1 6
我想要这样的东西
Product_id
2,4,5,5
3,2,1,6
想不出该怎么做?
最佳答案
您可以使用mySQL concat函数
http://dev.mysql.com/doc/refman/5.0/en/string-functions.html#function_concat-ws
关于mysql - mysql 中如何将多列中的值合并为一列?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22877558/