explain.depesz.com

PostgreSQL's explain analyze made readable

Result: SEtz : danone

Settings
# exclusive inclusive rows x rows loops node
1. 4,839.634 148,914.548 ↓ 40.4 271,729 1

GroupAggregate (cost=1,113,277.00..1,113,697.57 rows=6,729 width=189) (actual time=138,150.745..148,914.548 rows=271,729 loops=1)

  • Group Key: fact_tab.cod_categoria, app_cat05101169124535470522.tipo_periodicizzazione, app_cat05101169124535470522.tipo_categoria, fact_tab.cod_scenario, fact_tab.cod_periodo, fact_tab.cod_conto, app_conto051011787544294671.natura_conto, app_conto051011787544294671.tipo_conto, app_conto051011787544294671.tipo_conversione, fact_tab.cod_dest1, app_k2051011938757740781043.k1, fact_tab.cod_dest3, fact_tab.cod_dest5, fact_tab.cod_azienda, fact_tab.cod_valuta, fact_tab.cod_valuta_originaria
  • Buffers: shared hit=4638031 dirtied=1, temp read=76376 written=76376
2. 57,781.582 144,074.914 ↓ 611.4 4,114,188 1

Sort (cost=1,113,277.00..1,113,293.83 rows=6,729 width=139) (actual time=138,150.652..144,074.914 rows=4,114,188 loops=1)

  • Sort Key: fact_tab.cod_categoria, app_cat05101169124535470522.tipo_periodicizzazione, app_cat05101169124535470522.tipo_categoria, fact_tab.cod_scenario, fact_tab.cod_periodo, fact_tab.cod_conto, app_conto051011787544294671.natura_conto, app_conto051011787544294671.tipo_conto, app_conto051011787544294671.tipo_conversione, fact_tab.cod_dest1, app_k2051011938757740781043.k1, fact_tab.cod_dest5, fact_tab.cod_valuta, fact_tab.cod_valuta_originaria
  • Sort Method: external merge Disk: 610944kB
  • Buffers: shared hit=4638031 dirtied=1, temp read=76376 written=76376
3. 3,354.523 86,293.332 ↓ 611.4 4,114,188 1

Hash Join (cost=104.26..1,112,849.17 rows=6,729 width=139) (actual time=25.174..86,293.332 rows=4,114,188 loops=1)

  • Hash Cond: ((fact_tab.cod_dest1)::text = (app_k1051011244224709856781.k1)::text)
  • Buffers: shared hit=4638031 dirtied=1
4. 3,357.243 82,937.982 ↓ 611.4 4,114,188 1

Hash Join (cost=70.59..1,112,722.97 rows=6,729 width=139) (actual time=24.339..82,937.982 rows=4,114,188 loops=1)

  • Hash Cond: ((fact_tab.cod_conto)::text = (app_conto051011787544294671.k1)::text)
  • Buffers: shared hit=4638023 dirtied=1
5. 24,137.213 79,580.037 ↓ 629.1 4,233,010 1

Nested Loop (cost=45.53..1,112,605.39 rows=6,729 width=133) (actual time=23.622..79,580.037 rows=4,233,010 loops=1)

  • Join Filter: ((fact_tab.cod_categoria)::text = (app_cat05101169124535470522.k1)::text)
  • Rows Removed by Join Filter: 33590472
  • Buffers: shared hit=4638017 dirtied=1
6. 11,685.657 36,531.083 ↓ 234.2 18,911,741 1

Hash Join (cost=45.53..1,110,181.51 rows=80,762 width=128) (actual time=1.197..36,531.083 rows=18,911,741 loops=1)

  • Hash Cond: ((fact_tab.cod_dest2)::text = (app_k2051011938757740781043.k2)::text)
  • Buffers: shared hit=4638016 dirtied=1
7. 7,576.545 24,845.285 ↓ 231.0 9,459,833 1

Hash Join (cost=39.39..1,109,163.01 rows=40,948 width=128) (actual time=1.050..24,845.285 rows=9,459,833 loops=1)

  • Hash Cond: ((fact_tab.cod_dest5)::text = (app_k1051011747413686096932.k1)::text)
  • Buffers: shared hit=4638014 dirtied=1
