mysql中列转行,并多个字段转到一行中的一个字段上,中间用逗号分开
SELECT
group_concat(a.id SEPARATOR ',') AS ids
FROM
(
SELECT
*
FROM
tablename
WHERE
1 = 1
ORDER BY
rand()
LIMIT 10
) a
标签:转行,中列,逗号,字段,mysql,SELECT From: https://blog.51cto.com/u_9716826/6235246