This is an automated email from the ASF dual-hosted git repository.

haonan pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/tsfile.git


The following commit(s) were added to refs/heads/develop by this push:
     new a8e48ad9 Ignore the null value passed in the Tablet.addValue method 
(#540)
a8e48ad9 is described below

commit a8e48ad9d4f1682e53db3fc1fb14f18edb969610
Author: shuwenwei <[email protected]>
AuthorDate: Wed Jul 9 14:52:47 2025 +0800

    Ignore the null value passed in the Tablet.addValue method (#540)
---
 .../src/main/java/org/apache/tsfile/write/record/Tablet.java     | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git 
a/java/tsfile/src/main/java/org/apache/tsfile/write/record/Tablet.java 
b/java/tsfile/src/main/java/org/apache/tsfile/write/record/Tablet.java
index d84cd057..ac03949a 100644
--- a/java/tsfile/src/main/java/org/apache/tsfile/write/record/Tablet.java
+++ b/java/tsfile/src/main/java/org/apache/tsfile/write/record/Tablet.java
@@ -507,6 +507,9 @@ public class Tablet {
       throw new IllegalArgumentException(
           "The data type of column index " + columnIndex + " is not 
TEXT/STRING/BLOB");
     }
+    if (val == null) {
+      return;
+    }
     final Binary[] sensor = (Binary[]) values[columnIndex];
     sensor[rowIndex] = new Binary(val, TSFileConfig.STRING_CHARSET);
     updateBitMap(rowIndex, columnIndex, false);
@@ -524,6 +527,9 @@ public class Tablet {
       throw new IllegalArgumentException(
           "The data type of column index " + columnIndex + " is not 
TEXT/STRING/BLOB");
     }
+    if (val == null) {
+      return;
+    }
     final Binary[] sensor = (Binary[]) values[columnIndex];
     sensor[rowIndex] = new Binary(val);
     updateBitMap(rowIndex, columnIndex, false);
@@ -541,6 +547,9 @@ public class Tablet {
       throw new IllegalArgumentException(
           "The data type of column index " + columnIndex + " is not DATE");
     }
+    if (val == null) {
+      return;
+    }
     final LocalDate[] sensor = (LocalDate[]) values[columnIndex];
     sensor[rowIndex] = val;
     updateBitMap(rowIndex, columnIndex, false);

Reply via email to