MySQL and GROUP_CONCAT() maximum length

前端 未结 7 980
难免孤独
难免孤独 2020-11-22 15:24

I\'m using GROUP_CONCAT() in a MySQL query to convert multiple rows into a single string. However, the maximum length of the result of this function is 10

7条回答
  •  春和景丽
    2020-11-22 15:45

    The correct parameter to set the maximum length is:

    SET @@group_concat_max_len = value_numeric;
    

    value_numeric must be > 1024; by default the group_concat_max_len value is 1024.

提交回复
热议问题