Skip to content

feat(syntax): structure Snowflake EXECUTE IMMEDIATE and verify 288 more forms - #221

Merged
kvlonge merged 4 commits into
mainfrom
feat/syntax-pool-22
Nov 13, 2026
Merged

kvlonge merged 4 commits into
mainfrom
feat/syntax-pool-22

Conversation

@kvlonge

@kvlonge kvlonge commented Nov 13, 2026

Copy link
Copy Markdown
Contributor

Why

930 Snowflake forms were unverified; most needed only an independent review, and EXECUTE IMMEDIATE was an opaque command no obligation accepts.

Changes

  • EXECUTE IMMEDIATE parses into a structured node (source, FROM, USING, DRY_RUN). It ends at ; or before ), so r := ( ... ) works.
  • CREATE NOTEBOOK project QUERY_WAREHOUSE = ... parses; ALTER WAREHOUSE IF EXISTS with no name refuses ADD/DROP, RENAME and TAG.
  • SHOW reads a lone APPLICATION or CLASS after IN, or a grantee kind ending GRANTS TO|OF, as a name. Snowflake answers IN CLASS ; as IN v1 (2003), not as IN CLASS v1 (398014).
  • 293 reviews recorded, bound to fingerprints.

Verification

  • Verified forms: 2,421 to 2,709 of 3,351 (+288). Obligations met: 84,591 to 84,653 of 91,182.
  • Fresh reviewers, not the author: 293 approved, 41 rejected.
  • 10 approvals I spot-checked against the docs and trees: alter-task, postgres reset/suspend, replication group, alter application, table LIKE, iceberg clone, masking/row, app spec, masking policy.
  • Held: 3 SYSTEM$ preview/privatelink forms stay unverified. No batch here; the EXECUTE IMMEDIATE FROM stage replacements go to the next batch.
  • Coverage diff: nothing lost, disagreements stay 583. One diff review; its two findings (call/cast sources, the parenthesised form in RETURN) are fixed and confirmed. make check-ci passes on the final head.

EXECUTE IMMEDIATE was kept as opaque command text. It now parses into an
ExecuteImmediate node: the source (a string, a bound or session variable,
a variable name, or a || concatenation of them, or the location after
FROM), the USING variables or named arguments, and DRY_RUN. It ends at the
statement end or before a ) closing an enclosing assignment, so a RESULTSET
and a plain := assignment can take it in parentheses.
…d ALTER WAREHOUSE IF EXISTS

A notebook may be named PROJECT when a property assignment follows its
name, as in CREATE NOTEBOOK project QUERY_WAREHOUSE = w1. ALTER WAREHOUSE
IF EXISTS with no name now refuses the actions that need a name, as the
unnamed form already did.
…ake SHOW as a name

Snowflake reads SHOW TABLES IN APPLICATION ; and SHOW GRANTS TO ROLE ; as
naming a schema or grantee called APPLICATION or ROLE. They answer the
errors IN v1 and TO v1 answer, not the ones a named container gives, and
the kinds that take no plain name refuse the bare word. The tree now names
the word instead of recording a container kind with no name.
…ke forms

Each form was read against its documentation page, obligations, cases
and parse trees by a reviewer other than the parser's author, and is
bound to its fingerprint and definition. 288 forms become verified
(2,421 to 2,709); 41 reviewed forms were rejected and stay unverified.
@kvlonge
kvlonge enabled auto-merge November 13, 2026 14:25
@kvlonge
kvlonge added this pull request to the merge queue Nov 13, 2026
Merged via the queue into main with commit 239fe25 Nov 13, 2026
9 checks passed
@kvlonge
kvlonge deleted the feat/syntax-pool-22 branch November 13, 2026 15:40
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