explain.depesz.com

PostgreSQL's explain analyze made readable

Result: r0AN : Optimization for: plan #PwW9

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 0.108 52.364 ↓ 8.9 89 1

Nested Loop Left Join (cost=109,117.61..109,734.39 rows=10 width=474) (actual time=4.854..52.364 rows=89 loops=1)

  • Filter: ((vbe.match_type <> 'SNIPPET'::text) OR ((vbs.review_status = 'REVIEWED'::text) AND (NOT vbs.ignored)))
2.          

CTE vbcid

3. 0.087 51.606 ↓ 35.0 35 1

Nested Loop Semi Join (cost=0.43..109,115.93 rows=1 width=8) (actual time=4.803..51.606 rows=35 loops=1)

4. 50.519 50.519 ↑ 3.4 50 1

Seq Scan on version_bom_component vbc_1 (cost=0.00..14,066.69 rows=168 width=8) (actual time=4.724..50.519 rows=50 loops=1)

  • Filter: (version_bom_id = 1801)
  • Rows Removed by Filter: 314532
5. 1.000 1.000 ↑ 1.0 1 50

Index Scan using idx_version_bom_entry_version_bom_component_id on version_bom_entry vbe_1 (cost=0.43..562.42 rows=1 width=8) (actual time=0.020..0.020 rows=1 loops=50)

  • Index Cond: (version_bom_component_id = vbc_1.id)
  • Filter: ((license_definition)::text ~ '"codeSharing": 1'::text)
  • Rows Removed by Filter: 1
6. 0.048 52.167 ↓ 8.9 89 1

Nested Loop (cost=1.41..547.14 rows=10 width=466) (actual time=4.841..52.167 rows=89 loops=1)

7. 0.042 52.014 ↓ 35.0 35 1

Nested Loop (cost=0.98..22.95 rows=1 width=41) (actual time=4.836..52.014 rows=35 loops=1)

8. 0.012 51.902 ↓ 35.0 35 1

Nested Loop (cost=0.70..15.61 rows=1 width=33) (actual time=4.824..51.902 rows=35 loops=1)

9. 0.052 51.785 ↓ 35.0 35 1

Nested Loop (cost=0.42..8.47 rows=1 width=25) (actual time=4.815..51.785 rows=35 loops=1)

10. 51.628 51.628 ↓ 35.0 35 1

CTE Scan on vbcid (cost=0.00..0.02 rows=1 width=8) (actual time=4.806..51.628 rows=35 loops=1)

11. 0.105 0.105 ↑ 1.0 1 35

Index Scan using version_bom_component_pkey on version_bom_component vbc (cost=0.42..8.44 rows=1 width=17) (actual time=0.003..0.003 rows=1 loops=35)

  • Index Cond: (id = vbcid.id)
12. 0.105 0.105 ↑ 1.0 1 35

Index Scan using version_bom_pkey on version_bom vb (cost=0.28..7.13 rows=1 width=24) (actual time=0.003..0.003 rows=1 loops=35)

  • Index Cond: (id = vbc.version_bom_id)
13. 0.070 0.070 ↑ 1.0 1 35

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

  • Index Cond: (id = vb.release_id)
14. 0.105 0.105 ↑ 56.3 3 35

Index Scan using idx_version_bom_entry_version_bom_component_id on version_bom_entry vbe (cost=0.43..522.49 rows=169 width=441) (actual time=0.002..0.003 rows=3 loops=35)

  • Index Cond: (version_bom_component_id = vbc.id)
15. 0.089 0.089 ↓ 0.0 0 89

Index Scan using version_bom_snippet_pkey on version_bom_snippet vbs (cost=0.28..7.11 rows=1 width=22) (actual time=0.001..0.001 rows=0 loops=89)

  • Index Cond: (id = vbe.id)