explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 5Scl

Settings
# exclusive inclusive rows x rows loops node
1. 0.005 1,722.666 ↑ 1.0 4 1

Finalize GroupAggregate (cost=371,393.86..371,393.96 rows=4 width=12) (actual time=1,722.664..1,722.666 rows=4 loops=1)

  • Group Key: tr.transaction_review_status_id
2. 0.000 1,722.661 ↑ 1.1 7 1

Sort (cost=371,393.86..371,393.88 rows=8 width=12) (actual time=1,722.660..1,722.661 rows=7 loops=1)

  • Sort Key: tr.transaction_review_status_id
  • Sort Method: quicksort Memory: 25kB
3. 147.651 1,865.567 ↑ 1.1 7 1

Gather (cost=371,392.90..371,393.74 rows=8 width=12) (actual time=1,722.614..1,865.567 rows=7 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
4. 30.263 1,717.916 ↑ 2.0 2 3 / 3

Partial HashAggregate (cost=370,392.90..370,392.94 rows=4 width=12) (actual time=1,717.915..1,717.916 rows=2 loops=3)

  • Group Key: tr.transaction_review_status_id
5. 32.227 1,687.653 ↑ 1.2 130,149 3 / 3

Hash Join (cost=2.92..369,624.40 rows=153,701 width=8) (actual time=2.642..1,687.653 rows=130,149 loops=3)

  • Hash Cond: (sa.screening_applicant_type_id = sat.id)
6. 41.432 1,655.400 ↑ 1.2 130,149 3 / 3

Nested Loop (cost=1.72..369,029.74 rows=153,701 width=12) (actual time=2.599..1,655.400 rows=130,149 loops=3)

7. 0.000 1,223.522 ↑ 1.2 130,149 3 / 3

Nested Loop (cost=1.29..298,205.46 rows=153,701 width=16) (actual time=2.555..1,223.522 rows=130,149 loops=3)

8. 110.048 708.334 ↑ 1.2 132,090 3 / 3

Nested Loop (cost=0.86..223,956.98 rows=159,606 width=8) (actual time=0.120..708.334 rows=132,090 loops=3)

9. 69.226 69.226 ↑ 1.2 132,265 3 / 3

Parallel Index Scan using idx_transaction_reviews_transaction_review_status_id on transaction_reviews tr (cost=0.42..10,958.83 rows=164,443 width=8) (actual time=0.055..69.226 rows=132,265 loops=3)

  • Index Cond: (transaction_review_status_id = ANY ('{1,3,2,4}'::integer[]))
  • Filter: (transaction_review_queue_type_id = 1)
  • Rows Removed by Filter: 1,748
10. 529.060 529.060 ↑ 1.0 1 396,795 / 3

Index Scan using pk_screening_transactions on screening_transactions st (cost=0.44..1.30 rows=1 width=8) (actual time=0.004..0.004 rows=1 loops=396,795)

  • Index Cond: (id = tr.screening_transaction_id)
  • Filter: (screening_status_type_id <> ALL ('{5,3}'::integer[]))
  • Rows Removed by Filter: 0
11. 528.360 528.360 ↑ 1.0 1 396,270 / 3

Index Scan using pk_screening_applicants on screening_applicants sa (cost=0.43..0.47 rows=1 width=12) (actual time=0.004..0.004 rows=1 loops=396,270)

  • Index Cond: (id = st.screening_applicant_id)
  • Filter: (status_type_id <> 3)
  • Rows Removed by Filter: 0
12. 390.446 390.446 ↑ 1.0 1 390,446 / 3

Index Scan using pk_screenings on screenings s (cost=0.43..0.46 rows=1 width=8) (actual time=0.003..0.003 rows=1 loops=390,446)

  • Index Cond: (id = sa.screening_id)
13. 0.005 0.026 ↑ 1.0 9 3 / 3

Hash (cost=1.09..1.09 rows=9 width=4) (actual time=0.026..0.026 rows=9 loops=3)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
14. 0.021 0.021 ↑ 1.0 9 3 / 3

Seq Scan on screening_applicant_types sat (cost=0.00..1.09 rows=9 width=4) (actual time=0.019..0.021 rows=9 loops=3)

Planning time : 2.804 ms
Execution time : 1,865.817 ms