Skip to content

Commit

Permalink
session: add debug log for parsing (#46638)
Browse files Browse the repository at this point in the history
close #46637
  • Loading branch information
jackysp committed Sep 8, 2023
1 parent 0eb4560 commit d3d30f5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions session/session.go
Expand Up @@ -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 {
Expand Down

0 comments on commit d3d30f5

Please sign in to comment.