Dan Zou created CALCITE-5777:
--------------------------------

             Summary: Simplify 'OperandTypes.STRING.or(OperandTypes.BINARY)' to 
'OperandTypes.STRING'
                 Key: CALCITE-5777
                 URL: https://issues.apache.org/jira/browse/CALCITE-5777
             Project: Calcite
          Issue Type: Bug
            Reporter: Dan Zou


We have used 'OperandTypes.STRING.or(OperandTypes.BINARY)' multiple times as 
the SqlOperandTypeChecker in 'SqlLibraryOperators'. But this is not reasonable, 
as the STRING family already contains BINARY family, which means we could 
simplify 'OperandTypes.STRING.or(OperandTypes.BINARY)' to 'OperandTypes.STRING'.

{code:java}
  // From 'SqlTypeName'
  public static final List<SqlTypeName> STRING_TYPES =
      combine(CHAR_TYPES, BINARY_TYPES);
{code}




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

Reply via email to