-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Support functionc call rewrite by Presto Verifier #22783
Conversation
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.
Nice work, thanks! Nits of formatting suggested to improve readability.
Hi @steveburnett , I revised the .rst doc based on my understanding of the comments. Let me know if I miss anything. |
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.
Looks good! One tiny nit.
where ``foo(c0, _)`` would be substituted by ``bar(c0)``, | ||
with the declared arguments applied to the corresponding positions. | ||
|
||
Concatenate function substitutions with comma. |
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.
Concatenate function substitutions with comma. | |
Concatenate function substitutions with a comma. |
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.
Revised
154a141
to
20d3a04
Compare
Enable Presto Verifier to substitute function call expressions in a source query, according to the user specified substitution pattern, by the config function-substitutes. Support function call substitutions when rewriting Query, CreateTableAsSelect and Insert source queries.
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.
LGTM! (docs)
Pull updated branch, new local build, everything looks good. Thanks!
Description
Enable Presto Verifier to substitute function call expressions in a source query, according to the user specified substitution pattern, by the config function-substitutes. Support function call substitutions when rewriting Query, CreateTableAsSelect and Insert source queries.
Motivation and Context
Allow the Presto Verifier users to substitute functions, ex., nondeterministic functions, to make the test query comparable with TEST and CONTROL.
Impact
The feature is enabled only when the parameter --function-substitutes is set.
Test Plan
Unit tests in TestQueryRewriter.
Release Notes