Re: Adding "quota user limit" using triggers

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: Adding "quota user limit" using triggers
Дата
Msg-id 4DF06AAE.908@hogranch.com
обсуждение исходный текст
Ответ на Adding "quota user limit" using triggers  (Andrea Peri <aperi2007@gmail.com>)
Список pgsql-general
On 06/08/11 11:14 PM, Andrea Peri wrote:
> Hi,
>
> Is possible the limit the size of an user  (quota user) as space
> allocated in a tablespace ?
>
> I don't find this option in the 9.0 version of PG,
> so I think it is not available.
>
> Perhaps it should be possible to simulate it using triggers.
>
> However before start to work on it , I like to have a confirm and if
> there is some documentation or information on this
> problem available.

what exactly would this limit?

The total size of tables created by that user regardless of what role
inserted data into said tables?     There's really no way to track the
data written by a user into tables that multiple users have
insert/update privs to.     and does it include older tuple versions
that aren't yet vacuumed?

calculating pg_total_relation_size is fairly expensive, too, it requires
scanning the table and ancilliary items (indexes, toast storage) to sum
up the number of blocks allocated.




--
john r pierce                            N 37, W 122
santa cruz ca                         mid-left coast


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

Предыдущее
От: Andrea Peri
Дата:
Сообщение: Adding "quota user limit" using triggers
Следующее
От: Clemens Schwaighofer
Дата:
Сообщение: plpgsql function with update and seeing changed data from outside during run