[
https://issues.apache.org/jira/browse/CALCITE-7599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18088077#comment-18088077
]
Chris Dennis commented on CALCITE-7599:
---------------------------------------
https://github.com/apache/calcite/blob/8741cdcc759dc45ded1510427ac44c142ae0a47d/site/_docs/reference.md#L3575
vs
https://github.com/apache/calcite/blob/3b9d9f0acd076410e8acfb6b9fa72ce42de41e10/core/src/test/java/org/apache/calcite/test/SqlHintsConverterTest.java#L175
In the reference documentation it's: {{hint2(a=1, b=2)}}, whereas in the test
it's: {{hint2(a='1', b='2')}} with quoted numeric literals.
> Enhance parser to allow numeric literals as values in k/v hints as suggested
> by documentation
> ---------------------------------------------------------------------------------------------
>
> Key: CALCITE-7599
> URL: https://issues.apache.org/jira/browse/CALCITE-7599
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.42.0
> Reporter: Chris Dennis
> Priority: Minor
> Labels: pull-request-available
>
> There is a small inconsistency remaining between the reference documentation
> [https://calcite.apache.org/docs/reference.html#syntax] and the parser
> syntax. The documentation example shows unquoted numeric literals being used
> as values in a k/v hint. This isn't reflected in the grammar that follows in
> the document, the parser grammar itself, or in
> {{SqlHintsConverterTest#testDocumentationExample}}. I think it should be
> pretty simple to expand the grammar to support either a string or numeric
> literal, and to update the test to exactly match the documentation example by
> not quoting the two numeric constants.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)