explain.depesz.com

PostgreSQL's explain analyze made readable

Result: WsGD

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 137,592.192 ↓ 0.0 0 1

Limit (cost=2,009,951.76..2,009,951.76 rows=2 width=28) (actual time=137,592.192..137,592.192 rows=0 loops=1)

2. 0.020 137,592.191 ↓ 0.0 0 1

Sort (cost=2,009,951.76..2,009,951.76 rows=2 width=28) (actual time=137,592.191..137,592.191 rows=0 loops=1)

  • Sort Key: (max((max(t1._period)))) DESC, t1._fld32821rref
  • Sort Method: quicksort Memory: 25kB
3. 0.002 137,592.171 ↓ 0.0 0 1

GroupAggregate (cost=2,009,382.61..2,009,951.68 rows=2 width=28) (actual time=137,592.171..137,592.171 rows=0 loops=1)

  • Group Key: t1._fld32821rref
4. 0.001 137,592.169 ↓ 0.0 0 1

Merge Append (cost=2,009,382.61..2,009,951.65 rows=2 width=28) (actual time=137,592.169..137,592.169 rows=0 loops=1)

  • Sort Key: t1._fld32821rref
5. 0.001 137,521.919 ↓ 0.0 0 1

Limit (cost=1,880,567.77..1,880,567.79 rows=1 width=28) (actual time=137,521.919..137,521.919 rows=0 loops=1)

6. 0.001 137,521.918 ↓ 0.0 0 1

GroupAggregate (cost=1,880,567.77..1,880,567.79 rows=1 width=28) (actual time=137,521.918..137,521.918 rows=0 loops=1)

  • Group Key: t1._fld32821rref
7. 0.000 137,521.917 ↓ 0.0 0 1

Sort (cost=1,880,567.77..1,880,567.78 rows=1 width=28) (actual time=137,521.917..137,521.917 rows=0 loops=1)

  • Sort Key: t1._fld32821rref
  • Sort Method: quicksort Memory: 25kB
8. 326.009 137,528.415 ↓ 0.0 0 1

