Re: Only owners can ANALYZE tables...seems overly restrictive

Поиск
Список
Период
Сортировка
От Vitaly Burovoy
Тема Re: Only owners can ANALYZE tables...seems overly restrictive
Дата
Msg-id CAKOSWNkmc=EYnhCKjztGvx67gEm_UpCO==VCYfqLo-ju3_fN0w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Only owners can ANALYZE tables...seems overly restrictive  (John R Pierce <pierce@hogranch.com>)
Список pgsql-general
On 2/28/16, John R Pierce <pierce@hogranch.com> wrote:
> I don't see why anyone with delete privileges shouldn't be able to
> truncate (after all, thats the same as deleting all records).

Firstly, because you can prevent deleting some rows by a trigger;
TRUNCATE doesn't deal with rows.
Secondary, TRUNCATE is _NOT_ MVCC. Even in a not yet finished
transaction other connections can see empty table.
Thirdly, TRUNCATE is often used for clearing most of (or even all) DB
tables for tests. Splitting privileges is one of possible protection
for running tests on a prod server (if config files are copied
wrongly).

>
> --
> john r pierce, recycling bits in santa cruz

--
Best regards,
Vitaly Burovoy


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

Предыдущее
От: John R Pierce
Дата:
Сообщение: Re: Only owners can ANALYZE tables...seems overly restrictive
Следующее
От: Albe Laurenz
Дата:
Сообщение: Re: Only owners can ANALYZE tables...seems overly restrictive