explain.depesz.com

PostgreSQL's explain analyze made readable

Result: VURS

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Unique (cost=21,597,201,919.62..21,777,862,486.59 rows=200 width=24) (actual rows= loops=)

2.          

Initplan (forUnique)

3. 0.000 0.000 ↓ 0.0

Aggregate (cost=19,428,141.84..19,428,141.85 rows=1 width=4) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Seq Scan on gpsdata gpsdata_1 (cost=0.00..13,184,113.04 rows=499,522,304 width=108) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Sort (cost=21,577,773,777.76..21,668,104,061.25 rows=36,132,113,395 width=24) (actual rows= loops=)

  • Sort Key: gps_withorder.rownum, (st_distance(st_transform(line.geom, 3857), st_transform(gps_withorder.point, 3857)))
6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=139,990,282.22..11,536,591,699.91 rows=36,132,113,395 width=24) (actual rows= loops=)

  • Join Filter: (st_distance(st_transform(line.geom, 3857), st_transform(gps_withorder.point, 3857)) < '10'::double precision)
7. 0.000 0.000 ↓ 0.0

Subquery Scan on gps_withorder (cost=139,990,282.22..154,975,951.34 rows=166,507,435 width=44) (actual rows= loops=)

  • Filter: (gps_withorder."time" < $0)
8. 0.000 0.000 ↓ 0.0

WindowAgg (cost=139,990,282.22..148,731,922.54 rows=499,522,304 width=108) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Sort (cost=139,990,282.22..141,239,087.98 rows=499,522,304 width=36) (actual rows= loops=)

  • Sort Key: gpsdata."time
10. 0.000 0.000 ↓ 0.0

Seq Scan on gpsdata (cost=0.00..13,184,113.04 rows=499,522,304 width=36) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..30.76 rows=651 width=150) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Seq Scan on chengduline line (cost=0.00..27.51 rows=651 width=150) (actual rows= loops=)