Skip to content

Parse new ClickHouse 26.x syntax (batch 4) - #131

Merged
kyleconroy merged 8 commits into
claude/project-thread-8e2oya-syntax-3from
claude/project-thread-8e2oya-syntax-4
Dec 1, 2026
Merged

kyleconroy merged 8 commits into
claude/project-thread-8e2oya-syntax-3from
claude/project-thread-8e2oya-syntax-4

Conversation

@kyleconroy

Copy link
Copy Markdown
Collaborator

Requested by Kyle · project thread

Summary

Fourth batch of ClickHouse 26.8 syntax and EXPLAIN AST changes, stacked on batch 3. Pending explain statements drop from 2,628 to 2,038.

  • CREATE FUNCTION ... LANGUAGE WASM (module, source function, ARGUMENTS, RETURNS, SHA256_HASH, ABI, DETERMINISTIC, SETTINGS).
  • Projection INDEX ... TYPE ..., WHERE and WITH SETTINGS, plus ALTER TABLE ... MODIFY PROJECTION.
  • OPTIMIZE ... DRY RUN [PARTS ...], MANIFEST and DEDUPLICATE BY.
  • IS [NOT] DISTINCT FROM and IS [NOT] TRUE/FALSE now print as isDistinctFrom / isNotDistinctFrom; IS [NOT] UNKNOWN prints as isNull / isNotNull.
  • Typed JSON paths print as ObjectTypedPath.
  • Storage ORDER BY with any DESC element wraps every element in StorageOrderByElement; ORDER BY (x ASC) stays a plain tuple.
  • x IN () prints an empty ExpressionList without a children count.
  • Parenthesized single SELECT operands of INTERSECT/EXCEPT are unwrapped, matching 26.x.
  • gofmt on the touched packages.

Test Plan

  • go test ./parser/... -timeout 30s passes.
  • Ran go test ./parser/... -check-explain and committed the updated metadata.json files.
  • Spot-checked each construct against a local ClickHouse 26.8 server's EXPLAIN AST.

Generated by Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LuRZ4KB7DMX365Nmn5ksnY
Also orders the OptimizeQuery name suffixes as ClickHouse does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LuRZ4KB7DMX365Nmn5ksnY
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LuRZ4KB7DMX365Nmn5ksnY
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LuRZ4KB7DMX365Nmn5ksnY
@kyleconroy kyleconroy self-assigned this Dec 1, 2026
@kyleconroy
kyleconroy added this pull request to stack #128 December 1, 2026 05:30
@kyleconroy
kyleconroy merged commit 1edd82e into main Dec 1, 2026
1 check passed
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.

2 participants