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

Filters wrongly pushed into full outer join

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.9.2-incubating
    • None
    • None

    Description

      Filter R1.x=10 (R1 full outer join R2 on R1.y=R2.y)
      Gets rewritten as
      R1 left outer join R2 on R1.y=R2.y and R1.x=10.

      This is obviously wrong and produces wrong result.

      select count from(select ss.ss_sold_date_sk, ss.ss_item_sk, ss.ss_customer_sk from store_sales ss full outer join date_dim d on ss.ss_sold_date_sk = d.d_date_sk where ss.ss_item_sk = 4496)R;
      produces wrong result due to above described problem.

      Patch separates the join simplification from Join filter classification.
      Predicate Push Down through Join would first simplify Outer Joins before applying predicate push down.

      Attachments

        1. CALCITE-444.1.patch
          18 kB
          Laljo John Pullokkaran
        2. CALCITE-444.patch
          16 kB
          Laljo John Pullokkaran

        Activity

          People

            jpullokkaran Laljo John Pullokkaran
            jpullokkaran Laljo John Pullokkaran
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: