explain.depesz.com

PostgreSQL's explain analyze made readable

Result: b96a

Settings
# exclusive inclusive rows x rows loops node
1. 6.186 60.531 ↓ 11.0 5,465 1

Hash Join (cost=4,305.52..11,348.78 rows=496 width=250) (actual time=27.432..60.531 rows=5,465 loops=1)

  • Hash Cond: (ci.location_id = loc.location_id)
2. 2.030 32.461 ↓ 11.0 5,465 1

Hash Join (cost=4,303.86..5,066.65 rows=496 width=137) (actual time=27.331..32.461 rows=5,465 loops=1)

  • Hash Cond: (vd.check_in_id = ci.check_in_id)
3. 3.488 3.488 ↑ 1.0 6,310 1

Seq Scan on video_details vd (cost=0.00..746.22 rows=6,310 width=121) (actual time=0.342..3.488 rows=6,310 loops=1)

  • Filter: media_release
  • Rows Removed by Filter: 3412
4. 3.584 26.943 ↓ 1.1 16,767 1

Hash (cost=4,109.59..4,109.59 rows=15,542 width=32) (actual time=26.942..26.943 rows=16,767 loops=1)

  • Buckets: 32768 (originally 16384) Batches: 1 (originally 1) Memory Usage: 1370kB
5. 23.308 23.359 ↓ 1.1 16,767 1

Bitmap Heap Scan on check_in ci (cost=16.08..4,109.59 rows=15,542 width=32) (actual time=0.135..23.359 rows=16,767 loops=1)

  • Recheck Cond: ((session_start_time >= '2019-06-01 00:00:00+00'::timestamp with time zone) AND (session_start_time <= '2019-07-01 00:00:00+00'::timestamp with time zone))
  • Rows Removed by Index Recheck: 114150
  • Heap Blocks: lossy=2258
6. 0.051 0.051 ↑ 2.0 23,040 1

Bitmap Index Scan on check_in_session_start_time_idx1 (cost=0.00..12.20 rows=45,567 width=0) (actual time=0.051..0.051 rows=23,040 loops=1)

  • Index Cond: ((session_start_time >= '2019-06-01 00:00:00+00'::timestamp with time zone) AND (session_start_time <= '2019-07-01 00:00:00+00'::timestamp with time zone))
7. 0.008 0.024 ↑ 1.0 29 1

Hash (cost=1.29..1.29 rows=29 width=17) (actual time=0.024..0.024 rows=29 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 10kB
8. 0.016 0.016 ↑ 1.0 29 1

Seq Scan on location loc (cost=0.00..1.29 rows=29 width=17) (actual time=0.005..0.016 rows=29 loops=1)

9.          

SubPlan (forHash Join)

10. 4.933 21.860 ↑ 1.0 1 5,465

Nested Loop (cost=0.56..12.64 rows=1 width=17) (actual time=0.004..0.004 rows=1 loops=5,465)

11. 5.465 5.465 ↑ 1.0 1 5,465

Index Only Scan using video_details_id_game_id_unique on video_to_game_id vg (cost=0.29..4.33 rows=1 width=5) (actual time=0.001..0.001 rows=1 loops=5,465)

  • Index Cond: (video_details_id = vd.video_details_id)
  • Filter: (game_id <> 'n1'::text)
  • Rows Removed by Filter: 1
  • Heap Fetches: 0
12. 11.462 11.462 ↑ 1.0 1 5,731

Index Scan using game_game_id_idx on game g (cost=0.28..8.29 rows=1 width=25) (actual time=0.002..0.002 rows=1 loops=5,731)

  • Index Cond: (game_id = vg.game_id)
Planning time : 0.888 ms