osdir.com

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[jira] [Created] (CALCITE-2604) When simplifying an expression, say whether an UNKNOWN value will be interpreted as is, or as TRUE or FALSE


Julian Hyde created CALCITE-2604:
------------------------------------

             Summary: When simplifying an expression, say whether an UNKNOWN value will be interpreted as is, or as TRUE or FALSE
                 Key: CALCITE-2604
                 URL: https://issues.apache.org/jira/browse/CALCITE-2604
             Project: Calcite
          Issue Type: Task
            Reporter: Julian Hyde
            Assignee: Julian Hyde


When simplifying an expression, say whether an UNKNOWN value will be interpreted as is, or as true or false. Concretely, this means adding an {{enum RexUnknownAs}} with values {{TRUE}}, {{FALSE}}, {{UNKNOWN}}, and adding it as an argument to {{RexSimplify.simplify}} and similar methods.

Currently {{RexSimplify}} has a constant field {{boolean unknownAs}} but this is a mistake: the handling of unknown must change as you recurse into the tree. For example, if an {{UNKNOWN}} result of {{NOT x}} is interpreted as {{FALSE}}, then an {{UNKNOWN}} result of {{x}} must be interpreted as {{TRUE}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)