Re: slow query to improve performace

Поиск
Список
Период
Сортировка
От Jeff Janes
Тема Re: slow query to improve performace
Дата
Msg-id CAMkU=1wUubr0coupaEBo6u8pyOHt+HLxH=qZ+fidJUp81f53jQ@mail.gmail.com
обсуждение исходный текст
Ответ на slow query to improve performace  (Ayub Khan <ayub.hp@gmail.com>)
Список pgsql-performance
On Fri, Feb 25, 2022 at 3:18 PM Ayub Khan <ayub.hp@gmail.com> wrote:
Hi,

Could some some verify the attached query to verify the performance and suggest some steps to improve it, this query is created as a view. This view is used to get the aggregates of orders based on its current status

I don't see how it is possible for that query to yield that plan. For example, what part of that query could have been transformed into this part of the plan "order_status_code <> ALL ('{T,J,C,D}'::bpchar[])"?

Well, I suppose some of the tables used in that query could themselves be views over the same tables?  In that case, we might need to know the definitions of those views.  As well as knowing the version, and seeing the EXPLAIN (ANALYZE, BUFFERS) for the query, run after track_io_timing is turned on.

Cheers,

Jeff

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

Предыдущее
От: Jeff Janes
Дата:
Сообщение: Re: Never Ending query in PostgreSQL
Следующее
От: "ldh@laurent-hasson.com"
Дата:
Сообщение: RE: An I/O error occurred while sending to the backend (PG 13.4)