From d74f61775d06ebc40eb72e6055349e25df95b2de Mon Sep 17 00:00:00 2001 From: shuwenwei Date: Fri, 22 Nov 2024 15:28:08 +0800 Subject: [PATCH] modify example --- .../org/apache/tsfile/v4/WriteTabletWithITsFileWriter.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/java/examples/src/main/java/org/apache/tsfile/v4/WriteTabletWithITsFileWriter.java b/java/examples/src/main/java/org/apache/tsfile/v4/WriteTabletWithITsFileWriter.java index 78988cf93..d7dca8310 100644 --- a/java/examples/src/main/java/org/apache/tsfile/v4/WriteTabletWithITsFileWriter.java +++ b/java/examples/src/main/java/org/apache/tsfile/v4/WriteTabletWithITsFileWriter.java @@ -97,7 +97,7 @@ public static void main(String[] args) throws IOException { // reset tablet tablet.reset(); - for (int timestamp = 0; timestamp < 5; timestamp++) { + for (long timestamp = 0; timestamp < 5; timestamp++) { int rowIndex = tablet.getRowSize(); // rowSize may be changed after addTimestamp tablet.addTimestamp(rowIndex, timestamp); @@ -108,7 +108,8 @@ public static void main(String[] args) throws IOException { // id2 column tablet.addValue(rowIndex, 1, "id1_field_2"); - tablet.addValue(rowIndex, 2, timestamp); + // s1 column + tablet.addValue(rowIndex, 2, 1); // s2 column tablet.addValue(rowIndex, 3, false);