Re: REVOKE CREATE does not work on default tablespace

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: REVOKE CREATE does not work on default tablespace
Дата
Msg-id 1831.1182794384@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: REVOKE CREATE does not work on default tablespace  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
Ответы Re: REVOKE CREATE does not work on default tablespace  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
Список pgsql-bugs
Zdenek Kotala <Zdenek.Kotala@Sun.COM> writes:
> Tom Lane wrote:
>> It's presumed that the right to create tables within a database entails
>> the right to create them someplace; hence no permissions check is made
>> on the database's default tablespace.  Without that, not only does plain
>> CREATE TABLE fail (including CREATE TEMP TABLE), but any query complex
>> enough to require a temporary file would fail as well.  So you'd pretty
>> much have to grant rights on the tablespace to every user of the database
>> anyway.

> If only temporary objects are problem I think better solution is to create
> pg_temp tablespace which will be used as default for temporary data

Why are you so eager to make CREATE TABLE fail?  (If you really want to
do that there are other ways, for instance revoking create privilege
within the DB.)

Once you've created a database with a given tablespace as default, the
only way to make it stop using the tablespace is to drop the whole DB;
there are no half measures because you can't move the system catalogs
(particularly not pg_class).  So I'm not seeing the point of enforcing
tablespace usage against users of the database rather than at the time
of DB creation.

            regards, tom lane

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

Предыдущее
От: Zdenek Kotala
Дата:
Сообщение: Re: REVOKE CREATE does not work on default tablespace
Следующее
От: "Toru SHIMOGAKI"
Дата:
Сообщение: BUG #3413: character string or multibyte character to "char"