Hi Team,
   I am getting the following exception while trying to parse a SQL
statement into its tokens. Is this expected behavior? If not, what would
you suggest to work around this problem. The particulars are given below:

*Issue:*
*Method threw 'java.lang.RuntimeException' exception. Cannot evaluate
org.apache.calcite.sql.SqlJoin.toString().*

*Where:*
This happens when I use the following API (it is visible on the "from"
value):

        SqlParser.Config parserConfig = SqlParser.config();
        parserConfig
                .withCaseSensitive(false)
                .withLex(Lex.ORACLE);
        SqlParser parser = SqlParser.create(sqlString, parserConfig);
>>> [Line with the issue]        *SqlNode sqlNode = parser.parseStmt();*


*Debugger Image:*
[image: image.png]
*Version In Use:*
I am using the following maven GAVs
-org.apache.calcite:calcite-babel:1.27.0, so my assumption is that I am at
the latest.

*SQL Statement with the issue:*

*SELECT Purchase.Purchase_Date, Products.Product_Name FROM Purchase JOIN
Products ON Purchase.Product_ID = Purchase.ID WHERE Purchase.Quantity > 10*

I would appreciate any help on this.

Thanks - Jariv

Reply via email to