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

jackietien pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/master by this push:
     new 710e7fb6acf [IOTDB-5960] Fix bug in groupByCount in 1C3D
710e7fb6acf is described below

commit 710e7fb6acf5176f2511570812aae818e18b9be0
Author: YangCaiyin <[email protected]>
AuthorDate: Thu Jun 1 15:04:58 2023 +0800

    [IOTDB-5960] Fix bug in groupByCount in 1C3D
---
 .../java/org/apache/iotdb/db/it/groupby/IoTDBGroupByCountIT.java   | 7 +++++++
 .../iotdb/db/mpp/plan/planner/plan/parameter/GroupByParameter.java | 2 ++
 2 files changed, 9 insertions(+)

diff --git 
a/integration-test/src/test/java/org/apache/iotdb/db/it/groupby/IoTDBGroupByCountIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/db/it/groupby/IoTDBGroupByCountIT.java
index e8cafcd252f..5b59486db72 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/db/it/groupby/IoTDBGroupByCountIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/db/it/groupby/IoTDBGroupByCountIT.java
@@ -19,10 +19,15 @@
 package org.apache.iotdb.db.it.groupby;
 
 import org.apache.iotdb.it.env.EnvFactory;
+import org.apache.iotdb.it.framework.IoTDBTestRunner;
+import org.apache.iotdb.itbase.category.ClusterIT;
+import org.apache.iotdb.itbase.category.LocalStandaloneIT;
 
 import org.junit.AfterClass;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.junit.experimental.categories.Category;
+import org.junit.runner.RunWith;
 
 import java.sql.Connection;
 import java.sql.ResultSet;
@@ -34,6 +39,8 @@ import static 
org.apache.iotdb.db.it.utils.TestUtils.prepareData;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.fail;
 
+@RunWith(IoTDBTestRunner.class)
+@Category({LocalStandaloneIT.class, ClusterIT.class})
 public class IoTDBGroupByCountIT {
   // the data can be viewed in
   // 
https://docs.google.com/spreadsheets/d/1vsSmb41pdmK-BdBR1STwr8olg1Qc8baKVEWnfJB4mAg/edit#gid=0
diff --git 
a/server/src/main/java/org/apache/iotdb/db/mpp/plan/planner/plan/parameter/GroupByParameter.java
 
b/server/src/main/java/org/apache/iotdb/db/mpp/plan/planner/plan/parameter/GroupByParameter.java
index 586188fc4a2..283de44206d 100644
--- 
a/server/src/main/java/org/apache/iotdb/db/mpp/plan/planner/plan/parameter/GroupByParameter.java
+++ 
b/server/src/main/java/org/apache/iotdb/db/mpp/plan/planner/plan/parameter/GroupByParameter.java
@@ -77,6 +77,8 @@ public abstract class GroupByParameter {
       return GroupByConditionParameter.deserialize(byteBuffer);
     } else if (type == WindowType.SESSION_WINDOW.getType()) {
       return GroupBySessionParameter.deserialize(byteBuffer);
+    } else if (type == WindowType.COUNT_WINDOW.getType()) {
+      return GroupByCountParameter.deserialize(byteBuffer);
     } else throw new SemanticException("Unsupported window type");
   }
 }

Reply via email to