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

Feat(redshift): parse GETDATE #2904

Merged
merged 1 commit into from
Feb 2, 2024
Merged

Conversation

erickpeirson
Copy link
Contributor

This adds GETDATE to the parser for Redshift.

Copy link
Collaborator

@georgesittas georgesittas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good but let's test this as well. Thanks :)

@georgesittas georgesittas changed the title Parse GETDATE in Redshift Feta: parse GETDATE in Redshift Feb 2, 2024
@georgesittas georgesittas changed the title Feta: parse GETDATE in Redshift Feat(redshift): parse GETDATE Feb 2, 2024
@georgesittas georgesittas merged commit 3fa92ca into tobymao:main Feb 2, 2024
5 checks passed
@erickpeirson
Copy link
Contributor Author

Looks good but let's test this as well. Thanks :)

@georgesittas Adding some tests now. Quick question: I noticed that exp.CurrentTimestamp renders as SYSDATE for Redshift. There is a subtle difference between GETDATE and SYSDATE in that the former returns the timestamp at the start of the transaction (if there is one), whereas SYSDATE does not. Many other dialects have isomorphic functions.

I don't want to get too ambitious, but I'm wondering whether we should better distinguish between these with distinct expression types? E.g. CurrentTimestamp versus CurrentSystemTimestamp?

@erickpeirson
Copy link
Contributor Author

Oh whoops, didn't notice that you had already merged; can address this in a separate PR. But still wondering about ☝️

@erickpeirson
Copy link
Contributor Author

I'll take #2909 as my answer :-)

@georgesittas
Copy link
Collaborator

Hah!

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.

None yet

2 participants