-
Notifications
You must be signed in to change notification settings - Fork 1k
feat(snowflake): add type annotation for DECODE function support #6199
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(snowflake): add type annotation for DECODE function support #6199
Conversation
|
Decode function support is already available . added support to return type annotation for DECODE function. |
The annotation now determines the output type based solely on the return values (ret1, ret2, ..., default), ignoring comparison values.
VaggelisD
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a tough function to annotate, nice work! Leaving a few comments:
…implemented. Fixed the annotate_decode_case function to identify the returntype based on default param and added more tests
georgesittas
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's also add a DECODE(x, 1, 100, NULL) test case, see #6211 (review).
…Snowflake DECODE to verify correct type inference when one branch is NULL
…ents implemented.
…ents implemented.
georgesittas
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, thanks for addressing all comments @fivetran-ashashankar!
No description provided.