Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
Original topic: tidb slow log 里面的sql 语句显示不全,是不是有什么参数控制这种行为?
Excuse me, teachers, the SQL statements in the TiDB slow log are not fully displayed. Is there any parameter that controls this behavior? Does the tidb_stmt_summary_max_sql_length
parameter control this behavior?
Try modifying the length of this and test it.
I guess what he means is that it’s still not fully visible. I’ve seen people write SQL with a million lines, so it can never be fully visible.
Sometimes it’s incomplete because the SQL is too long, and generally speaking, overly long SQL is not good. Displaying it is one issue, but it’s better to address it fundamentally. You can view the complete SQL in the slow log and correct it.
Sometimes it’s incomplete because the SQL is too long, and generally speaking, overly long SQL is not good. Displaying it is one issue, but it’s better to address the root cause. You can view the complete SQL in the slow log and correct it.
It’s just that the complete SQL can’t be viewed in the slow log.
What is the purpose of 1 million lines? I’m very curious.
100,000 lines? The entire Redis source code is only tens of thousands of lines!!!
I’ve seen SQL with hundreds of thousands of IN values, probably something similar.
Don’t spoil the developers, take them out and sacrifice them to the heavens.
The parameter tidb_stmt_summary_max_sql_length
controls the display length of SQL queries, and it has been proven.
It shouldn’t be IN, right?
This topic was automatically closed 1 minute after the last reply. No new replies are allowed.