Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-19073

StatsOptimizer may mangle constant columns

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.2.2
    • 3.0.0
    • Physical Optimizer
    • None

    Description

      Following query is giving wrong result:

      SELECT DATE_SUB(CURRENT_DATE,0) as GROUP_BY_FIELD, count (*)  as src_cnt from mytable WHERE 1=1 group by DATE_SUB(CURRENT_DATE,0);
      +-----------------+----------+--+
      | group_by_field  | src_cnt  |
      +-----------------+----------+--+
      | 239             | NULL     |
      +-----------------+----------+--+
      1 row selected (5.175 seconds)
      

      Attachments

        1. HIVE-19073.patch
          2 kB
          jcamachorodriguez

        Activity

          People

            jcamacho Jesús Camacho Rodríguez
            jcamacho Jesús Camacho Rodríguez
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: