22477 浏览
喜欢(11)

MYSQL 获取某个表的各列名(字段名)并以逗号分隔(隔开)连接

MYSQL 获取某个表的各列名(字段名)并以逗号连接:SELECT GROUP_CONCAT( COLUMN_NAME SEPARATOR "," ) FROM information_schema.COLUMNSWHERE TABLE_SCHEMA = 'YOUR_DATABASE'AND TABLE_NAME = 'YOUR_TABLE'

MySQL 2014-07-22 14:53 0评论 0收藏
AD 友情赞助