Gather (cost=8,823.34..1,880,567.71 rows=1 width=28) (actual time=137,521.906..137,528.415 rows=0 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
9. 734.457 137,202.406 ↓ 0.0 0 3 / 3

Parallel Hash Anti Join (cost=7,823.34..1,879,567.61 rows=1 width=28) (actual time=137,202.406..137,202.406 rows=0 loops=3)

  • Hash Cond: (t1._fld32821rref = t2._fld74574_rrref)
10. 131,304.100 131,304.100 ↑ 1.2 4,668,136 3 / 3

Parallel Seq Scan on _accumrg32819 t1 (cost=0.00..1,733,199.55 rows=5,833,462 width=28) (actual time=67,013.196..131,304.100 rows=4,668,136 loops=3)

  • Filter: ((_period >= '2015-01-01 00:00:00'::timestamp without time zone) AND (_period < '2015-12-31 17:05:45'::timestamp without time zone) AND (_fld1389 = '0'::numeric))
  • Rows Removed by Filter: 3609832
11. 0.111 5,163.849 ↑ 2.6 8 3 / 3

Parallel Hash (cost=7,823.08..7,823.08 rows=21 width=17) (actual time=5,163.848..5,163.849 rows=8 loops=3)

  • Buckets: 1024 Batches: 1 Memory Usage: 104kB
12. 5,163.738 5,163.738 ↑ 2.6 8 3 / 3

Parallel Seq Scan on _inforg74571 t2 (cost=0.00..7,823.08 rows=21 width=17) (actual time=2,498.689..5,163.738 rows=8 loops=3)

  • Filter: ((NOT _fld74573) AND (_fld74572_type = '\\x08'::bytea) AND (_fld74572_rtref = '\\x00000099'::bytea) AND (_fld74572_rrref = '\\x8cda000c29b4f2a211e3ba42c12a08eb'::bytea) AND (_fld74574_type = '\\x08'::bytea) AND (_fld74574_rtref = '\\x000000d7'::bytea) AND (_fld74575_type = '\\x08'::bytea) AND (_fld74575_rtref = '\\x000082ed'::bytea) AND (_fld74575_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74576_type = '\\x08'::bytea) AND (_fld74576_rtref = '\\x000082ed'::bytea) AND (_fld74576_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74577_type = '\\x08'::bytea) AND (_fld74577_rtref = '\\x000082ed'::bytea) AND (_fld74577_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74578_type = '\\x08'::bytea) AND (_fld74578_rtref = '\\x000082ed'::bytea) AND (_fld74578_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld1389 = '0'::numeric))
  • Rows Removed by Filter: 53884
13. 0.002 70.249 ↓ 0.0 0 1

Limit (cost=128,814.83..129,383.79 rows=1 width=28) (actual time=70.249..70.249 rows=0 loops=1)

14. 0.000 70.247 ↓ 0.0 0 1

GroupAggregate (cost=128,814.83..129,383.79 rows=1 width=28) (actual time=70.247..70.247 rows=0 loops=1)

  • Group Key: t1_1._fld32821rref
15. 46.894 70.264 ↓ 0.0 0 1

Gather Merge (cost=128,814.83..129,383.78 rows=1 width=28) (actual time=70.244..70.264 rows=0 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
16. 0.001 23.370 ↓ 0.0 0 3 / 3

Merge Anti Join (cost=127,814.81..128,383.64 rows=1 width=28) (actual time=23.370..23.370 rows=0 loops=3)

  • Merge Cond: (t1_1._fld32821rref = t2_1._fld74574_rrref)
17. 0.051 12.971 ↓ 0.0 0 3 / 3

Sort (cost=128,259.59..128,332.52 rows=29,170 width=28) (actual time=12.970..12.971 rows=0 loops=3)

  • Sort Key: t1_1._fld32821rref
  • Sort Method: quicksort Memory: 25kB
  • Worker 0: Sort Method: quicksort Memory: 25kB
  • Worker 1: Sort Method: quicksort Memory: 25kB
18. 12.920 12.920 ↓ 0.0 0 3 / 3

Parallel Index Scan using _accumrg32819_1 on _accumrg32819 t1_1 (cost=0.56..126,096.32 rows=29,170 width=28) (actual time=12.920..12.920 rows=0 loops=3)

  • Index Cond: ((_fld1389 = '0'::numeric) AND (_period >= '2015-01-01 00:00:00'::timestamp without time zone) AND (_period = '2015-12-31 17:05:45'::timestamp without time zone))
19. 0.006 10.398 ↑ 10.0 5 1 / 3

Sort (cost=294.35..294.47 rows=50 width=17) (actual time=31.194..31.194 rows=5 loops=1)

  • Sort Key: t2_1._fld74574_rrref
  • Sort Method: quicksort Memory: 26kB
20. 10.392 10.392 ↑ 2.0 25 1 / 3

Index Scan using _inforg74571_1 on _inforg74571 t2_1 (cost=0.55..292.94 rows=50 width=17) (actual time=31.145..31.177 rows=25 loops=1)

  • Index Cond: ((_fld1389 = '0'::numeric) AND (_fld74572_type = '\\x08'::bytea) AND (_fld74572_rtref = '\\x00000099'::bytea) AND (_fld74572_rrref = '\\x8cda000c29b4f2a211e3ba42c12a08eb'::bytea) AND (_fld74573 = false) AND (_fld74574_type = '\\x08'::bytea) AND (_fld74574_rtref = '\\x000000d7'::bytea) AND (_fld74575_type = '\\x08'::bytea) AND (_fld74575_rtref = '\\x000082ed'::bytea) AND (_fld74575_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74576_type = '\\x08'::bytea) AND (_fld74576_rtref = '\\x000082ed'::bytea) AND (_fld74576_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74577_type = '\\x08'::bytea) AND (_fld74577_rtref = '\\x000082ed'::bytea))
  • Filter: ((NOT _fld74573) AND (_fld74577_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea) AND (_fld74578_type = '\\x08'::bytea) AND (_fld74578_rtref = '\\x000082ed'::bytea) AND (_fld74578_rrref = '\\x9998bc573f4038d745ebec0464ef1b5c'::bytea))
Planning time : 534.024 ms
Execution time : 137,615.210 ms