Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-22253 General task tracking improvements for materialized views
  3. HIVE-22259

Rewriting fails for `BETWEEN` clauses with different ranges in MV and query

Log workAgile BoardRank to TopRank to BottomVotersWatch issueWatchersConvert to IssueMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Sub-task
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0.0
    • Component/s: CBO, Materialized views
    • Labels:
      None

      Description

      Script attached.

      The following query does not rewrite:

      create materialized view view9 stored as orc as (select prod_id, cust_id, store_id, sale_date, qty, amt, descr from sales where cust_id >= 1 and prod_id < 31);

       

      – this is not ok

      explain extended select  * from sales where cust_id between 1 and 20 and prod_id < 31;

        Attachments

        1. expr5.sql
          0.9 kB
          Steve Carlin

        Issue Links

          Activity

          $i18n.getText('security.level.explanation', $currentSelection) Viewable by All Users
          Cancel

            People

            • Assignee:
              jcamachorodriguez Jesus Camacho Rodriguez Assign to me
              Reporter:
              scarlin Steve Carlin

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment