Re: About PostgreSQL Query Plan

Поиск
Список
Период
Сортировка
От hubert depesz lubaczewski
Тема Re: About PostgreSQL Query Plan
Дата
Msg-id Z4U0gAcTLQ8sX29J@depesz.com
обсуждение исходный текст
Список pgsql-general
On Mon, Jan 13, 2025 at 05:26:09PM +0300, Eşref Halıcıoğlu wrote:
> Hello,
>  
> I have a query in PostgreSQL and I want this query to retrieve only data from the last 3 months. However, when I
examinethe query
 
> plan, I see that all partitions are listed.

Please note that your explain is for update, not select (which
"retrieve" in your mail would suggest).

> This raises a few questions in my mind:
> 
>   • Are all partitions really being accessed, or only the partitions of the last 3 months are being accessed while
theother
 
>     partitions have to be shown in the query plan?

Not really possible to tell without reading explain *analyze*.
Potentially all. But perhaps just fewer.

Best regards,

depesz




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