Re: Add SPLIT PARTITION/MERGE PARTITIONS commands

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
Дата
Msg-id CAKFQuwao0EgGe9C5cPwr1e=9nkabiJRCyMAwNo5hjKebjZFoeg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Add SPLIT PARTITION/MERGE PARTITIONS commands  (Alexander Lakhin <exclusion@gmail.com>)
Список pgsql-hackers
On Sunday, April 28, 2024, Alexander Lakhin <exclusion@gmail.com> wrote:

When we deal with mixed ownership, say, bob is an owner of a
partitioned table, but not an owner of a partition, should we
allow him to perform merge with that partition?


Attaching via alter table requires the user to own both the partitioned table and the table being acted upon.  Merge needs to behave similarly.

The fact that we let the superuser break the requirement of common ownership is unfortunate but I guess understandable.  But given the existing behavior of attach merge should likewise fail if it find the user doesn’t own the partitions being merged.  The fact that the user can select from those tables can be acted upon manually if desired; these administrative commands should all ensure common ownership and fail if that precondition is not met.

David J.

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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
Следующее
От: Justin Pryzby
Дата:
Сообщение: Re: Add SPLIT PARTITION/MERGE PARTITIONS commands