Uploaded image for project: 'ORC'
  1. ORC
  2. ORC-362

String direct length streams gets some values even if data is null

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Not A Problem
    • 1.4.3
    • None
    • None
    • None

    Description

      Observed this in one of the orc files recently.

      Looking at the orcfiledump (compression is NONE) something looks odd

          Stream: column 2 section PRESENT start: 13976 length 80
          Stream: column 2 section DATA start: 14056 length 541
          Stream: column 2 section LENGTH start: 14597 length 13
      ..
      ..
      ..
          Row group indices for column 2:
            Entry 0: count: 4 hasNull: true min: a max: z sum: 157 positions: 0,0,0,0,0,0
            Entry 1: count: 5 hasNull: true min: a max: z sum: 314 positions: 26,111,0,157,0,4
            Entry 2: count: 2 hasNull: true min: a max: z sum: 70 positions: 52,62,0,471,0,9
            Entry 3: count: 0 hasNull: true positions: 78,16,0,541,0,11
      

      If we look at Entry 3 (last entry) and related the stream positions, last entry is all nulls, the corresponding data stream ended at 541 offset (which is same as length). Data stream looks correct. But now if we look at length stream, the position is recorded as 11 in last entry but the length is actually 13 (this last 2 bytes is not expected). If there is no data the length stream is supposedly not record anything. If the data is null, only isPresent stream is expected to have an entry. Looks like orc writer is writing entries to length stream even if data is null (probably recording 0 lengths).

      Attachments

        Activity

          People

            Unassigned Unassigned
            prasanth_j Prasanth Jayachandran
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: