amaliujia commented on a change in pull request #2332:
URL: https://github.com/apache/calcite/pull/2332#discussion_r562832978



##########
File path: core/src/test/java/org/apache/calcite/sql/test/SqlAdvisorTest.java
##########
@@ -1585,4 +1587,17 @@ private void testSimpleParserQuotedIdImpl() {
     assertSimplify(sql, simplified);
     assertComplete(sql, EXPR_KEYWORDS, Collections.singletonList("TABLE(a)"), 
DEPT_COLUMNS);
   }
+
+  private static SqlSimpleParser simpleParser =
+      new SqlSimpleParser("_suggest_", SqlParser.Config.DEFAULT);
+
+  @Test public void testFilterComment() {
+    // when SqlSimpleParser.Tokenizer#nextToken() method parse sql,
+    // ignore the  "--" after 10.0, this is a comment,
+    // but Tokenizer#nextToken() does not recognize it
+    String sqlWithComment = "select count(*) from a where price > 10.0-- this 
is comment n"

Review comment:
       The last `n` should be `\n`?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to