From d3d30f5f556e826ae5ec2d25c8d8fd6b9412e72a Mon Sep 17 00:00:00 2001 From: Jack Yu Date: Sat, 9 Sep 2023 00:18:06 +0800 Subject: [PATCH] session: add debug log for parsing (#46638) close pingcap/tidb#46637 --- session/session.go | 1 + 1 file changed, 1 insertion(+) diff --git a/session/session.go b/session/session.go index 8a3fcf5159031..278d5519804d3 100644 --- a/session/session.go +++ b/session/session.go @@ -1678,6 +1678,7 @@ func (s *session) Execute(ctx context.Context, sql string) (recordSets []sqlexec // Parse parses a query string to raw ast.StmtNode. func (s *session) Parse(ctx context.Context, sql string) ([]ast.StmtNode, error) { + logutil.Logger(ctx).Debug("parse", zap.String("sql", sql)) parseStartTime := time.Now() stmts, warns, err := s.ParseSQL(ctx, sql, s.sessionVars.GetParseParams()...) if err != nil {