Hi,

I'm trying to extend Calcite grammar to support some custom statements. And
I need to increase LOOKAHEAD to 3 to resolve some ambiguity. But when I did
that, the parser fails to parse queries like:
*    select t.key from (select key from src) t*

With exception:
*Caused by: org.apache.calcite.sql.parser.impl.ParseException:*
*Encountered "( select key" at line 1, column 19.*
*Was expecting one of:*
*    <IDENTIFIER> ...*
*    <QUOTED_IDENTIFIER> ...*
*    <BACK_QUOTED_IDENTIFIER> ...*
*    <BRACKET_QUOTED_IDENTIFIER> ...*
*    <UNICODE_QUOTED_IDENTIFIER> ...*
*    "LATERAL" ...*
*    "(" "WITH" ...*
*...*

So I'm wondering whether there's some limitation on the LOOKAHEAD we can
use?

-- 
Best regards!
Rui Li

Reply via email to