This is an automated email from the ASF dual-hosted git repository. rong pushed a commit to branch select-into in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit f5706f2b8b631765ecb42b248a3612395aec1153 Author: Steve Yurong Su <[email protected]> AuthorDate: Tue Jul 13 09:46:34 2021 +0800 fix IoTDBSqlVisitor parsing error --- .../src/main/java/org/apache/iotdb/db/qp/sql/IoTDBSqlVisitor.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) 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 737423b..909bf07 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 @@ -1217,8 +1217,8 @@ public class IoTDBSqlVisitor extends SqlBaseBaseVisitor<Operator> { trueLevel = fromLen - 1; } - if (ctx.fullPath() != null) { - targetPath = parseFullPath(ctx.fullPath()); + if (ctx.intoPath().fullPath() != null) { + targetPath = parseFullPath(ctx.intoPath().fullPath()); Matcher m = cqLevelNodePattern.matcher(targetPath.getFullPath()); while (m.find()) { String param = m.group(); @@ -1233,7 +1233,7 @@ public class IoTDBSqlVisitor extends SqlBaseBaseVisitor<Operator> { "CQ: x of ${x} should be greater than 0 and equal to or less than <level> or the length of queried path prefix."); } } - } else if (ctx.nodeNameWithoutStar() != null) { + } else if (ctx.intoPath().nodeNameWithoutStar() != null) { List<String> targetNodes = new ArrayList<>(); @@ -1242,7 +1242,7 @@ public class IoTDBSqlVisitor extends SqlBaseBaseVisitor<Operator> { for (int i = 1; i <= trueLevel; i++) { targetNodes.add("${" + i + "}"); } - targetNodes.add(ctx.nodeNameWithoutStar().getText()); + targetNodes.add(ctx.intoPath().nodeNameWithoutStar().getText()); targetPath = new PartialPath(targetNodes.toArray(new String[0])); }
