Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-92

Project should be optimized away, not converted to EnumerableCalcRel

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0.0-incubating
    • Component/s: None
    • Labels:

      Description

      See JdbcTest.testNoCalcBetweenJoins. The plan contains

      ```
      EnumerableJoinRel(condition=[=($33, $37)], joinType=[inner])
      EnumerableCalcRel(expr(#0 | FLINK-0)..36=[

      {inputs}

      ], customer_id=[$t8], account_num=[$t9], lname=[$t10], fname=[$t11], mi=[$t12], address1=[$t13], address2=[$t14], address3=[$t15], address4=[$t16], city=[$t17], state_province=[$t18], postal_code=[$t19], country=[$t20], customer_region_id=[$t21], phone1=[$t22], phone2=[$t23], birthdate=[$t24], marital_status=[$t25], yearly_income=[$t26], gender=[$t27], total_children=[$t28], num_children_at_home=[$t29], education=[$t30], date_accnt_opened=[$t31], member_card=[$t32], occupation=[$t33], houseowner=[$t34], num_cars_owned=[$t35], fullname=[$t36], product_id=[$t0], time_id=[$t1], customer_id0=[$t2], promotion_id=[$t3], store_id=[$t4], store_sales=[$t5], store_cost=[$t6], unit_sales=[$t7])
      EnumerableJoinRel(condition=[=($2, $8)], joinType=[inner])
      ```

      That calc is just a project. It was probably introduced by a SwapJoinRule. It should be expanded away during code generation, but as it stands the EnumerableCalcRel is expensive.

      ---------------- Imported from GitHub ----------------
      Url: https://github.com/julianhyde/optiq/issues/92
      Created by: julianhyde
      Labels:
      Created at: Sat Nov 30 06:17:28 CET 2013
      State: open

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                github-import GitHub Import
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: