Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要连接一行字符串中的所有列。这样的事情可能吗?
SELECT CONCAT_WS(';', *) FROM db.table
桌子:
|col1 |col2 |col3 | ------------------------- |val11 |val12 |val13 | |val21 |val22 |val23 |
结果:
val11;val12;val13 val21;val22;val23
谢谢。