[
https://issues.apache.org/jira/browse/CALCITE-2917?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16790854#comment-16790854
]
Julian Hyde commented on CALCITE-2917:
--------------------------------------
When the parser is invoked, it calls {{parser.switchTo(String stateName)}}
based on {{SqlParser.Confing.quoting()}}. And the default value of
{{quoting()}} is {{Quoting.DOUBLE_QUOTE}}.
So, the premise of this case, "Calcite should use double quote as default
identifier delimiter" is already true.
That said, I agree that the DEFAULT lexical state in Parser.jj (which uses
brackets) is misleadingly named. Because we never leave the parser in that
lexical state. Maybe we can improve the name and/or documentation for that
state.
> Calcite should use double quote as default identifier delimiter
> ---------------------------------------------------------------
>
> Key: CALCITE-2917
> URL: https://issues.apache.org/jira/browse/CALCITE-2917
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.17.0, 1.18.0
> Reporter: Nan Deng
> Priority: Major
>
> From CALCITE-1217 I found this statement:
> {code:java}
> (Calcite) Its default identifier quoting character is double-quote.
> {code}
> this is not consistent with what's been said in
> [Parser.jj|https://github.com/apache/calcite/blob/50012d221d6e9a5e42a957ab0723e0f706b25be3/core/src/main/codegen/templates/Parser.jj#L6976]
> which defines bracket as the default identifier delimiter:
>
> It should be one or another.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)