Re: Having a problem with RoR-3.1.1 and Pg-9.1

Поиск
Список
Период
Сортировка
От Adrian Klaver
Тема Re: Having a problem with RoR-3.1.1 and Pg-9.1
Дата
Msg-id 201202271254.49132.adrian.klaver@gmail.com
обсуждение исходный текст
Ответ на Re: Having a problem with RoR-3.1.1 and Pg-9.1  ("James B. Byrne" <byrnejb@harte-lyne.ca>)
Ответы Re: Having a problem with RoR-3.1.1 and Pg-9.1  ("James B. Byrne" <byrnejb@harte-lyne.ca>)
Re: Having a problem with RoR-3.1.1 and Pg-9.1  ("James B. Byrne" <byrnejb@harte-lyne.ca>)
Список pgsql-general
On Monday, February 27, 2012 11:44:09 am James B. Byrne wrote:


>
> 3. Why are these dependencies not owned by the database
> owner to begin with?  Surely this code:
>
> CREATE EXTENSION plpgsql
>   SCHEMA pg_catalog
>   VERSION "1.0";
> ALTER EXTENSION plpgsql
>   OWNER TO postgres;
>
> could just as easily specify the actual database owner
> instead?

I have not spent enough time with 9.1, exploring the change over to EXTENSIONs
to manage a language to give you a definitive answer. However it would seem you
can peg a LANGUAGE to a database owner:

http://www.postgresql.org/docs/9.1/interactive/sql-createlanguage.html

"
Ordinarily, the user must have the PostgreSQL superuser privilege to register a
new language. However, the owner of a database can register a new language
within that database if the language is listed in the pg_pltemplate catalog and
is marked as allowed to be created by database owners (tmpldbacreate is true).
The default is that trusted languages can be created by database owners, but
this can be adjusted by superusers by modifying the contents of pg_pltemplate.
The creator of a language becomes its owner and can later drop it, rename it, or
assign it to a new owner.
"

Not sure how that interacts with the EXTENSION mechanism though:(

--
Adrian Klaver
adrian.klaver@gmail.com

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Orphaned temp table
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_class.relnamespace NOT IN pg_namespace.oid