explain.depesz.com

PostgreSQL's explain analyze made readable

Result: DlQC

Settings
# exclusive inclusive rows x rows loops node
1. 8,201.467 150,448.731 ↑ 25.7 3,142,210 1

Gather (cost=9,690,061.20..18,043,491.39 rows=80,607,200 width=132) (actual time=141,569.600..150,448.731 rows=3,142,210 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
2. 977.583 142,247.264 ↑ 32.1 628,442 5 / 5

Parallel Hash Left Join (cost=9,689,061.20..9,981,771.39 rows=20,151,800 width=132) (actual time=141,537.222..142,247.264 rows=628,442 loops=5)

  • Hash Cond: ((pt.id_processo_trf)::integer = pi.id_processo)
3. 407.630 3,279.970 ↑ 1.3 628,442 5 / 5

Parallel Hash Left Join (cost=93,373.69..195,753.67 rows=785,625 width=80) (actual time=1,526.794..3,279.970 rows=628,442 loops=5)

  • Hash Cond: ((pt.id_processo_trf)::integer = (pc.id_processo_trf)::integer)
4. 505.348 1,901.442 ↑ 1.3 628,442 5 / 5

Parallel Hash Left Join (cost=70,627.88..170,945.60 rows=785,625 width=52) (actual time=538.606..1,901.442 rows=628,442 loops=5)

  • Hash Cond: ((pt.id_processo_trf)::integer = (p.id_processo)::integer)
5. 214.244 1,056.396 ↑ 1.3 628,442 5 / 5

Parallel Hash Left Join (cost=14,620.16..112,875.61 rows=785,625 width=44) (actual time=196.319..1,056.396 rows=628,442 loops=5)

  • Hash Cond: ((pt.id_processo_trf)::integer = (pr.id_processo_trf)::integer)
6. 572.397 702.014 ↑ 1.3 628,442 5 / 5

Parallel Hash Left Join (cost=7,967.26..96,328.73 rows=785,625 width=40) (actual time=56.060..702.014 rows=628,442 loops=5)

  • Hash Cond: ((pt.id_processo_trf)::integer = hdo.id_processo_trf)
7. 73.688 73.688 ↑ 1.3 628,442 5 / 5

Parallel Seq Scan on tb_processo_trf pt (cost=0.00..75,500.25 rows=785,625 width=36) (actual time=0.019..73.688 rows=628,442 loops=5)

8. 11.925 55.929 ↑ 1.5 25,771 5 / 5

Parallel Hash (cost=7,493.15..7,493.15 rows=37,929 width=8) (actual time=55.927..55.929 rows=25,771 loops=5)

  • Buckets: 131072 (originally 65536) Batches: 1 (originally 1) Memory Usage: 6656kB
9. 21.000 44.004 ↑ 1.5 25,771 5 / 5

Parallel Hash Anti Join (cost=3,424.17..7,493.15 rows=37,929 width=8) (actual time=20.175..44.004 rows=25,771 loops=5)

  • Hash Cond: (hdo.id_processo_trf = hdo2.id_processo_trf)
  • Join Filter: ((hdo2.dt_deslocamento < hdo.dt_deslocamento) OR ((hdo2.dt_deslocamento = hdo.dt_deslocamento) AND (hdo2.id_hist_desloca_oj < hdo.id_hist_desloca_oj)))
  • Rows Removed by Join Filter: 32838
10. 3.007 3.007 ↑ 2.9 29,029 5 / 5

Parallel Seq Scan on tb_hist_desloca_oj hdo (cost=0.00..2,357.41 rows=85,341 width=20) (actual time=0.008..3.007 rows=29,029 loops=5)

11. 11.157 19.997 ↑ 2.9 29,029 5 / 5

Parallel Hash (cost=2,357.41..2,357.41 rows=85,341 width=16) (actual time=19.996..19.997 rows=29,029 loops=5)

  • Buckets: 262144 Batches: 1 Memory Usage: 10080kB
12. 8.840 8.840 ↑ 2.9 29,029 5 / 5

Parallel Seq Scan on tb_hist_desloca_oj hdo2 (cost=0.00..2,357.41 rows=85,341 width=16) (actual time=0.066..8.840 rows=29,029 loops=5)

13. 12.267 140.138 ↑ 1.5 20,272 5 / 5

Parallel Hash (cost=6,284.55..6,284.55 rows=29,468 width=8) (actual time=140.138..140.138 rows=20,272 loops=5)

  • Buckets: 131072 (originally 65536) Batches: 1 (originally 1) Memory Usage: 5568kB
14. 22.993 127.871 ↑ 1.5 20,272 5 / 5

Parallel Hash Anti Join (cost=2,914.82..6,284.55 rows=29,468 width=8) (actual time=102.001..127.871 rows=20,272 loops=5)

  • Hash Cond: ((pr.id_processo_trf)::integer = (pr2.id_processo_trf)::integer)
  • Join Filter: (((pr2.dt_redistribuicao)::timestamp without time zone < (pr.dt_redistribuicao)::timestamp without time zone) OR (((pr2.dt_redistribuicao)::timestamp without time zone = (pr.dt_redistribuicao)::timestamp without time zone) AND ((pr2.id_processo_trf_redistribuicao)::integer < (pr.id_processo_trf_redistribuicao)::integer)))
  • Rows Removed by Join Filter: 25397
15. 3.100 3.100 ↑ 2.9 22,548 5 / 5

Parallel Seq Scan on tb_proc_trf_redistribuicao pr (cost=0.00..2,086.03 rows=66,303 width=20) (actual time=0.025..3.100 rows=22,548 loops=5)

16. 11.735 101.778 ↑ 2.9 22,548 5 / 5

Parallel Hash (cost=2,086.03..2,086.03 rows=66,303 width=16) (actual time=101.778..101.778 rows=22,548 loops=5)

  • Buckets: 131072 Batches: 1 Memory Usage: 7296kB
17. 90.043 90.043 ↑ 2.9 22,548 5 / 5

Parallel Seq Scan on tb_proc_trf_redistribuicao pr2 (cost=0.00..2,086.03 rows=66,303 width=16) (actual time=0.847..90.043 rows=22,548 loops=5)

18. 220.747 339.698 ↑ 1.2 628,487 5 / 5

Parallel Hash (cost=46,188.43..46,188.43 rows=785,543 width=12) (actual time=339.698..339.698 rows=628,487 loops=5)

  • Buckets: 4194304 Batches: 1 Memory Usage: 180288kB
19. 118.951 118.951 ↑ 1.2 628,487 5 / 5

Parallel Seq Scan on tb_processo p (cost=0.00..46,188.43 rows=785,543 width=12) (actual time=0.059..118.951 rows=628,487 loops=5)

20. 900.214 970.898 ↑ 1.6 128,238 5 / 5

Parallel Hash (cost=20,160.36..20,160.36 rows=206,836 width=32) (actual time=970.897..970.898 rows=128,238 loops=5)

  • Buckets: 1048576 Batches: 1 Memory Usage: 43328kB
21. 70.684 70.684 ↑ 1.6 128,238 5 / 5

Parallel Seq Scan on tb_processo_clet pc (cost=0.00..20,160.36 rows=206,836 width=32) (actual time=0.086..70.684 rows=128,238 loops=5)

22. 295.113 137,989.711 ↑ 34.7 581,257 5 / 5

Parallel Hash (cost=9,245,392.01..9,245,392.01 rows=20,151,800 width=12) (actual time=137,989.711..137,989.711 rows=581,257 loops=5)

  • Buckets: 8388608 Batches: 32 Memory Usage: 69856kB
23. 104,443.486 137,694.598 ↑ 34.7 581,257 5 / 5

Parallel Hash Anti Join (cost=4,956,998.29..9,245,392.01 rows=20,151,800 width=12) (actual time=99,593.965..137,694.598 rows=581,257 loops=5)

  • Hash Cond: (pi.id_processo = pi2.id_processo)
  • Join Filter: (ti2.create_ < ti.create_)
  • Rows Removed by Join Filter: 137153353
24. 22,226.519 33,251.112 ↑ 1.2 24,190,944 5 / 5

Parallel Hash Join (cost=464,266.46..3,967,288.58 rows=30,227,700 width=12) (actual time=18,034.313..33,251.112 rows=24,190,944 loops=5)

  • Hash Cond: (ti.procinst_ = pi.id_proc_inst)
25. 8,353.881 8,353.881 ↑ 1.2 24,192,266 5 / 5

Parallel Seq Scan on jbpm_taskinstance ti (cost=0.00..2,673,923.00 rows=30,227,700 width=16) (actual time=0.040..8,353.881 rows=24,192,266 loops=5)

26. 2,670.712 2,670.712 ↑ 1.3 6,988,149 5 / 5

Parallel Hash (cost=312,236.76..312,236.76 rows=8,745,976 width=12) (actual time=2,670.712..2,670.712 rows=6,988,149 loops=5)