explain.depesz.com

PostgreSQL's explain analyze made readable

Result: DBiF : Optimization for: plan #KXR7

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Nested Loop (cost=315,825.33..941,241.34 rows=3,275 width=482) (actual rows= loops=)

2.          

CTE vbcid

3. 0.000 0.000 ↓ 0.0

Seq Scan on version_bom_entry (cost=0.00..315,759.98 rows=322 width=8) (actual rows= loops=)

  • Filter: ((license_definition)::text ~ '"codeSharing": 1'::text)
4. 0.000 0.000 ↓ 0.0

Nested Loop (cost=64.92..5,013.00 rows=322 width=49) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Hash Join (cost=64.64..2,647.99 rows=322 width=41) (actual rows= loops=)

  • Hash Cond: (vbc.version_bom_id = vb.id)
6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.42..2,579.34 rows=322 width=25) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

CTE Scan on vbcid (cost=0.00..6.44 rows=322 width=8) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Index Scan using version_bom_component_pkey on version_bom_component vbc (cost=0.42..7.98 rows=1 width=17) (actual rows= loops=)

  • Index Cond: (id = vbcid.id)
9. 0.000 0.000 ↓ 0.0

Hash (cost=46.32..46.32 rows=1,432 width=24) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Seq Scan on version_bom vb (cost=0.00..46.32 rows=1,432 width=24) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Index Scan using pk_central_release on central_release cr (cost=0.28..7.33 rows=1 width=24) (actual rows= loops=)

  • Index Cond: (id = vb.release_id)
12. 0.000 0.000 ↓ 0.0

Index Scan using idx_version_bom_entry_version_bom_component_id on version_bom_entry vbe (cost=0.43..1,925.18 rows=169 width=433) (actual rows= loops=)

  • Index Cond: (version_bom_component_id = vbc.id)
  • Filter: ((match_type <> 'SNIPPET'::text) OR (alternatives: SubPlan 2 or hashed SubPlan 3))
13.          

SubPlan (for Index Scan)

14. 0.000 0.000 ↓ 0.0

Index Scan using version_bom_snippet_pkey on version_bom_snippet vbs (cost=0.28..8.30 rows=1 width=0) (actual rows= loops=)

  • Index Cond: (id = vbe.id)
  • Filter: ((NOT ignored) AND (review_status = 'REVIEWED'::text))
15. 0.000 0.000 ↓ 0.0

Seq Scan on version_bom_snippet vbs_1 (cost=0.00..76.45 rows=1 width=8) (actual rows= loops=)

  • Filter: ((NOT ignored) AND (review_status = 'REVIEWED'::text))