Feng Jin created FLINK-34312:
--------------------------------

             Summary: Improve the handling of default node types when using 
named parameters.
                 Key: FLINK-34312
                 URL: https://issues.apache.org/jira/browse/FLINK-34312
             Project: Flink
          Issue Type: Sub-task
            Reporter: Feng Jin


Currently, we have supported the use of named parameters with optional 
arguments. 

By adapting the interface of Calcite, we can fill in the default operator when 
a parameter is missing. Whether it is during the validation phase or when 
converting to SqlToRel phase, we need to handle it specially by modifying the 
return type of DEFAULT operator based on the argument type of the operator.  
We have multiple places that need to handle the type of DEFAULT operator, 
including SqlCallBinding, SqlOperatorBinding, and SqlToRelConverter.


The improved solution is as follows: 

Before SqlToRel, we can construct a DEFAULT node with a return type that 
matches the argument type. This way, during the SqlToRel phase, there is no 
need for special handling of the DEFAULT node's type.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to