Skip to content

Support Doris distribution hints and share JOIN rendering - #2584

Merged
manticore-projects merged 3 commits into
JSQLParser:masterfrom
minleejae:feat/doris-join-hints
Sep 11, 2026
Merged

Support Doris distribution hints and share JOIN rendering#2584
manticore-projects merged 3 commits into
JSQLParser:masterfrom
minleejae:feat/doris-join-hints

Conversation

@minleejae

Copy link
Copy Markdown
Contributor

With parser.withDialect(Dialect.DORIS), queries such as SELECT * FROM a LEFT JOIN [shuffle] b ON a.id = b.id now parse with a structured JoinHint. Both [shuffle] and [broadcast] are supported, preserving the hint keyword and AFTER_JOIN position.

Keep existing SQL Server hints at BEFORE_JOIN and preserve their constructor behavior. Join and SelectDeParser now share the JOIN/APPLY/STRAIGHT_JOIN keyword, hint and FETCH rendering. The new grammar is dialect-gated and introduces no reserved words, so SQL Server bracket-quoted table names retain their interpretation.

Validation: the complete issue reproducer, join variants, AST round-trips and mutation, table discovery, dialect isolation, existing SQL Server hints and quoted identifiers, and malformed hints; full Gradle check and Maven verify.

Syntax reference: Doris distribution hints.

Fixes #1620.

@manticore-projects
manticore-projects merged commit 78cff6b into JSQLParser:master Sep 11, 2026
9 checks passed
@manticore-projects

Copy link
Copy Markdown
Contributor

Thank you much!

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.

sql contain join [shuffle], so error

2 participants