JingsongLi commented on code in PR #2364:
URL: https://github.com/apache/incubator-paimon/pull/2364#discussion_r1400756568


##########
paimon-format/src/main/java/org/apache/paimon/format/orc/reader/OrcRowColumnVector.java:
##########
@@ -43,7 +43,8 @@ public OrcRowColumnVector(StructColumnVector hiveVector, 
RowType type) {
 
     @Override
     public ColumnarRow getRow(int i) {
-        this.columnarRow.setRowId(i);
-        return this.columnarRow;
+        ColumnarRow copy = this.columnarRow.copy();

Review Comment:
   Don't need to introduce this `copy`, just:
   ```
       private final VectorizedColumnBatch batch;
   
       public OrcRowColumnVector(StructColumnVector hiveVector, RowType type) {
           super(hiveVector);
           int len = hiveVector.fields.length;
           ColumnVector[] paimonVectors = new ColumnVector[len];
           for (int i = 0; i < len; i++) {
               paimonVectors[i] = createPaimonVector(hiveVector.fields[i], 
type.getTypeAt(i));
           }
           this.batch = new VectorizedColumnBatch(paimonVectors);
       }
   
       @Override
       public ColumnarRow getRow(int i) {
           return new ColumnarRow(batch, i);
       }
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to