explain.depesz.com

PostgreSQL's explain analyze made readable

Result: CLUt

Settings

Optimization(s) for this plan:

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

Seq Scan on subscribers (cost=0.00..635,755,235.25 rows=2,636,209 width=972) (actual rows= loops=)

  • Filter: (((alternatives: SubPlan 1 or hashed SubPlan 2) AND (NOT (alternatives: SubPlan 3 or hashed SubPlan 4))) OR (alternatives: SubPlan 5 or hashed SubPlan 6) OR ((msisdn)::text = '56965817010'::text))
2.          

SubPlan (for Seq Scan)

3. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.87..50.13 rows=1 width=0) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Index Scan using content_value_key on content c (cost=0.43..8.45 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((value)::text = (subscribers.msisdn)::text)
5. 0.000 0.000 ↓ 0.0

Index Scan using file_contents_content_id_ix on file_contents fc (cost=0.44..41.67 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (content_id = c.id)
  • Filter: (file_id = ANY (('{827,749}'::text[])::integer[]))
6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.88..68,633.79 rows=9,804 width=32) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Index Only Scan using file_contents_pkey on file_contents fc_1 (cost=0.44..2,661.99 rows=9,804 width=4) (actual rows= loops=)

  • Index Cond: (file_id = ANY (('{827,749}'::text[])::integer[]))
8. 0.000 0.000 ↓ 0.0

Index Scan using content_pkey on content c_1 (cost=0.43..6.73 rows=1 width=17) (actual rows= loops=)

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

Nested Loop (cost=0.87..50.13 rows=1 width=0) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Index Scan using content_value_key on content c_2 (cost=0.43..8.45 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((value)::text = (subscribers.msisdn)::text)
11. 0.000 0.000 ↓ 0.0

Index Scan using file_contents_content_id_ix on file_contents fc_2 (cost=0.44..41.67 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (content_id = c_2.id)
  • Filter: (file_id = ANY (('{750}'::text[])::integer[]))
12. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.88..37,994.62 rows=4,902 width=32) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Index Only Scan using file_contents_pkey on file_contents fc_3 (cost=0.44..1,364.72 rows=4,902 width=4) (actual rows= loops=)

  • Index Cond: (file_id = ANY (('{750}'::text[])::integer[]))
14. 0.000 0.000 ↓ 0.0

Index Scan using content_pkey on content c_3 (cost=0.43..7.47 rows=1 width=17) (actual rows= loops=)

  • Index Cond: (id = fc_3.content_id)
15. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.87..50.13 rows=1 width=0) (actual rows= loops=)

16. 0.000 0.000 ↓ 0.0

Index Scan using content_value_key on content c_4 (cost=0.43..8.45 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((value)::text = (subscribers.msisdn)::text)
17. 0.000 0.000 ↓ 0.0

Index Scan using file_contents_content_id_ix on file_contents fc_4 (cost=0.44..41.67 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (content_id = c_4.id)
  • Filter: (file_id = ANY (('{926,994,1292,1398,1551,1555}'::text[])::integer[]))
18. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.88..147,702.00 rows=29,413 width=32) (actual rows= loops=)

19. 0.000 0.000 ↓ 0.0

Index Only Scan using file_contents_pkey on file_contents fc_5 (cost=0.44..7,354.15 rows=29,413 width=4) (actual rows= loops=)

  • Index Cond: (file_id = ANY (('{926,994,1292,1398,1551,1555}'::text[])::integer[]))
20. 0.000 0.000 ↓ 0.0

Index Scan using content_pkey on content c_5 (cost=0.43..4.77 rows=1 width=17) (actual rows= loops=)

  • Index Cond: (id = fc_5.content_id)