explain.depesz.com

PostgreSQL's explain analyze made readable

Result: joFn

Settings
# exclusive inclusive rows x rows loops node
1. 418.931 83,256.144 ↑ 101.6 873 1

GroupAggregate (cost=12,845,664.48..12,848,324.55 rows=88,669 width=187) (actual time=82,725.773..83,256.144 rows=873 loops=1)

  • Group Key: sp.id, pst.id
2. 617.634 82,837.213 ↓ 6.6 580,822 1

Sort (cost=12,845,664.48..12,845,886.15 rows=88,669 width=163) (actual time=82,724.520..82,837.213 rows=580,822 loops=1)

  • Sort Key: sp.id, pst.id
  • Sort Method: quicksort Memory: 178,853kB
3. 0.000 82,219.579 ↓ 6.6 580,822 1

Gather (cost=39,022.30..12,838,377.60 rows=88,669 width=163) (actual time=13,904.289..82,219.579 rows=580,822 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
4. 133.395 82,232.895 ↓ 5.2 193,607 3 / 3

Parallel Hash Left Join (cost=38,022.30..12,828,510.70 rows=36,945 width=163) (actual time=13,523.762..82,232.895 rows=193,607 loops=3)

  • Hash Cond: (sp.id = pst.id)
5. 8,645.533 81,573.488 ↓ 5.2 193,607 3 / 3

Hash Join (cost=2,168.56..12,792,559.98 rows=36,945 width=41) (actual time=12,991.323..81,573.488 rows=193,607 loops=3)

  • Hash Cond: (mr.supply_point_id = sp.id)
6. 72,927.171 72,927.171 ↑ 1.4 77,958,567 3 / 3

Parallel Seq Scan on meters_raw mr (cost=0.00..12,509,556.60 rows=106,984,438 width=16) (actual time=0.213..72,927.171 rows=77,958,567 loops=3)

  • Filter: ((created_on >= '2020-09-13 00:00:00+02'::timestamp with time zone) AND (created_on < '2020-10-14 00:00:00+02'::timestamp with time zone))
  • Rows Removed by Filter: 188,456,338
7. 0.276 0.784 ↓ 1.7 1,017 3 / 3

Hash (cost=2,160.92..2,160.92 rows=611 width=29) (actual time=0.781..0.784 rows=1,017 loops=3)

  • Buckets: 1,024 Batches: 1 Memory Usage: 56kB
8. 0.326 0.508 ↓ 1.7 1,017 3 / 3

Bitmap Heap Scan on supply_points sp (cost=29.16..2,160.92 rows=611 width=29) (actual time=0.209..0.508 rows=1,017 loops=3)

  • Recheck Cond: (meter_group_id = 1,608)
  • Heap Blocks: exact=9
9. 0.182 0.182 ↓ 1.7 1,017 3 / 3

Bitmap Index Scan on idx_supply_points_group_id (cost=0.00..29.01 rows=611 width=0) (actual time=0.181..0.182 rows=1,017 loops=3)

  • Index Cond: (meter_group_id = 1,608)
10. 363.788 526.012 ↑ 1.3 428,577 3 / 3

Parallel Hash (cost=29,157.22..29,157.22 rows=535,722 width=122) (actual time=526.010..526.012 rows=428,577 loops=3)

  • Buckets: 2,097,152 Batches: 1 Memory Usage: 210,496kB
11. 162.224 162.224 ↑ 1.3 428,577 3 / 3

Parallel Seq Scan on punto_suministro_temporal pst (cost=0.00..29,157.22 rows=535,722 width=122) (actual time=0.046..162.224 rows=428,577 loops=3)

Planning time : 0.818 ms
Execution time : 83,284.679 ms