Home > database >  About the length of the mysql temporary field.
About the length of the mysql temporary field.

Time:09-17

Met, ladies and gentlemen, today I met a problem when I do SQL stitching,
Check out of the results will be truncated, the SQL statement is no problem, in shorter data content, can complete the query, but long content, will be cut off part of
Ask next bosses encountered this problem?

SELECT
GROUP_CONCAT (DISTINCT
CONCAT (
'MAX (IF (time2=' ' ',
Time2,
"' checkNum, 0)) AS the ' ' ',
Time2, '"'
)
) INTO @ SQL

CodePudding user response:


This field is complete, the following fields is not complete, there will be a part of the content of the show not to come out,

CodePudding user response:

If limit the length of the temporary field, but also should not be so small?

CodePudding user response:

refer to the second floor qq_41462501 response:
is limiting the length of the temporary field, but also should not be so small?
is limit the length of the temporary field, don't know how to change the length limit,

CodePudding user response:

Using group_concat function, the default length of 1024, if you need more length, will need to modify the configuration file manually group_concat_max_len system variables,

CodePudding user response:

The
reference 5 floor fly_flsh response:
use group_concat functions, the default length of 1024, if you need more length, just need to modify the configuration file manually group_concat_max_len system variables,


Thank you! I took so many days, your method is useful, everything else is what all don't know

CodePudding user response:

To perform this first two:
The SET GLOBAL group_concat_max_len=102400;
SET the SESSION group_concat_max_len=102400;
Reference:
https://blog.csdn.net/uotail/article/details/89503927
  • Related