On Thu, Jul 12, 2012 at 11:26:16PM +0200, Vivien Malerba wrote: > Le 12 juil. 2012 21:40, "Aaron Patterson" <tenderl...@ruby-lang.org> a > écrit : > > > > Hi, > > > > I would like to build an AST of a SQL statement using SQLite3. I've > > been reading through sqlite3RunParser as well as the grammar. It > > *looks* like the grammar is building some sort of structure before the > > statement is compiled to byte code, but I'm getting lost. > > > > Is it possible to get an AST out of the parser without major surgery? > > If so, can someone point me in the right direction? > > > > I don't know if this is what you are looking for, but Libgda ( > http://www.gnome-db.org) includes a parser which takes and SQL string and > builds a abstract tree, see > http://developer-next.gnome.org/libgda/stable/GdaSqlParser.html and > http://developer-next.gnome.org/libgda/stable/libgda-5.0-GdaSqlStatement.html > . > > If this is what you're looking for, you can either use Libgda or copy the > bits you want.
That's perfect. Thanks for the information! -- Aaron Patterson http://tenderlovemaking.com/ _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users