Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix(snowflake): allow window to be used as a table alias #2337

Merged
merged 1 commit into from
Sep 27, 2023

Conversation

georgesittas
Copy link
Collaborator

Fixes #2335

It doesn't seem like Snowflake supports Postgres' FROM x WINDOW y AS (...) syntax, e.g. this is invalid in Snowflake:

SELECT SUM(x) OVER a, SUM(y) OVER b FROM c WINDOW a AS (PARTITION BY d), b AS (PARTITION BY e)

I also checked their docs and didn't find an example with WINDOW having special meaning after a table reference in the FROM or JOIN clause.

References:

@tobymao tobymao merged commit 5ea5438 into main Sep 27, 2023
@tobymao tobymao deleted the jo/snowflake_window_as_table_alias branch September 27, 2023 23:23
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.

Parser error for Snowflake SQL when "window" is used as an alias
2 participants