Register missing SQL V2 relevance functions in Calcite function table#5440
Conversation
…on table Add SQL V2 relevance functions (query, wildcard_query, score, scorequery) and aliases (match_query, matchquery, matchphrase, matchphrasequery, multimatch, multimatchquery) to PPLFuncImpTable so CalciteRelNodeVisitor can resolve them when processing RelNodes generated by SQL V2 AstBuilder. Signed-off-by: Chen Dai <daichen@amazon.com>
PR Reviewer Guide 🔍(Review updated until commit 064092d)Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Latest suggestions up to 48f2911
Previous suggestionsSuggestions up to commit f01a6cb
|
f01a6cb to
48f2911
Compare
|
Persistent review updated to latest commit 48f2911 |
… function table Add SQL V2 relevance functions and aliases to PPLFuncImpTable so CalciteRelNodeVisitor can resolve them from SQL V2 AstBuilder. Aliases normalize to canonical operators (e.g. matchquery -> match). New functions: query, wildcard_query Aliases: wildcardquery, match_query, matchquery, matchphrase, matchphrasequery, multimatch, multimatchquery Not included: score/scorequery/score_query (needs dedicated visitor). Signed-off-by: Chen Dai <daichen@amazon.com>
48f2911 to
064092d
Compare
|
Persistent review updated to latest commit 064092d |
Description
Register missing SQL V2 relevance functions in
PPLFuncImpTableso the Calcite engine inUnifiedQueryPlannercan resolve them when processingRelNodesfrom the SQL V2 AST.Function Support Matrix
score/scorequery/score_queryproduce aScoreFunctionAST node (wrapper around inner relevance function) requiring dedicated visitor handling — not standard function table resolution.PredicateAnalyzerpushdown handlers for the new functions are not yet implemented. These functions are only reachable from SQL (PPL grammar does not expose them).Planned PRs
CalciteRelNodeVisitorissues identified during V2 AST integrationRelated Issues
Part of #5248; Related to #5279
Check List
--signoffor-s.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.