explain.depesz.com

PostgreSQL's explain analyze made readable

Result: eVQ0

Settings
# exclusive inclusive rows x rows loops node
1. 0.034 4,149.354 ↑ 6.5 31 1

Sort (cost=734,164.93..734,165.43 rows=200 width=40) (actual time=4,149.352..4,149.354 rows=31 loops=1)

  • Sort Key: tblmovements.commodity
  • Sort Method: quicksort Memory: 27kB
2. 1.124 4,149.320 ↑ 6.5 31 1

HashAggregate (cost=734,150.29..734,157.29 rows=200 width=40) (actual time=4,149.308..4,149.320 rows=31 loops=1)

  • Group Key: tblmovements.commodity
3. 1.617 4,148.196 ↑ 106.1 2,835 1

Finalize HashAggregate (cost=716,104.21..725,127.25 rows=300,768 width=67) (actual time=4,144.677..4,148.196 rows=2,835 loops=1)

  • Group Key: tblmovements.trip_id
4. 341.445 4,146.579 ↑ 318.3 2,835 1

Gather (cost=611,587.33..704,825.41 rows=902,304 width=155) (actual time=3,527.801..4,146.579 rows=2,835 loops=1)

  • Workers Planned: 3
  • Workers Launched: 3
5. 1,121.198 3,805.134 ↑ 424.2 709 4

Partial HashAggregate (cost=610,587.33..613,595.01 rows=300,768 width=155) (actual time=3,802.986..3,805.134 rows=709 loops=4)

  • Group Key: tblmovements.trip_id
6. 780.279 2,683.936 ↑ 2.5 3,456,820 4

Parallel Hash Left Join (cost=16,190.91..461,553.69 rows=8,516,208 width=43) (actual time=82.145..2,683.936 rows=3,456,820 loops=4)

  • Hash Cond: (tblsegments.trip_id = v_transit_movement_extras.trip_id)
7. 837.400 1,871.020 ↑ 2.5 3,456,820 4

Parallel Hash Join (cost=10,335.19..433,342.60 rows=8,516,208 width=35) (actual time=48.404..1,871.020 rows=3,456,820 loops=4)

  • Hash Cond: (tblsegments.trip_id = tblmovements.trip_id)
8. 985.542 986.837 ↑ 2.5 3,456,820 4

Nested Loop (cost=184.49..400,836.55 rows=8,516,208 width=16) (actual time=0.993..986.837 rows=3,456,820 loops=4)

9. 0.272 0.451 ↑ 4.4 709 4

Parallel Bitmap Heap Scan on tblsegments tblsegments_1 (cost=183.92..37,087.49 rows=3,136 width=8) (actual time=0.230..0.451 rows=709 loops=4)

  • Recheck Cond: (link_id = 1464746470)
  • Heap Blocks: exact=5
10. 0.179 0.179 ↑ 3.4 2,835 1

Bitmap Index Scan on seglink (cost=0.00..181.49 rows=9,723 width=0) (actual time=0.179..0.179 rows=2,835 loops=1)

  • Index Cond: (link_id = 1464746470)
11. 0.844 0.844 ↓ 1.8 4,877 2,835

Index Only Scan using idx_tblsegments_keyrev on tblsegments (cost=0.57..89.21 rows=2,678 width=16) (actual time=0.016..0.844 rows=4,877 loops=2,835)

  • Index Cond: (trip_id = tblsegments_1.trip_id)
  • Heap Fetches: 0
12. 24.007 46.783 ↑ 1.7 75,192 4

Parallel Hash (cost=8,584.20..8,584.20 rows=125,320 width=27) (actual time=46.782..46.783 rows=75,192 loops=4)

  • Buckets: 524288 Batches: 1 Memory Usage: 23776kB
13. 22.776 22.776 ↑ 1.7 75,192 4

Parallel Seq Scan on tblmovements (cost=0.00..8,584.20 rows=125,320 width=27) (actual time=0.382..22.776 rows=75,192 loops=4)

14. 19.972 32.637 ↑ 2.4 74,662 4

Parallel Hash (cost=3,659.76..3,659.76 rows=175,676 width=24) (actual time=32.637..32.637 rows=74,662 loops=4)

  • Buckets: 524288 Batches: 1 Memory Usage: 20512kB
15. 12.665 12.665 ↑ 2.4 74,662 4

Parallel Seq Scan on v_transit_movement_extras (cost=0.00..3,659.76 rows=175,676 width=24) (actual time=0.285..12.665 rows=74,662 loops=4)