mysql 字串号以逗号分隔,分隔后第个字符加单引号,而后再拼接起来,字符间用逗号

select channel from tb_user where id='1';
获得如下结果
+-----------+
| channel   |
+-----------+
| 4,5,6,7,8 |
+-----------+
我想要个结果是
+-----------+
| channel   |
+-----------+
| '4','5','6','7','8' |
+-----------+
select replace(concat('''',channel,''''),',',''',''') from tb_user where id='1';这样么

追问:select

结果是
| replace(concat('''',channel,''''),',',''',''') |
+------------------------------------------------+
| '4','5','6','7','8'
我只要| '4','5','6','7','8' | 这一行channel

相关文章
相关标签/搜索