explain.depesz.com

PostgreSQL's explain analyze made readable

Result: G9uJ

Settings
# exclusive inclusive rows x rows loops node
1. 0.214 240.454 ↓ 0.0 0 1

Delete on exploitation_engine_result (cost=41,734.95..45,178.43 rows=4,989 width=18) (actual time=240.454..240.454 rows=0 loops=1)

2. 0.105 240.240 ↑ 39.3 127 1

Nested Loop (cost=41,734.95..45,178.43 rows=4,989 width=18) (actual time=239.867..240.240 rows=127 loops=1)

3. 0.099 239.881 ↑ 39.3 127 1

HashAggregate (cost=41,734.52..41,784.41 rows=4,989 width=16) (actual time=239.839..239.881 rows=127 loops=1)

  • Group Key: res.id
4. 1.521 239.782 ↑ 39.3 127 1

Nested Loop (cost=0.42..41,722.05 rows=4,989 width=16) (actual time=227.400..239.782 rows=127 loops=1)

5. 234.097 234.097 ↑ 1.2 4,164 1

Seq Scan on horanet_operation ope (cost=0.00..31,380.62 rows=4,989 width=10) (actual time=1.049..234.097 rows=4,164 loops=1)

  • Filter: (("time" > '2020-05-30 12:00:00'::timestamp without time zone) AND (action_id <> 1))
  • Rows Removed by Filter: 852,154
6. 4.164 4.164 ↓ 0.0 0 4,164

Index Scan using exploitation_engine_result_trigger_operation on exploitation_engine_result res (cost=0.42..2.06 rows=1 width=14) (actual time=0.001..0.001 rows=0 loops=4,164)

  • Index Cond: (trigger_operation_id = ope.id)
7. 0.254 0.254 ↑ 1.0 1 127

Index Scan using exploitation_engine_result_pkey on exploitation_engine_result (cost=0.42..0.67 rows=1 width=10) (actual time=0.002..0.002 rows=1 loops=127)

  • Index Cond: (id = res.id)
Planning time : 0.402 ms
Execution time : 4,775.699 ms
Trigger times:
Trigger Name:Total time:Calls:Average time:
for constraint device_query_resulting_engine_result_id_fkey 8.469 ms 127 0.067 ms
for constraint device_response_origin_engine_result_id_fkey 2.751 ms 127 0.022 ms
for constraint horanet_operation_origin_engine_result_id_fkey 4.648 ms 127 0.037 ms
for constraint horanet_operation_resulting_engine_result_id_fkey 16.491 ms 127 0.130 ms
for constraint horanet_usage_origin_engine_result_id_fkey 4,502.507 ms 127 35.453 ms