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

qiaojialin 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 c7f6bea  [IOTDB-1057] Remove Data type ALL in create time series 
sentence (#2268)
c7f6bea is described below

commit c7f6beab34fb6319e80d70aef2423c592e8b6ea4
Author: Qi Yu <[email protected]>
AuthorDate: Thu Dec 17 15:52:42 2020 +0800

    [IOTDB-1057] Remove Data type ALL in create time series sentence (#2268)
---
 antlr/src/main/antlr4/org/apache/iotdb/db/qp/sql/SqlBase.g4       | 8 ++++----
 .../src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/antlr/src/main/antlr4/org/apache/iotdb/db/qp/sql/SqlBase.g4 
b/antlr/src/main/antlr4/org/apache/iotdb/db/qp/sql/SqlBase.g4
index b28392b..1f86f1e 100644
--- a/antlr/src/main/antlr4/org/apache/iotdb/db/qp/sql/SqlBase.g4
+++ b/antlr/src/main/antlr4/org/apache/iotdb/db/qp/sql/SqlBase.g4
@@ -299,9 +299,9 @@ groupByLevelClause
     ;
 
 typeClause
-    : dataType LS_BRACKET linearClause RS_BRACKET
-    | dataType LS_BRACKET previousClause RS_BRACKET
-    | dataType LS_BRACKET previousUntilLastClause RS_BRACKET
+    : (dataType | ALL) LS_BRACKET linearClause RS_BRACKET
+    | (dataType | ALL) LS_BRACKET previousClause RS_BRACKET
+    | (dataType | ALL) LS_BRACKET previousUntilLastClause RS_BRACKET
     ;
 
 linearClause
@@ -622,7 +622,7 @@ nodeNameWithoutStar
     ;
 
 dataType
-    : INT32 | INT64 | FLOAT | DOUBLE | BOOLEAN | TEXT | ALL
+    : INT32 | INT64 | FLOAT | DOUBLE | BOOLEAN | TEXT
     ;
 
 dateFormat
diff --git 
a/server/src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java 
b/server/src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java
index ab78eea..ad69a12 100644
--- a/server/src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java
+++ b/server/src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java
@@ -1291,7 +1291,7 @@ public class IoTDBSqlVisitor extends 
SqlBaseBaseVisitor<Operator> {
         throw new SQLParserException("group by fill doesn't support linear 
fill");
       }
       // all type use the same fill way
-      if (SQLConstant.ALL.equalsIgnoreCase(typeClause.dataType().getText())) {
+      if (typeClause.ALL() != null) {
         IFill fill;
         if (typeClause.previousUntilLastClause() != null) {
           long preRange;

Reply via email to