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

From Tom Lane
Subject Re: create table bug with reserved words?
Date
Msg-id 12335.982343494@sss.pgh.pa.us
Whole thread Raw
In response to RE: create table bug with reserved words?  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-bugs
Peter Eisentraut <peter_e@gmx.net> writes:
> But since the problematic word in your case is not CALL but SELECT, I can
> tell you right away with relative certainty that it will not be possible
> to change the parser to accept SELECT as an identifier in all contexts
> without butchering the grammar beyond reason.

You can drop the "without" qualifier ;-) --- it's not possible period.
Counterexample:

        SELECT (SELECT (3)) FROM foo;

Is the second SELECT a (rather vacuous) sub-select, or is it a call of a
function named SELECT?

If you've got a really strong urge to use some keyword as an identifier,
that's what double quotes are for.  But the SQL syntax does require a
lot of keywords to be reserved.  I believe that we are actually more
permissive in this respect than the SQL spec expects us to be.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: RE: create table bug with reserved words?
Next
From: Chris Storah
Date:
Subject: RE: create table bug with reserved words?