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
IGNITE-20294 Sql. Using UDF as a place for system_range function #3666
base: main
Are you sure you want to change the base?
Conversation
|
||
/** Creates a {@link org.apache.calcite.schema.impl.TableFunctionImpl} from a class, looking for an "eval" | ||
* method. Returns null if there is no such method. */ | ||
public static @Nullable TableFunction create(Class<?> clazz) { |
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.
why do we need this method (and the following)?
p.s. I see "for eval" but can't figure out what's not working 😔
* @param name name of the method to find | ||
* @return the first method with matching name or null when no method found | ||
*/ | ||
static @Nullable Method findMethod(Class<?> clazz, String name) { |
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.
is it possible to use this method in RexToLixTranslator and remove the same method from RexToLixTranslator?
or move it to some utility-class?
super( | ||
"SYSTEM_RANGE", | ||
new SqlIdentifier(funcName, SqlParserPos.ZERO), |
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.
What is a point of making a function name configurable, if this function can only used for a system range function?
* Implementation of {@link org.apache.calcite.schema.TableFunction} based on a | ||
* method. | ||
*/ | ||
public class TableFunctionImpl extends ReflectiveFunctionBase |
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.
Why this one is copied? How it differs from calcite's TableFunctionImpl?
Thank you for submitting the pull request.
To streamline the review process of the patch and ensure better code quality
we ask both an author and a reviewer to verify the following:
The Review Checklist
- There is a single JIRA ticket related to the pull request.
- The web-link to the pull request is attached to the JIRA ticket.
- The JIRA ticket has the Patch Available state.
- The description of the JIRA ticket explains WHAT was made, WHY and HOW.
- The pull request title is treated as the final commit message. The following pattern must be used: IGNITE-XXXX Change summary where XXXX - number of JIRA issue.
Notes