Skip to content

Fix SQL parser bugs: PG ANALYZE loop, FOR XML, UNION alias, COLLATE, DM IDENTITY#6625

Open
wenshao wants to merge 3 commits intomasterfrom
fix/sql-parser-bugs-6595-6564-6572-6573-6583
Open

Fix SQL parser bugs: PG ANALYZE loop, FOR XML, UNION alias, COLLATE, DM IDENTITY#6625
wenshao wants to merge 3 commits intomasterfrom
fix/sql-parser-bugs-6595-6564-6572-6573-6583

Conversation

@wenshao
Copy link
Copy Markdown
Member

@wenshao wenshao commented Mar 23, 2026

Summary

Test plan

  • Added Issue6595 test: 5 cases (ANALYZE bare, VERBOSE, SKIP_LOCKED, combined, with table)
  • Added Issue6564 test: 3 cases (FOR XML PATH+TYPE, AUTO, PATH+ELEMENTS)
  • Added Issue6572 test: 2 cases (single/multiple column aliases on UNION subquery)
  • Added Issue6573 test: 3 cases (simple COLLATE, double-quoted COLLATE, ::text COLLATE)
  • Added DM_IdentityTest: 2 cases (IDENTITY with PRIMARY KEY, with NOT NULL)
  • Full core test suite: 6004 tests passed, 0 failures, 0 errors
  • PostgreSQL tests: 65 passed
  • SQL Server tests: 8 passed

🤖 Generated with Claude Code

wenshao and others added 3 commits December 12, 2024 10:31
- Fix PostgreSQL ANALYZE VERBOSE/SKIP_LOCKED infinite loop by adding EOF guard
- Fix SQL Server FOR XML PATH output: off-by-one error losing first option and duplicate FOR XML prefix
- Fix PostgreSQL AS table_name(column_name) syntax for UNION subqueries being rejected as SQL injection
- Fix PostgreSQL ORDER BY COLLATE clause lost after ::text cast by extracting collate from charType
- Fix DM (达梦) IDENTITY(1,1) parse failure by adding IDENTITY keyword and parseColumnRest handling

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant