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

[C++] ORC: Char(n) and Varchar(n) writers truncate to n bytes & corrupts multi-byte data

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.5.2
    • 1.6.0
    • None
    • None

    Description

      https://github.com/apache/orc/blob/master/java/core/src/java/org/apache/orc/impl/writer/CharTreeWriter.java#L41

          itemLength = schema.getMaxLength();
          padding = new byte[itemLength];
        }
      

      https://github.com/apache/orc/blob/master/java/core/src/java/org/apache/orc/impl/writer/VarcharTreeWriter.java#L48

            if (vector.noNulls || !vector.isNull[0]) {
              int itemLength = Math.min(vec.length[0], maxLength);
      

      Attachments

        Issue Links

          Activity

            People

              wgtmac Gang Wu
              wgtmac Gang Wu
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: