Re: schema and roles - Mailing list pgsql-general

From Josh Williams
Subject Re: schema and roles
Date
Msg-id 1224295752.25622.1.camel@godzilla.local.scalefeather.com
Whole thread Raw
In response to schema and roles  ("Alain Roger" <raf.news@gmail.com>)
List pgsql-general
On Fri, 2008-10-17 at 19:45 +0200, Alain Roger wrote:
> i mean if i'm logged with the role "test_user", typing show
> search_path; will show me all default schemas.

On SHOW, the manual saith[1]:
"The function current_setting produces equivalent output" ...

SELECT current_setting('search_path');

It's also in pg_settings, though not listed in the (8.2) manual:

SELECT * FROM pg_settings WHERE name = 'search_path';


> After that, i know that using alter user test_user .... i can add
> another schema as default, but how to remove some ?
> thanks a lot,

ALTER USER ... SET search_path ... will always replace the schema search
path with the value you specify, so simply leave it out of that list to
effectively remove it.

P.S. In case there's any question, search_path has nothing to do with
security and access rights to schemas.

[1] http://www.postgresql.org/docs/8.2/interactive/sql-show.html

- Josh Williams



pgsql-general by date:

Previous
From: Jason Long
Date:
Subject: Re: auto insert data every one minute
Next
From: "Ow Mun Heng"
Date:
Subject: Re: partitioning : replicate_partition doesn't seem to be working