Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-12487

Introduce planner rules to rewrite expression and merge calc

    XMLWordPrintableJSON

Details

    Description

      This issue aims to introduce planner rules to rewrite expression and merge calc, rules include:
      1. ConvertToNotInOrInRule, that converts a cascade of predicates to IN or NOT_IN,
      e.g.
      converts predicate (x = 1 OR x = 2 OR x = 3 OR x = 4) AND y = 5 to predicate x IN (1, 2, 3, 4) AND y = 5
      converts predicate (x <> 1 AND x <> 2 AND x <> 3 AND x <> 4) AND y = 5 to predicate x NOT IN (1, 2, 3, 4) AND y = 5
      2. RewriteCoalesceRule, that rewrites Coalesce to Case When
      3. FlinkCalcMergeRule, that is copied from Calcite CalcMergeRule, and it will simplify the merged program

      Attachments

        Issue Links

          Activity

            People

              godfreyhe godfrey he
              godfreyhe godfrey he
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m