explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 5hLL

Settings
# exclusive inclusive rows x rows loops node
1. 0.004 81.163 ↑ 1.0 10 1

```"Limit (cost=72,406.72..72,406.74 rows=10 width=274) (actual time=81.155..81.163 rows=10 loops=1)

2. 1.394 81.159 ↑ 9.5 10 1

Sort (cost=72,406.72..72,406.96 rows=95 width=274) (actual time=81.155..81.159 rows=10 loops=1)

  • Sort Key: (_st_distance((st_makepoint(bike.lon, bike.lat))::geography(Geometry,4326), '0101000020E61000002030C50BD86F5340345D990178FD2940'::geography(Geometry,4326), '0'::double precision, true))
  • Sort Method: top-N heapsort Memory: 28kB
3. 5.347 79.765 ↓ 11.7 1,111 1

Nested Loop (cost=18,720.40..72,404.67 rows=95 width=274) (actual time=16.511..79.765 rows=1,111 loops=1)

4. 57.218 71.085 ↓ 11.6 1,111 1

Bitmap Heap Scan on bike (cost=18,720.12..71,629.72 rows=96 width=139) (actual time=16.401..71.085 rows=1,111 loops=1)

  • Recheck Cond: (axcess_id IS NOT NULL)
  • Filter: ((type <> 'cycle'::keyless_type) AND (status = 'idle'::bike_status) AND ((st_makepoint(lon, lat))::geography(Geometry,4326) && '0101000020E61000002030C50BD86F5340345D990178FD2940'::geography) AND ('0101000020E61000002030C50BD86F5340345D990178FD2940'::geography(Geometry,4326) && _st_expand((st_makepoint(lon, lat))::geography(Geometry,4326), '1500'::double precision)) AND _st_dwithin((st_makepoint(lon, lat))::geography(Geometry,4326), '0101000020E61000002030C50BD86F5340345D990178FD2940'::geography(Geometry,4326), '1500'::double precision, true))
  • Rows Removed by Filter: 16069
  • Heap Blocks: exact=14195
5. 13.867 13.867 ↓ 1.1 18,854 1

Bitmap Index Scan on idx_bike_axcess_id (cost=0.00..18,720.09 rows=17,024 width=0) (actual time=13.867..13.867 rows=18,854 loops=1)

  • Index Cond: (axcess_id IS NOT NULL)
6. 3.333 3.333 ↑ 1.0 1 1,111

Index Scan using axcess_pkey on axcess (cost=0.29..7.81 rows=1 width=135) (actual time=0.003..0.003 rows=1 loops=1,111)

  • Index Cond: (id = bike.axcess_id)
  • Filter: (ota_status = 'COMPLETED'::otastatus)
Planning time : 0.428 ms
Execution time : 81.250 ms