|
NAMEGenezzo::Parse::SQL - SQL parserSYNOPSISuse Genezzo::Parse::SQL; use Parse::RecDescent; use Data::Dumper; # load the precompiled parser my $parser = Genezzo::Parse::SQL->new(); # sql_000 is parser entry point. # The argument is a string which contains a SQL query # (without a trailing semicolon). # The output is nested hash structure of the abstract # syntax tree. my $sql_tree = $parser->sql_000($some_sql_statement); # dump out the parse tree print Data::Dumper->Dumper([$sql_tree],['sql_tree']); DESCRIPTIONThe SQL parser is a L<Parse::RecDescent> parser generated by L<Genezzo::Parse::SQLGrammar>. It shouldn't be looked at with human eyes. Still reading this? You must be a glutton for punishment. This parser handles a fair bit of SQL92, but the error handling is somewhat lacking. ARGUMENTSFUNCTIONSEXPORTLIMITATIONSNo support for DDL, ANSI Interval, Date, Timestamp, etc. TODO
AUTHORJeffrey I. Cohen, jcohen@genezzo.comSEE ALSOperl(1).Copyright (c) 2005,2006 Jeffrey I Cohen. All rights reserved. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Address bug reports and comments to: jcohen@genezzo.com For more information, please visit the Genezzo homepage at <http://www.genezzo.com>
Visit the GSP FreeBSD Man Page Interface. |