Re: Operators and schemas - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Operators and schemas
Date
Msg-id 9171.1018930897@sss.pgh.pa.us
Whole thread Raw
In response to Re: Operators and schemas  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> I had imagined that pg_dump would emit commands such as this:

> CREATE SCHEMA foo
>   CREATE TABLE bar ( ... )
>   CREATE otherthings
> ;

> which is how I read the SQL standard.  Are there plans to implement the
> CREATE SCHEMA command that way?  I think I recall someone from Toronto
> mentioning something along these lines.

We have portions of that now, but I don't think there is any serious
intent to support *all* Postgres CREATE statements inside CREATE SCHEMA.
Because there are no semicolons in there, allowing random statements in
CREATE SCHEMA tends to force promotion of keywords to full-reserved
status (so you can tell where each sub-statement starts).  My
inclination is to allow the minimum necessary for SQL spec compliance.

(Fernando, your thoughts here?)    
>> Given the present semantics of
>> search_path, that will imply an implicit search of pg_catalog before
>> foo.

> Interesting ... Is that only temporary?  (since you say "present"
> semantics)

Only meant to imply "it hasn't been seriously reviewed, so someone
might have a better idea".  At the moment I'm happy with it.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Manuel Sugawara
Date:
Subject: Re: regexp character class locale awareness patch
Next
From: Peter Eisentraut
Date:
Subject: Re: [PATCHES] [SQL] 16 parameter limit