Skip to content

Snowflake: Parse structured ARRAY types - #2488

Open
osipovartem wants to merge 2 commits into
apache:mainfrom
Embucket:upstream-snowflake-structured-array
Open

osipovartem wants to merge 2 commits into
apache:mainfrom
Embucket:upstream-snowflake-structured-array

Conversation

@osipovartem

Copy link
Copy Markdown
Contributor

Snowflake supports structured ARRAY types such as ARRAY(VARCHAR), while the parser currently treats ARRAY as untyped and leaves the parenthesized type unconsumed.

This adds a dialect capability for ARRAY(element_type), enables it for Snowflake and ClickHouse, and parses it into ArrayElemTypeDef::Parenthesis. Existing ClickHouse behavior is preserved.

Validated against:
https://docs.snowflake.com/en/sql-reference/data-types-structured#label-structured-types-array

Tests cover CREATE TABLE and CAST round trips.

AI assistance: Codex was used to prepare the implementation and tests.

@osipovartem
osipovartem force-pushed the upstream-snowflake-structured-array branch from 31f4dc7 to 029d304 Compare September 22, 2026 22:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants