Re: Antwort: [HACKERS] ecpg parser - Mailing list pgsql-hackers

From Michael Meskes
Subject Re: Antwort: [HACKERS] ecpg parser
Date
Msg-id 19980930074744.A630@usa.net
Whole thread Raw
In response to Re: Antwort: [HACKERS] ecpg parser  ("Thomas G. Lockhart" <lockhart@alumni.caltech.edu>)
List pgsql-hackers
On Tue, Sep 29, 1998 at 12:55:57PM +0000, Thomas G. Lockhart wrote:
> I haven't yet committed the changes to the source tree, but may have a
> chance to regression test and commit today. I'll send patches to you at
> the same time. btw, there was a missing comma between ADD and AS in the
> token list (I see the problem also in preproc.y) and I found one or two
> omissions in parser/keywords.c. Most of my changes were to fix omissions
> and to allow tokens to be column identifiers or column labels as much as
> possible.

I see. I will add your changes as soon as I find time.

> The other thing I'm doing is documenting the reserved and unreserved
> keywords (I'm most of the way there, and will commit a new file
> syntax.sgml to the docs tree soon). The only thing I've been looking at
> so far is gram.y. Are there any other keywords added to preproc.y? I see

Yes, there are some special embedded sql keywords like break, call,
whenever, etc. See ecpg/preproc/ecpg_keywords.c for details.

> that you did things so that EXEC and SQL are not required to be reserved
> words (I hadn't thought of how to do that; nice trick!), but perhaps

Thanks. :-)

> there are others which are. Shall we put all of the keywords used by
> either gram.y or preproc.y into gram.y and keywords.c to make it more
> consistant and to enforce consistancy in database design? SQL92 doesn't

At first I thought why making it a keyword when it doesn't have to. But the
more I think about it the more I like it. It just doesn't make sense to use
these keywords because that would force you to not use ecpg.

> OK, sorry. I'd put your address into my mailer, and hadn't notice the
> change.

No problem. But that way it will reach me no matter if I'm at home or in the
office.

Michael
--
Dr. Michael Meskes      | Th.-Heuss-Str. 61, D-41812 Erkelenz | Go SF49ers!
Senior-Consultant       | business: Michael.Meskes@mummert.de | Go Rhein Fire!
Mummert+Partner         | private: Michael.Meskes@usa.net     | Use Debian
Unternehmensberatung AG |          Michael.Meskes@gmx.net     | GNU/Linux!

pgsql-hackers by date:

Previous
From: "Thomas G. Lockhart"
Date:
Subject: Patches for gram.y and keywords.c
Next
From: "Joost Kraaijeveld"
Date:
Subject: Windows NT port: what file are created by initdb?