SQL query parser



Hello all,

I am currently looking for an SQL parser written in Java, preferably
with source code. What I want to do is to infer (as far as possible)
the schema from an SQL DML statement. The parser should give me some
nice, traversable Java object tree/abstract syntax tree.

So far I only found sql4j and Zql, which both are very old and do not
parse my statements.

Anyone can give me some pointers? Here is a list of things that the
parser should be able to parse:

* CASE statements in the SELECT as well as in the WHERE clause
* subselects, exists, not exists, ...
* column and table aliasing
* grouping and aggregate functions

Thanks for your help,
Boris Stumm
.



Relevant Pages

  • Re: SQL query parser
    ... I am currently looking for an SQL parser written in Java, ... parse my statements. ...
    (comp.lang.java.databases)
  • Re: corrupted pointer when initing a dll
    ... then call parser to parse the a2l file and load all the channel ... return result of the load and parse. ... class is housed in a DLL and that DLL can be unloaded while your ...
    (microsoft.public.vc.language)
  • Re: corrupted pointer when initing a dll
    ... then call parser to parse the a2l file and load all the channel ... return result of the load and parse. ... class is housed in a DLL and that DLL can be unloaded while your ...
    (microsoft.public.vc.language)
  • Re: corrupted pointer when initing a dll
    ... DWORD WINAPI CCCP::ParseA2lThread{ ... class is housed in a DLL and that DLL can be unloaded while your ... then call parser to parse the a2l file and load all the channel ...
    (microsoft.public.vc.language)
  • Re: Treetop parser (or PEG in general?) questions
    ... other parser generators, and perhaps also to build lists. ... rule statement skip whitespace ... not wild about implicit insertion into rules. ... determining only if the parse is possible. ...
    (comp.lang.ruby)