explain.depesz.com

PostgreSQL's explain analyze made readable

Result: JESY : filter 1

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 1.133 ↓ 4.0 4 1

Nested Loop Anti Join (cost=16.26..24.72 rows=1 width=16) (actual time=0.479..1.133 rows=4 loops=1)

2. 0.014 1.120 ↓ 4.0 4 1

Nested Loop Semi Join (cost=15.99..24.36 rows=1 width=32) (actual time=0.472..1.120 rows=4 loops=1)

  • Join Filter: ("c"."id" = "channel_subscription_packs"."channel")
3. 0.035 1.004 ↓ 51.0 51 1

Nested Loop (cost=15.71..24.05 rows=1 width=48) (actual time=0.117..1.004 rows=51 loops=1)

4. 0.048 0.663 ↓ 51.0 51 1

Nested Loop (cost=15.43..18.72 rows=1 width=32) (actual time=0.097..0.663 rows=51 loops=1)

5. 0.142 0.216 ↓ 57.0 57 1

Bitmap Heap Scan on "assets" "a" (cost=15.00..16.26 rows=1 width=16) (actual time=0.082..0.216 rows=57 loops=1)

  • Recheck Cond: ("to_tsvector"('"english_nostop"'::"regconfig", "name") @@ '''red'' & ''octob'':*'::"tsquery")
  • Heap Blocks: exact=57
6. 0.074 0.074 ↓ 57.0 57 1

Bitmap Index Scan on "assets_to_tsvector_idx" (cost=0.00..15.00 rows=1 width=0) (actual time=0.074..0.074 rows=57 loops=1)

  • Index Cond: ("to_tsvector"('"english_nostop"'::"regconfig", "name") @@ '''red'' & ''octob'':*'::"tsquery")
7. 0.399 0.399 ↑ 1.0 1 57

Index Scan using "linear_asset_channel_idx" on "linear" "l" (cost=0.43..2.45 rows=1 width=48) (actual time=0.007..0.007 rows=1 loops=57)

  • Index Cond: ("asset" = "a"."id")
8. 0.102 0.306 ↑ 1.0 1 51

Index Only Scan using "channels_pkey" on "channels" "c" (cost=0.28..5.31 rows=1 width=16) (actual time=0.006..0.006 rows=1 loops=51)

  • Index Cond: ("id" = "l"."channel")
  • Filter: (((NOT (alternatives: SubPlan 1 or hashed SubPlan 2)) OR (alternatives: SubPlan 3 or hashed SubPlan 4)) AND ((NOT (alternatives: SubPlan 5 or hashed SubPlan 6)) OR (alternatives: SubPlan 7 or hashed SubPlan 8)))
  • Heap Fetches: 51
9.          

SubPlan (forIndex Only Scan)

10. 0.153 0.153 ↓ 0.0 0 51

Seq Scan on "channel_allowed_timezones" (cost=0.00..1.35 rows=4 width=0) (actual time=0.003..0.003 rows=0 loops=51)

  • Filter: ("channel" = "c"."id")
  • Rows Removed by Filter: 28
11. 0.000 0.000 ↓ 0.0 0

Seq Scan on "channel_allowed_timezones" "channel_allowed_timezones_1" (cost=0.00..1.28 rows=28 width=16) (never executed)

12. 0.000 0.000 ↓ 0.0 0

Seq Scan on "channel_allowed_timezones" "channel_allowed_timezones_2" (cost=0.00..1.42 rows=1 width=0) (never executed)

  • Filter: (("channel" = "c"."id") AND ("timezone" = '-0700'::"text"))
13. 0.000 0.000 ↓ 0.0 0

Seq Scan on "channel_allowed_timezones" "channel_allowed_timezones_3" (cost=0.00..1.35 rows=4 width=16) (never executed)

  • Filter: ("timezone" = '-0700'::"text")
14. 0.051 0.051 ↓ 0.0 0 51

Index Only Scan using "channel_allowed_dmas_pkey" on "channel_allowed_dmas" (cost=0.28..15.29 rows=22 width=0) (actual time=0.001..0.001 rows=0 loops=51)

  • Index Cond: ("channel" = "c"."id")
  • Heap Fetches: 0
15. 0.000 0.000 ↓ 0.0 0

Seq Scan on "channel_allowed_dmas" "channel_allowed_dmas_1" (cost=0.00..46.13 rows=2,813 width=16) (never executed)

16. 0.000 0.000 ↓ 0.0 0

Index Only Scan using "channel_allowed_dmas_pkey" on "channel_allowed_dmas" "channel_allowed_dmas_2" (cost=0.28..2.30 rows=1 width=0) (never executed)

  • Index Cond: (("channel" = "c"."id") AND ("dma" = 770))
  • Heap Fetches: 0
17. 0.000 0.000 ↓ 0.0 0

Seq Scan on "channel_allowed_dmas" "channel_allowed_dmas_3" (cost=0.00..53.16 rows=12 width=16) (never executed)

  • Filter: ("dma" = 770)
18. 0.102 0.102 ↓ 0.0 0 51

Index Only Scan using "channel_subscription_packs_pkey" on "channel_subscription_packs" (cost=0.28..0.30 rows=1 width=16) (actual time=0.002..0.002 rows=0 loops=51)

  • Index Cond: (("channel" = "l"."channel") AND ("subscription_pack" = ANY ('{5cdb1742-8311-4f96-a669-4571e418f17d}'::"uuid"[])))
  • Heap Fetches: 4
19. 0.012 0.012 ↓ 0.0 0 4

Index Only Scan using "channel_device_restrictions_pkey" on "channel_device_restrictions" (cost=0.28..0.31 rows=1 width=16) (actual time=0.003..0.003 rows=0 loops=4)

  • Index Cond: (("channel" = "c"."id") AND ("device" = 'browser'::"text"))
  • Heap Fetches: 0