explain.depesz.com

PostgreSQL's explain analyze made readable

Result: PZwe

Settings
# exclusive inclusive rows x rows loops node
1. 52.505 370.396 ↓ 1.6 23,994 1

HashAggregate (cost=18,006.35..18,153.84 rows=14,749 width=16) (actual time=366.746..370.396 rows=23,994 loops=1)

  • Group Key: bfsi_staging_urlmodel.domain_id
2. 115.678 317.891 ↓ 2.0 196,098 1

Hash Join (cost=5,767.01..17,760.98 rows=98,150 width=16) (actual time=76.026..317.891 rows=196,098 loops=1)

  • Hash Cond: ((bfsi_staging_keywordserpdcmodel.url_id)::text = (bfsi_staging_urlmodel.url_id)::text)
3. 40.575 134.901 ↓ 2.0 196,098 1

Hash Join (cost=277.57..7,817.89 rows=98,150 width=91) (actual time=8.052..134.901 rows=196,098 loops=1)

  • Hash Cond: (bfsi_staging_productkeywordmapping.keyword_id = bfsi_staging_keywordmodel.keyword)
4. 55.288 90.524 ↓ 2.0 196,098 1

Hash Join (cost=196.98..7,479.19 rows=98,150 width=143) (actual time=4.164..90.524 rows=196,098 loops=1)

  • Hash Cond: (bfsi_staging_keywordserpdcmodel.keyword_id = bfsi_staging_productkeywordmapping.keyword_id)
5. 31.191 31.191 ↑ 1.0 196,098 1

Seq Scan on bfsi_staging_keywordserpdcmodel (cost=0.00..6,766.01 rows=196,301 width=117) (actual time=0.063..31.191 rows=196,098 loops=1)

6. 1.847 4.045 ↓ 2.0 2,382 1

Hash (cost=182.09..182.09 rows=1,191 width=26) (actual time=4.045..4.045 rows=2,382 loops=1)

  • Buckets: 4,096 (originally 2048) Batches: 1 (originally 1) Memory Usage: 168kB
7. 2.126 2.198 ↓ 2.0 2,382 1

Seq Scan on bfsi_staging_productkeywordmapping (cost=117.36..182.09 rows=1,191 width=26) (actual time=0.119..2.198 rows=2,382 loops=1)

  • Filter: ((NOT (hashed SubPlan 1)) AND ((product_id)::text = 'test-work-bench'::text))
8.          

SubPlan (for Seq Scan)

9. 0.001 0.072 ↓ 0.0 0 1

Nested Loop (cost=5.00..117.34 rows=10 width=26) (actual time=0.072..0.072 rows=0 loops=1)

10. 0.071 0.071 ↓ 0.0 0 1

Index Scan using bfsi_staging_urlmodel_domain_id_c93ef4d9 on bfsi_staging_urlmodel u3 (cost=0.42..20.49 rows=4 width=91) (actual time=0.071..0.071 rows=0 loops=1)

  • Index Cond: ((domain_id)::text = ''::text)
11. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on bfsi_staging_keywordserpdcmodel u2 (cost=4.58..24.16 rows=5 width=117) (never executed)

  • Recheck Cond: ((url_id)::text = (u3.url_id)::text)
12. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on bfsi_staging_keywordserpdcmodel_url_id_bbdf981e_like (cost=0.00..4.58 rows=5 width=0) (never executed)

  • Index Cond: ((url_id)::text = (u3.url_id)::text)
13. 2.062 3.802 ↑ 1.0 2,382 1

Hash (cost=50.82..50.82 rows=2,382 width=26) (actual time=3.802..3.802 rows=2,382 loops=1)

  • Buckets: 4,096 Batches: 1 Memory Usage: 168kB
14. 1.740 1.740 ↑ 1.0 2,382 1

Seq Scan on bfsi_staging_keywordmodel (cost=0.00..50.82 rows=2,382 width=26) (actual time=0.027..1.740 rows=2,382 loops=1)

  • Filter: is_active
15. 38.586 67.312 ↑ 1.0 79,486 1

Hash (cost=3,175.86..3,175.86 rows=79,486 width=107) (actual time=67.312..67.312 rows=79,486 loops=1)

  • Buckets: 32,768 Batches: 4 Memory Usage: 2,978kB
16. 28.726 28.726 ↑ 1.0 79,486 1

Seq Scan on bfsi_staging_urlmodel (cost=0.00..3,175.86 rows=79,486 width=107) (actual time=0.039..28.726 rows=79,486 loops=1)

  • Filter: (domain_id IS NOT NULL)
Planning time : 13.260 ms
Execution time : 373.216 ms