explain.depesz.com

PostgreSQL's explain analyze made readable

Result: f6hm

Settings
# exclusive inclusive rows x rows loops node
1. 3.447 14,244.676 ↑ 1.0 1 1

Aggregate (cost=1,047,779.05..1,047,779.06 rows=1 width=29) (actual time=14,244.676..14,244.676 rows=1 loops=1)

2. 664.408 14,241.229 ↑ 176.5 133 1

HashAggregate (cost=1,034,279.61..1,034,514.38 rows=23,477 width=33) (actual time=14,241.112..14,241.229 rows=133 loops=1)

  • Group Key: trr.test_run_id, trr.status, trr.failure_reason, trr.reviewer_action, COALESCE(trr.is_deferred_failure, false)
3.          

Initplan (for HashAggregate)

4. 0.028 0.028 ↑ 1.0 1 1

Seq Scan on db_enums (cost=0.00..7.01 rows=1 width=4) (actual time=0.008..0.028 rows=1 loops=1)

  • Filter: ((name)::text = 'TEST_RUN_RESULT_STATUS_RUNNING'::text)
  • Rows Removed by Filter: 240
5. 459.993 13,576.793 ↓ 1.2 1,411,674 1

Merge Join (cost=152.10..996,913.36 rows=1,149,515 width=33) (actual time=124.030..13,576.793 rows=1,411,674 loops=1)

  • Merge Cond: (tr.id = trr.test_run_id)
6. 76.934 76.934 ↑ 1.0 622,842 1

Index Only Scan using test_runs_pkey on test_runs tr (cost=0.42..18,660.43 rows=632,096 width=4) (actual time=0.018..76.934 rows=622,842 loops=1)

  • Heap Fetches: 8,791
7. 13,039.866 13,039.866 ↓ 1.2 1,411,674 1

Index Scan using fki_test_run_result_test_run_id_index on test_run_results trr (cost=0.57..962,373.10 rows=1,149,515 width=33) (actual time=0.059..13,039.866 rows=1,411,674 loops=1)

  • Index Cond: (test_run_id = ANY ('{3757919,3757918,3757847,3757715,3757701,3757684,3757341,3757261,3756739}'::integer[]))
  • Filter: (rec_type = ANY ('{0,1}'::integer[]))
  • Rows Removed by Filter: 15,938