Thursday, January 3, 2013

How to increase GROUP_CONCAT function length in MySQL

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 1024 characters.

 I'm very well aware that I can change the param group_concat_max_len to increase this limit:

SET SESSION group_concat_max_len = 1000000;

Above is set for SESSION

SET GLOBAL group_concat_max_len = 1000000;

above is set for GLOBAL

ref :-


  1. attractive piece of information, I had come to know about your blog from my friend arjun, ahmedabad,i have read atleast eleven posts of yours by now, and let me tell you, your website gives the best and the most interesting information. This is just the kind of information that i had been looking for, i'm already your rss reader now and i would regularly watch out for the new posts, once again hats off to you! Thanks a lot once again, Regards, Single Row Function in sql

  2. Nilesh, Thanks this information helped me.

  3. You saved mine too! Thanks,
    Emanuele (Italy)

  4. Thanks for your post. It helped me a lot with a clients wish to Export his data into a XML File where I had to store records from another table into one field. And it was allways only 1024 long.


Create MongoDB service in Windows OS

1) Open Command Prompt 2) Create directory for Database and Logs                    mkdir c:\data\db                     mkdir c:\...