explain.depesz.com

PostgreSQL's explain analyze made readable

Result: O7RNf

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Unique (cost=1,057,153.02..1,057,155.75 rows=99 width=86) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=1,057,153.02..1,057,153.27 rows=99 width=86) (actual rows= loops=)

  • Sort Key: h_2.ijrtteffeh, h_1.statut, e.matri, e.nompre, e.datcalc, h_2.sjrtteplah, (sum(h_3.sjqjourrep)), hopctra.scibashor, hopctra.scimodul, hopctra.scinbjtheo
3. 0.000 0.000 ↓ 0.0

Gather (cost=1,020,548.83..1,057,149.74 rows=99 width=86) (actual rows= loops=)

  • Workers Planned: 2
4. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1,019,548.83..1,056,139.84 rows=41 width=86) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=1,019,548.42..1,055,883.59 rows=41 width=49) (actual rows= loops=)

  • Merge Cond: ((e.matri)::text = (h_3.matri)::text)
6. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1,017,772.38..1,050,001.16 rows=41 width=41) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1,017,771.81..1,049,758.15 rows=41 width=35) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Merge Join (cost=14,704.51..14,841.60 rows=41 width=33) (actual rows= loops=)

  • Merge Cond: ((e.matri)::text = (h.matri)::text)
9. 0.000 0.000 ↓ 0.0

Sort (cost=12,975.20..13,044.32 rows=27,648 width=33) (actual rows= loops=)

  • Sort Key: e.matri
10. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on hopempl e (cost=0.00..10,935.48 rows=27,648 width=33) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Sort (cost=1,728.63..1,728.87 rows=99 width=8) (actual rows= loops=)

  • Sort Key: h.matri
12. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.99..1,725.34 rows=99 width=8) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Index Only Scan using i_hoprols on hoprols (cost=0.42..16.48 rows=3 width=14) (actual rows= loops=)

  • Index Cond: ((matri = '04745013'::text) AND (role = '9001'::text))
14. 0.000 0.000 ↓ 0.0

Index Only Scan using i_hophjoun5 on hophjoun h (cost=0.57..568.20 rows=142 width=21) (actual rows= loops=)

  • Index Cond: ((sectori = (hoprols.horsect)::text) AND (dat >= '2019-04-01'::date) AND (dat <= '2019-04-07'::date))
15. 0.000 0.000 ↓ 0.0

Hash Join (cost=1,003,067.29..1,003,844.08 rows=2 width=10) (actual rows= loops=)

  • Hash Cond: (((hophjoun.matri)::text = (h_1.matri)::text) AND ((min(hophjoun.dat)) = h_1.dat))
16. 0.000 0.000 ↓ 0.0

HashAggregate (cost=994,822.78..995,130.42 rows=30,764 width=12) (actual rows= loops=)

  • Group Key: hophjoun.matri
17. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on hophjoun (cost=11,696.71..992,561.24 rows=452,307 width=12) (actual rows= loops=)

  • Recheck Cond: ((dat >= '2019-04-01'::date) AND (dat <= '2019-04-07'::date))
18. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on i_hophjoun2 (cost=0.00..11,583.64 rows=452,307 width=0) (actual rows= loops=)

  • Index Cond: ((dat >= '2019-04-01'::date) AND (dat <= '2019-04-07'::date))
19. 0.000 0.000 ↓ 0.0

Hash (cost=8,201.75..8,201.75 rows=2,851 width=14) (actual rows= loops=)

20. 0.000 0.000 ↓ 0.0

Index Scan using i_hophjoun on hophjoun h_1 (cost=0.57..8,201.75 rows=2,851 width=14) (actual rows= loops=)

  • Index Cond: ((e.matri)::text = (matri)::text)
21. 0.000 0.000 ↓ 0.0

Index Scan using i_hophjoup on hophjoup h_2 (cost=0.57..11.29 rows=2 width=14) (actual rows= loops=)

  • Index Cond: (((e.matri)::text = (matri)::text) AND (dat = '2019-04-07'::date))
22. 0.000 0.000 ↓ 0.0

GroupAggregate (cost=1,776.04..5,869.15 rows=1,053 width=16) (actual rows= loops=)

  • Group Key: h_3.matri
23. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1,776.04..5,853.35 rows=1,053 width=10) (actual rows= loops=)

24. 0.000 0.000 ↓ 0.0

Unique (cost=1,775.47..1,775.97 rows=99 width=8) (actual rows= loops=)

25. 0.000 0.000 ↓ 0.0

Sort (cost=1,775.47..1,775.72 rows=99 width=8) (actual rows= loops=)

  • Sort Key: e_1.matri
26. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.41..1,772.19 rows=99 width=8) (actual rows= loops=)

27. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.99..1,725.34 rows=99 width=8) (actual rows= loops=)

28. 0.000 0.000 ↓ 0.0

Index Only Scan using i_hoprols on hoprols hoprols_1 (cost=0.42..16.48 rows=3 width=14) (actual rows= loops=)

  • Index Cond: ((matri = '04745013'::text) AND (role = '9001'::text))
29. 0.000 0.000 ↓ 0.0

Index Only Scan using i_hophjoun5 on hophjoun h_4 (cost=0.57..568.20 rows=142 width=21) (actual rows= loops=)

  • Index Cond: ((sectori = (hoprols_1.horsect)::text) AND (dat >= '2019-04-01'::date) AND (dat <= '2019-04-07'::date))
30. 0.000 0.000 ↓ 0.0

Index Only Scan using i_hopempl4 on hopempl e_1 (cost=0.42..0.47 rows=1 width=8) (actual rows= loops=)

  • Index Cond: (matri = (h_4.matri)::text)
31. 0.000 0.000 ↓ 0.0

Index Scan using i_hophjoup on hophjoup h_3 (cost=0.57..41.07 rows=11 width=10) (actual rows= loops=)

  • Index Cond: (((matri)::text = (e_1.matri)::text) AND (dat >= '2019-04-01'::date) AND (dat <= '2019-04-07'::date))
32. 0.000 0.000 ↓ 0.0

Index Scan using i_hopctra on hopctra (cost=0.42..6.24 rows=1 width=16) (actual rows= loops=)

  • Index Cond: (((e.matri)::text = (matri)::text) AND (datfin >= '2019-04-07'::date))
  • Filter: (datdeb <= '2019-04-07'::date)