Re: Schema + search path problem

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: johnsw(at)wardbrook(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Schema + search path problem
Date: 2003-12-11 18:38:38
Message-ID: 14612.1071167918@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"John Sidney-Woollett" <johnsw(at)wardbrook(dot)com> writes:
> Is there a way to set the default search path for the user 'FRED'
> permanently?

See ALTER USER. You can set per-user or per-database defaults for any
SETtable variable, not only search_path.

> If I am the postgres user and creating a function (for example) in a given
> schema, do I have to qualify ALL the objects referred to in the function
> by the schema prefix (if I don't want them in the public schema)?

It's a good idea. At the moment a function body is interpreted with the
call-time value of search_path. We've batted around the idea that it
should use the creation-time path, but nothing's been done about it.

> ps Is the 7.4 documentation less detailed on schemas than the 7.3
> docs?

I don't believe we've removed anything; rearranged, perhaps. Does
http://www.postgresql.org/docs/current/static/ddl-schemas.html
not cover the same ground that's in the 7.3 docs?

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Amir Khawaja 2003-12-11 18:47:02 Re: Redhat 9.0 Service Shutdown
Previous Message Joe Conway 2003-12-11 18:33:06 Re: Strange permission problem regarding pg_settings