explain.depesz.com

PostgreSQL's explain analyze made readable

Result: TQ7o : Optimization for: plan #q7E1

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 38.772 3,864.194 ↓ 66.7 13,345 1

GroupAggregate (cost=336,819.15..459,656.82 rows=200 width=49) (actual time=2,920.708..3,864.194 rows=13,345 loops=1)

  • Group Key: trip_fare_25.medallion
2. 93.159 3,825.422 ↑ 1.8 200,257 1

Finalize GroupAggregate (cost=336,819.15..452,266.10 rows=369,411 width=45) (actual time=2,920.596..3,825.422 rows=200,257 loops=1)

  • Group Key: trip_fare_25.medallion, (date_trunc('day'::text, trip_fare_25.pickup_datetime))
3. 0.000 3,732.263 ↑ 1.3 560,232 1

Gather Merge (cost=336,819.15..442,107.30 rows=738,822 width=45) (actual time=2,920.587..3,732.263 rows=560,232 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
4. 598.881 10,717.509 ↑ 2.0 186,744 3

Partial GroupAggregate (cost=335,819.13..355,828.88 rows=369,411 width=45) (actual time=2,913.850..3,572.503 rows=186,744 loops=3)

  • Group Key: trip_fare_25.medallion, (date_trunc('day'::text, trip_fare_25.pickup_datetime))
5. 9,020.757 10,118.628 ↑ 1.2 1,231,385 3

Sort (cost=335,819.13..339,667.16 rows=1,539,212 width=45) (actual time=2,913.835..3,372.876 rows=1,231,385 loops=3)

  • Sort Key: trip_fare_25.medallion, (date_trunc('day'::text, trip_fare_25.pickup_datetime))
  • Sort Method: external merge Disk: 74536kB
  • Worker 0: Sort Method: external merge Disk: 75184kB
  • Worker 1: Sort Method: external merge Disk: 74536kB
6. 1,097.871 1,097.871 ↑ 1.2 1,231,385 3

Parallel Seq Scan on trip_fare_25 (cost=0.00..82,933.15 rows=1,539,212 width=45) (actual time=0.538..365.957 rows=1,231,385 loops=3)

Planning time : 0.277 ms
Execution time : 3,886.427 ms