8. 6,440.080 17,267.754 ↓ 231.0 9,459,833 1

Nested Loop (cost=0.57..1,108,561.15 rows=40,948 width=128) (actual time=0.057..17,267.754 rows=9,459,833 loops=1)

  • Buffers: shared hit=4638006 dirtied=1
9. 0.026 0.026 ↑ 5.8 12 1

Seq Scan on app_sce_per0510117333747601 (cost=0.00..10.70 rows=70 width=1,032) (actual time=0.002..0.026 rows=12 loops=1)

  • Buffers: shared hit=1 dirtied=1
10. 10,827.648 10,827.648 ↓ 99.0 788,319 12

Index Scan using ix_dati_saldi_lordi_01 on dati_saldi_lordi fact_tab (cost=0.57..15,756.81 rows=7,962 width=128) (actual time=0.028..902.304 rows=788,319 loops=12)

  • Index Cond: (((cod_scenario)::text = (app_sce_per0510117333747601.cod_scenario)::text) AND ((cod_scenario)::text = ANY ('{2019_ACT,2018_ACT}'::text[])) AND ((cod_periodo)::text = (app_sce_per0510117333747601.cod_periodo)::text) AND ((cod_periodo)::text = ANY ('{03,04,02,05,01,06}'::text[])) AND ((cod_azienda)::text = 'ETI_4630'::text))
  • Filter: ((cod_dest3)::text = 'BUS_TYP_DOMESTIC'::text)
  • Rows Removed by Filter: 88817
  • Buffers: shared hit=4638005
11. 0.538 0.986 ↑ 1.0 1,370 1

Hash (cost=21.70..21.70 rows=1,370 width=10) (actual time=0.986..0.986 rows=1,370 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 74kB
  • Buffers: shared hit=8
12. 0.448 0.448 ↑ 1.0 1,370 1

Seq Scan on app_k1051011747413686096932 (cost=0.00..21.70 rows=1,370 width=10) (actual time=0.007..0.448 rows=1,370 loops=1)

  • Buffers: shared hit=8
13. 0.077 0.141 ↑ 1.0 184 1

Hash (cost=3.84..3.84 rows=184 width=42) (actual time=0.141..0.141 rows=184 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
  • Buffers: shared hit=2
14. 0.064 0.064 ↑ 1.0 184 1

Seq Scan on app_k2051011938757740781043 (cost=0.00..3.84 rows=184 width=42) (actual time=0.005..0.064 rows=184 loops=1)

  • Buffers: shared hit=2
15. 18,911.738 18,911.741 ↑ 1.0 2 18,911,741

Materialize (cost=0.00..1.03 rows=2 width=16) (actual time=0.000..0.001 rows=2 loops=18,911,741)

  • Buffers: shared hit=1
16. 0.003 0.003 ↑ 1.0 2 1

Seq Scan on app_cat05101169124535470522 (cost=0.00..1.02 rows=2 width=16) (actual time=0.002..0.003 rows=2 loops=1)

  • Buffers: shared hit=1
17. 0.369 0.702 ↑ 1.0 847 1

Hash (cost=14.47..14.47 rows=847 width=17) (actual time=0.702..0.702 rows=847 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 49kB
  • Buffers: shared hit=6
18. 0.333 0.333 ↑ 1.0 847 1

Seq Scan on app_conto051011787544294671 (cost=0.00..14.47 rows=847 width=17) (actual time=0.006..0.333 rows=847 loops=1)

  • Buffers: shared hit=6
19. 0.439 0.827 ↑ 1.0 1,141 1

Hash (cost=19.41..19.41 rows=1,141 width=16) (actual time=0.827..0.827 rows=1,141 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 70kB
  • Buffers: shared hit=8
20. 0.388 0.388 ↑ 1.0 1,141 1

Seq Scan on app_k1051011244224709856781 (cost=0.00..19.41 rows=1,141 width=16) (actual time=0.008..0.388 rows=1,141 loops=1)

  • Buffers: shared hit=8
Planning time : 3.054 ms