Re: [PATCHES] dollar quoting

From: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCHES] dollar quoting
Date: 2004-02-17 01:15:46
Message-ID: 40316B42.7060407@familyhealth.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

> Actually, I thought the way to handle it would be to duplicate the
> backend lexer as nearly as possible. Most of the productions would have
> empty bodies probably, but doing it that way would guarantee that in
> fact psql and the backend would lex a string the same way, which is
> exactly the problem we are facing here. You'd fall out of the lexer
> only upon detecting backslash (unless we want to put backslash command
> lexing into the flex code, which might or might not be a good idea),
> or upon detecting a ';' at parenthesis depth 0, or upon hitting end of
> string. In the last case the lexer state would indicate which prompt
> we need to give.

You know what would be really sweet? If the lexing was made available
as a public function. eg. So I could parse queries in phpPgAdmin before
sending them to the backend, etc...

Chris

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-02-17 02:22:41 Re: [PATCHES] dollar quoting
Previous Message markw 2004-02-16 23:41:07 Re: Proposed Query Planner TODO items

Browse pgsql-patches by date

  From Date Subject
Next Message Tom Lane 2004-02-17 02:22:41 Re: [PATCHES] dollar quoting
Previous Message Tom Lane 2004-02-16 18:18:30 Re: [PATCHES] dollar quoting