MySQL and GROUP_CONCAT() maximum length MySQL and GROUP_CONCAT() maximum length mysql mysql

MySQL and GROUP_CONCAT() maximum length


SET SESSION group_concat_max_len = 1000000;

is a temporary, session-scope, setting. It only applies to the current session You should use it like this.

SET SESSION group_concat_max_len = 1000000;select group_concat(column) from table group by column

You can do this even in sharing hosting, but when you use an other session, you need to repeat the SET SESSION command.


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.


Include this setting in xampp my.ini configuration file:

[mysqld]group_concat_max_len = 1000000

Then restart xampp mysql