mysql的group_concat函数查询结果默认长度1024,超出部门将自动截取,只保留前半部分
解决方法一:
在mysql的配置文件“my.ini”或“my.conf”加上以下语句,然后重启mysql服务即可:
group_concat_max_len=102400
如果这个值设为-1,表示为最大值(4294967295)
解决方法二:
执行以下sql语句:
SET GLOBAL group_concat_max_len=102400;
SET SESSION group_concat_max_len=102400;