You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2022/04/08 11:07:16 UTC

[GitHub] [druid] LakshSingla commented on a diff in pull request #12414: Make error messages for insert statements consistent with select statements

LakshSingla commented on code in PR #12414:
URL: https://github.com/apache/druid/pull/12414#discussion_r846000668


##########
sql/src/main/codegen/includes/insert.ftl:
##########
@@ -34,6 +34,8 @@ SqlNode DruidSqlInsert() :
     <CLUSTERED> <BY>
     clusteredBy = ClusterItems()
   ]
+  // EOF is also present in SqlStmtEof but is a special case and multiple occurances together are valid with one token

Review Comment:
   ```suggestion
     // EOF is also present in SqlStmtEof but EOF is a special case and a single EOF can be consumed multiple times. The reason for adding EOF here is to ensure that we create a DruidSqlInsert node after the syntax has been validated and throw SQL syntax errors before performing validations in the DruidSqlInsert which can overshadow the actual error message```



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org