MySQL返回列名

SELECT GROUP_CONCAT(COLUMN_NAME SEPARATOR "+") FROM information_schema.COLUMNS
WHERE TABLE_SCHEMA = 'db_name' AND TABLE_NAME = 'tbl_name'

猜你喜欢

转载自www.cnblogs.com/annofyf/p/9925183.html