RE: create table bug with reserved words? - Mailing list pgsql-bugs

From Chris Storah
Subject RE: create table bug with reserved words?
Date
Msg-id C05E7DA1218ED411BF8A00105AC95A8E016D0C43@SV-CNTRMAIL
Whole thread Raw
In response to create table bug with reserved words?  (Chris Storah <cstorah@emis-support.demon.co.uk>)
Responses Re: create table bug with reserved words?  (Tom Lane <tgl@sss.pgh.pa.us>)
RE: create table bug with reserved words?  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-bugs
According to the documentation, CALL is in as a reserved word (7.1beta4 docs
I think).

The problem I have (and others may get) is porting apps from other databases
that support reserved words as identifiers (SQL server being the main one).

I assume the parser should know where it is (first and follow sets would
define whether a reserved word is allowed or not?), so is there any reason
why an identifier cannot cope with reserved words?.

If not, can anyone point me in the direction of the code that does the
parsing so I can take a look - if this would be helpful!

Thanks,
Chris

-----Original Message-----
From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Sent: 15 February 2001 15:23
To: Chris Storah
Cc: pgsql-bugs@postgresql.org
Subject: Re: [BUGS] create table bug with reserved words?


Chris Storah <cstorah@emis-support.demon.co.uk> writes:
> Is this a bug - should the parser cope with any reserved words as
> identifiers?

No, and no.  If you could use them as identifiers then they wouldn't
be reserved words, would they?

Some keywords are "more reserved" than others in the Postgres parser;
see the distinction between ColId and ColLabel in gram.y if you want
the details.  AFAICT, "CALL" is not a keyword at all in Postgres.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: create table bug with reserved words?
Next
From: "Henshall, Stuart - WCP"
Date:
Subject: Rules for Inserting Serials