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): preserve TIME type instead of converting it to TIMESTAMP #1685

Merged
merged 1 commit into from
May 24, 2023

Conversation

georgesittas
Copy link
Collaborator

@georgesittas georgesittas commented May 24, 2023

Fixes #1682

Got rid of several type: ignore comments because mypy seems to no longer complain.

The line of interest for #1682 is the following (inside Snowflake's parser):

TIMESTAMPS = parser.Parser.TIMESTAMPS.copy() - {TokenType.TIME}

Also moved some _sql methods inside of the Tableau class instead of having them in TRANSFORMS.

@tobymao tobymao merged commit c567a0b into main May 24, 2023
@tobymao tobymao deleted the jo/snowflake_time branch May 24, 2023 15:39
adrianisk pushed a commit to adrianisk/sqlglot that referenced this pull request Jun 21, 2023
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.

TIME data type is changed to TIMESTAMPNTZ when cast is applied for Snowflake dialect
2 participants