Re: DELETE / UPDATE from partition not optimized (11.0)

Поиск
Список
Период
Сортировка
От Justin Pryzby
Тема Re: DELETE / UPDATE from partition not optimized (11.0)
Дата
Msg-id 20181026154540.GA27004@telsasoft.com
обсуждение исходный текст
Ответ на DELETE / UPDATE from partition not optimized (11.0)  (Dave E Martin <postgresql2-to.dave@dave.to>)
Ответы Re: DELETE / UPDATE from partition not optimized (11.0)  (Justin Pryzby <pryzby@telsasoft.com>)
Список pgsql-performance
On Thu, Oct 25, 2018 at 10:43:10AM -0600, Dave E Martin wrote:
> If SELECT is confident enough to limit itself to one partition, why isn't
> DELETE (or UPDATE)?

Because of this limitation:

https://www.postgresql.org/docs/current/static/ddl-partitioning.html#DDL-PARTITION-PRUNING
|Currently, pruning of partitions during the planning of an UPDATE or DELETE
|command is implemented using the constraint exclusion method (however, it is
|controlled by the enable_partition_pruning rather than constraint_exclusion) —
|see the following section for details and caveats that apply.

Justin


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

Предыдущее
От: Dave E Martin
Дата:
Сообщение: DELETE / UPDATE from partition not optimized (11.0)
Следующее
От: Jeff Janes
Дата:
Сообщение: Re: Gained %20 performance after disabling bitmapscan