Il dom 29 lug 2018, 19:31 srikanth <srikanth.mvs...@gmail.com> ha scritto:
> favorite > < > https://stackoverflow.com/questions/51547864/apache-calcite-and-sql-parsing?noredirect=1# > > > > I am working on a project that needs to connect to the database to retrieve > the SQL Statements. Once I retrieved the SQL queries then I need to parse > these SQL statement Conditions*/Qualifiers* and store them in a memory for > doing some comparisons later on. > > I did some research and I came across Apache Calcite. As per the website > link <https://calcite.apache.org/docs/>, it supports query parsing, > validation, and optimization. > > The database that I want to connect is *Oracle DB* to retrieve the queries( > like SELECT,WITH). > > Can you provide any info on how to get started for this and am I going in > right direction in going with Apache Calcite? > This is an application which uses Calcite sql parser and planner https://github.com/diennea/herddb/blob/master/herddb-core/src/main/java/herddb/sql/CalcitePlanner.java Look for 'runPlanner' You will find how to parse an SQL statement Hope that helps Enrico Thanks, > Srikanth. > -- -- Enrico Olivelli