explain.depesz.com

PostgreSQL's explain analyze made readable

Result: eq6U : Optimization for: plan #347v

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 91.335 129.194 ↓ 3.0 8,261 1

Aggregate (cost=1,677.27..8,680.44 rows=2,762 width=204) (actual time=35.091..129.194 rows=8,261 loops=1)

  • Buffers: shared hit=338, temp read=359 written=360
2. 17.467 37.859 ↓ 3.0 19,095 1

Sort (cost=1,677.27..1,693.18 rows=6,365 width=156) (actual time=34.939..37.859 rows=19,095 loops=1)

  • Sort Key: cities.id
  • Sort Method: external merge Disk: 2872kB
  • Buffers: shared hit=338, temp read=359 written=360
3. 3.867 20.392 ↓ 3.0 19,095 1

Hash Join (cost=874.38..1,275.13 rows=6,365 width=156) (actual time=8.089..20.392 rows=19,095 loops=1)

  • Buffers: shared hit=338
4. 6.342 16.489 ↓ 3.0 19,095 1

Hash Join (cost=870.69..1,253.79 rows=6,365 width=153) (actual time=8.046..16.489 rows=19,095 loops=1)

  • Buffers: shared hit=336
5. 2.116 2.116 ↑ 1.0 19,095 1

Seq Scan on city_provider_source city_provider_source (cost=0..332.95 rows=19,095 width=17) (actual time=0.007..2.116 rows=19,095 loops=1)

  • Buffers: shared hit=142
6. 2.222 8.031 ↓ 3.0 8,286 1

Hash (cost=836.16..836.16 rows=2,762 width=140) (actual time=8.03..8.031 rows=8,286 loops=1)

  • Buffers: shared hit=194
7. 5.809 5.809 ↓ 3.0 8,286 1

Seq Scan on cities cities (cost=0..836.16 rows=2,762 width=140) (actual time=0.023..5.809 rows=8,286 loops=1)

  • Filter: (st_distance(st_setsrid(cities.bbox, 4326), '0101000020E610000000000000800F3640F4E942B024854740'::geometry) < '1000000'::double precision)
  • Buffers: shared hit=194
8. 0.016 0.036 ↑ 1.0 75 1

Hash (cost=2.75..2.75 rows=75 width=11) (actual time=0.036..0.036 rows=75 loops=1)

  • Buffers: shared hit=2
9. 0.020 0.020 ↑ 1.0 75 1

Seq Scan on providers providers (cost=0..2.75 rows=75 width=11) (actual time=0.009..0.02 rows=75 loops=1)

  • Buffers: shared hit=2