SteveYurongSu commented on code in PR #11757:
URL: https://github.com/apache/iotdb/pull/11757#discussion_r1436069619


##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/pipe/event/common/tablet/TabletInsertionDataContainer.java:
##########
@@ -133,36 +150,23 @@ private void parse(InsertRowNode insertRowNode, String 
pattern) {
         this.measurementSchemaList[filteredColumnIndex] = 
originMeasurementSchemaList[i];
         this.columnNameStringList[filteredColumnIndex] = 
originColumnNameStringList[i];
         this.valueColumnTypes[filteredColumnIndex] = originValueColumnTypes[i];
-        switch (originValueColumnTypes[i]) {
-          case INT32:
-            this.valueColumns[filteredColumnIndex] = new int[] {(Integer) 
originValueColumns[i]};
-            break;
-          case INT64:
-            this.valueColumns[filteredColumnIndex] = new long[] {(Long) 
originValueColumns[i]};
-            break;
-          case FLOAT:
-            this.valueColumns[filteredColumnIndex] = new float[] {(Float) 
originValueColumns[i]};
-            break;
-          case DOUBLE:
-            this.valueColumns[filteredColumnIndex] = new double[] {(Double) 
originValueColumns[i]};
-            break;
-          case BOOLEAN:
-            this.valueColumns[filteredColumnIndex] =
-                new boolean[] {(Boolean) originValueColumns[i]};
-            break;
-          case TEXT:
-            this.valueColumns[filteredColumnIndex] = new Binary[] {(Binary) 
originValueColumns[i]};
-            break;
-          default:
-            throw new UnSupportedDataTypeException(
-                String.format(
-                    "Data type %s is not supported.", 
originValueColumnTypes[i].toString()));
-        }
+        this.valueColumns[filteredColumnIndex] =
+            filterValueColumnsByRowIndexList(
+                originValueColumnTypes[i], originValueColumns[i], 
rowIndexList, true);
         this.nullValueColumnBitmaps[filteredColumnIndex] = new BitMap(1);
       }
     }
 
-    rowCount = 1;
+    rowCount = rowIndexList.size();
+    if (rowCount == 0) {
+      LOGGER.warn(

Review Comment:
   LOGGER.info



-- 
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