Hive
  1. Hive
  2. HIVE-7067

Min() and Max() on Timestamp and Date columns for ORC returns wrong results

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.14.0, 0.13.1
    • Component/s: None
    • Labels:
      None

      Description

      min() and max() of timestamp and date columns of ORC table returns wrong results. The reason for that is when ORC creates object inspectors for date and timestamp it uses JAVA primitive objects as opposed to WRITABLE objects. When get() is performed on java primitive objects, a reference to the underlying object is returned whereas when get() is performed on writable objects, a copy of the underlying object is returned.

      Fix is to change the object inspector creation to return writable objects for timestamp and date.

      1. HIVE-7067.1.patch
        28 kB
        Prasanth Jayachandran
      2. HIVE-7067.2.patch
        31 kB
        Prasanth Jayachandran
      3. HIVE-7067.branch-13.2.patch
        31 kB
        Prasanth Jayachandran

        Issue Links

          Activity

          Prasanth Jayachandran created issue -
          Prasanth Jayachandran made changes -
          Field Original Value New Value
          Attachment HIVE-7067.1.patch [ 12644932 ]
          Prasanth Jayachandran made changes -
          Status Open [ 1 ] Patch Available [ 10002 ]
          Prasanth Jayachandran made changes -
          Remote Link This issue links to "Review Board (Web Link)" [ 15075 ]
          Prasanth Jayachandran made changes -
          Priority Major [ 3 ] Critical [ 2 ]
          Prasanth Jayachandran made changes -
          Attachment HIVE-7067.2.patch [ 12644976 ]
          Prasanth Jayachandran made changes -
          Attachment HIVE-7067.branch-13.2.patch [ 12645129 ]
          Prasanth Jayachandran made changes -
          Status Patch Available [ 10002 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Prasanth Jayachandran made changes -
          Fix Version/s 0.14.0 [ 12326450 ]
          Sushanth Sowmyan made changes -
          Fix Version/s 0.13.1 [ 12326829 ]
          Thejas M Nair made changes -
          Link This issue relates to HIVE-7104 [ HIVE-7104 ]
          Thejas M Nair made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Prasanth Jayachandran
              Reporter:
              Prasanth Jayachandran
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development