explain.depesz.com

PostgreSQL's explain analyze made readable

Result: FMgv

Settings
# exclusive inclusive rows x rows loops node
1. 0.023 3,116.120 ↑ 2.1 233 1

Limit (cost=380,590.17..380,591.42 rows=500 width=94) (actual time=3,116.071..3,116.120 rows=233 loops=1)

2. 0.173 3,116.097 ↑ 1,384.8 233 1

Sort (cost=380,590.17..381,396.82 rows=322,658 width=94) (actual time=3,116.070..3,116.097 rows=233 loops=1)

  • Sort Key: v.effective_at
  • Sort Method: quicksort Memory: 57kB
3. 1.197 3,115.924 ↑ 1,384.8 233 1

Hash Join (cost=89,886.39..364,512.47 rows=322,658 width=94) (actual time=3,096.450..3,115.924 rows=233 loops=1)

  • Hash Cond: (e.place_description_id = pd.id)
4. 7.677 3,073.132 ↑ 1,384.8 233 1

Hash Join (cost=85,128.48..358,907.56 rows=322,658 width=78) (actual time=3,053.793..3,073.132 rows=233 loops=1)

  • Hash Cond: (pt.job_place_description_optimize_properties_id = e.id)
  • Join Filter: (((v.status)::text = 'SCHEDULED'::text) OR (((v.status)::text = 'FAILED'::text) AND ((SubPlan 1) < 3)
  • Rows Removed by Join Filter: 392
5. 2,449.363 2,449.363 ↑ 516.9 625 1

Gather (cost=39,786.49..312,717.51 rows=323,074 width=25) (actual time=1,948.920..2,449.363 rows=625 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
  • -> Hash Join (cost=38,786.49..279410.11 rows=134,614 width=25) (actual time=1,573.337..2422.707 rows=208 loop
  • Hash Cond: (v.id = pt.job_place_description_optimize_properties_version_id)
  • -> Parallel Seq Scan on job_place_description_optimize_properties_version v (cost=0.00..237339.72 ro
  • Filter: (((status)::text = 'SCHEDULED'::text) OR ((status)::text = 'FAILED'::text))
  • Rows Removed by Filter: 1,196,645
  • -> Hash (cost=23,062.33..23062.33 rows=1,257,933 width=16) (actual time=1,369.332..1369.332 rows=1,256,466
  • Buckets: 2,097,152 Batches: 1 Memory Usage: 75,281kB
6. 0.000 0.000 ↓ 0.0 / 3

Seq Scan on job_pdop_current_version_pointer pt (cost=0.00..23,062.33 rows=1,257,933 width=16) (actual rows= loops=)

7. 607.461 607.461 ↓ 1.0 1,256,466 1

Hash (cost=29,669.77..29,669.77 rows=1,253,777 width=61) (actual time=607.461..607.461 rows=1,256,466 loops=1)

  • Buckets: 2,097,152 Batches: 1 Memory Usage: 131,270kB
  • -> Seq Scan on job_place_description_optimize_properties e (cost=0.00..29669.77 rows=1,253,777 width=61) (ac
8.          

SubPlan (for Hash Join)

9. 8.631 8.631 ↑ 1.0 1 411

Aggregate (cost=19.08..19.09 rows=1 width=8) (actual time=0.020..0.021 rows=1 loops=411)

  • -> Index Scan using job_place_description_optimize_properties_version_ux1 on job_place_description_optimi
  • Index Cond: (job_place_description_optimize_properties_id = e.id)
  • Filter: ((status)::text = 'FAILED'::text)
  • Rows Removed by Filter: 7
10. 41.595 41.595 ↓ 1.0 141,952 1

Hash (cost=2,986.85..2,986.85 rows=141,685 width=24) (actual time=41.595..41.595 rows=141,952 loops=1)

  • Buckets: 262,144 Batches: 1 Memory Usage: 9,811kB
  • -> Seq Scan on place_description pd (cost=0.00..2986.85 rows=141,685 width=24) (actual time=0.007..17.299 rows=14