explain.depesz.com

PostgreSQL's explain analyze made readable

Result: VM2x

Settings
# exclusive inclusive rows x rows loops node
1. 0.002 1,461.244 ↑ 6.4 7 1

Limit (cost=261,024.62..261,024.73 rows=45 width=680) (actual time=1,461.244..1,461.244 rows=7 loops=1)

2. 0.021 1,461.242 ↑ 7.4 7 1

Sort (cost=261,024.62..261,024.75 rows=52 width=680) (actual time=1,461.242..1,461.242 rows=7 loops=1)

  • Sort Key: teaser.created_at DESC
  • Sort Method: quicksort Memory: 26kB
3. 0.016 1,461.221 ↑ 7.4 7 1

Nested Loop (cost=1.44..261,023.14 rows=52 width=680) (actual time=66.484..1,461.221 rows=7 loops=1)

  • Join Filter: (teaser.id = teaser_country_relation.teaser_id)
4. 0.104 1,461.121 ↑ 84.0 6 1

Nested Loop (cost=0.87..228,941.92 rows=504 width=684) (actual time=66.461..1,461.121 rows=6 loops=1)

5. 1,460.698 1,460.698 ↑ 65.8 29 1

Index Scan using "idx-teaser-clicks" on teaser (cost=0.43..212,916.21 rows=1,908 width=680) (actual time=55.706..1,460.698 rows=29 loops=1)

  • Index Cond: ((clicks >= 180000) AND (clicks <= 510000))
  • Filter: (to_tsvector((title)::text) @@ plainto_tsquery('bC'::text))
  • Rows Removed by Filter: 329972
6. 0.319 0.319 ↓ 0.0 0 29

Index Scan using "idx-teaser_network_relation-teaser_id" on teaser_network_relation (cost=0.43..8.39 rows=1 width=4) (actual time=0.011..0.011 rows=0 loops=29)

  • Index Cond: (teaser_id = teaser.id)
  • Filter: (network_id = ANY ('{13,3}'::integer[]))
  • Rows Removed by Filter: 2
7. 0.084 0.084 ↑ 19.0 1 6

Index Scan using "idx-teaser_country_relation-teaser_id" on teaser_country_relation (cost=0.57..63.42 rows=19 width=4) (actual time=0.012..0.014 rows=1 loops=6)

  • Index Cond: (teaser_id = teaser_network_relation.teaser_id)
  • Filter: (country_id = ANY ('{3,67}'::integer[]))
  • Rows Removed by Filter: 28