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

Bug in ORC Timestamp reader returns wrong nanoseconds

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.13.0, 0.14.0
    • Fix Version/s: 0.13.0
    • Component/s: None
    • Labels:

      Description

      ORC timestamp writer stores the number of trailing zeros in 3 LSB bits. There is a bug in parsing nanosecond logic that returns incorrect value.

      Input:
      1999-01-01 00:00:00.999999999

      Output:
      1999-01-01 00:00:00.463129087

      The fix for this is parseNanos() should first right shift by 3 and then typecast to int.

        Attachments

        1. HIVE-6656.1.patch
          4 kB
          Prasanth Jayachandran
        2. HIVE-6656.1.patch.txt
          4 kB
          Prasanth Jayachandran

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved: