Re: RFD: schemas and different kinds of Postgres objects - Mailing list pgsql-hackers

From Zeugswetter Andreas SB SD
Subject Re: RFD: schemas and different kinds of Postgres objects
Date
Msg-id 46C15C39FEB2C44BA555E356FBCD6FA41EB4C2@m0114.s-mxs.net
Whole thread Raw
In response to RFD: schemas and different kinds of Postgres objects  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: RFD: schemas and different kinds of Postgres objects  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> > Switches set to historical:
> 
> >   schema search path = (user's own schema, "any" schema, postgres)
> 
> >   [ default creation schema = user's own schema ]
> 
> > The searching in "any" schema (i.e., any owner) will let will find 
> > things that where defined the way they are today, i.e., possibly
> > by several different users.
> 
> No, it won't, because nothing will ever get put into that schema.
> (At least not by existing pg_dump scripts, which are the things that
> really need to see the historical behavior.)  The
> default-creation-schema variable has got to point at any/public/
> whatever-we-call it, or you do not have the historical behavior.

When configured for historical behavior would need to:
1. have search path: temp, any, system
2. guard against duplicate table names across all schemas (except temp schema)

Or are you thinking about a per session behavior ?
I would rather envision a per database behavior.

Maybe the easy way out would be a "default creation schema" property for 
each user, that would default to the username. If you want everything in one 
schema simply alter the users.

Andreas


pgsql-hackers by date:

Previous
From: Vsevolod Lobko
Date:
Subject: pltcl build problem on FreeBSD (was: Re: pltlc and pltlcu problems)
Next
From: "Zeugswetter Andreas SB SD"
Date:
Subject: Re: Schemas vs. PostQUEL: resolving qualified identifiers