postgresql long running query

Поиск
Список
Период
Сортировка
От liam saffioti
Тема postgresql long running query
Дата
Msg-id CAGHjuaZkGZVRK6OC4ifBJVQ+=1Y=0CXdDnZ7sjHkdfY2wkACVg@mail.gmail.com
обсуждение исходный текст
Ответы AW: postgresql long running query  ("Dischner, Anton" <Anton.Dischner@med.uni-muenchen.de>)
Список pgsql-admin
Hello Team,

I have a problem with a query that consumes a long time. 
The query' execution plan is :


EXPLAIN ANALYZE SELECT x."HistoryId", x."SlaDefinition" FROM "T_CMN_SLAHISTORY" AS x WHERE x."DefinitionId" = '302';
                                                                        QUERY PLAN                                                                        
-----------------------------------------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on "T_CMN_SLAHISTORY" x  (cost=2144.77..35086.42 rows=139012 width=8) (actual time=58.806..116.874 rows=135498 loops=1)
   Recheck Cond: ("DefinitionId" = 302)
   Heap Blocks: exact=2175
   ->  Bitmap Index Scan on "Index-20180712-192739"  (cost=0.00..2110.02 rows=139012 width=0) (actual time=57.043..57.045 rows=135498 loops=1)
         Index Cond: ("DefinitionId" = 302)
 Planning Time: 11.132 ms
 Execution Time: 120.320 ms



But, the query execution time was 43min 11seconds in the morning in pgbadger report. I don't understand why the query is taking so long. Can you guide me?

Thank you so much.

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

Предыдущее
От: Jiankang Ji
Дата:
Сообщение: Re: Are you working on both pentaho and postgresql?
Следующее
От: "Dischner, Anton"
Дата:
Сообщение: AW: postgresql long running query