From: | Alvaro Herrera <alvherre(at)commandprompt(dot)com> |
---|---|
To: | Florian Pflug <fgp(at)phlo(dot)org> |
Cc: | andurkar <andurkarad10(dot)comp(at)coep(dot)ac(dot)in>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Postgresql parser |
Date: | 2011-09-27 14:22:43 |
Message-ID: | 1317133225-sup-7687@alvh.no-ip.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Excerpts from Florian Pflug's message of mar sep 27 08:28:00 -0300 2011:
> On Sep27, 2011, at 10:44 , andurkar wrote:
> > Currently I am working on Postgresql... I need to study the gram.y and
> > scan.l parser files...since I want to do some qery modification. Can anyone
> > please help me to understand the files. What should I do ? Is there any
> > documentation available ?
>
> scan.l defines the lexer, i.e. the algorithm that splits a string (containing
> an SQL statement) into a stream of tokens. A token is usually a single word
> (i.e., doesn't contain spaces but is delimited by spaces), but can also be
> a whole single or double-quoted string for example. The lexer is basically
> defined in terms of regular expressions which describe the different token types.
Seemed a good answer so I added it to the developer's faq
http://wiki.postgresql.org/wiki/Developer_FAQ#I_need_to_do_some_changes_to_query_parsing._Can_you_succintly_explain_the_parser_files.3F
Feel free to edit.
--
Álvaro Herrera <alvherre(at)commandprompt(dot)com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2011-09-27 14:32:03 | Re: Support UTF-8 files with BOM in COPY FROM |
Previous Message | Peter Eisentraut | 2011-09-27 14:21:37 | Re: Support UTF-8 files with BOM in COPY FROM |