explain.depesz.com

PostgreSQL's explain analyze made readable

Result: AyOG

Settings
# exclusive inclusive rows x rows loops node
1. 0.377 5,796.398 ↑ 1.0 1 1

Aggregate (cost=48,506.44..48,506.45 rows=1 width=8) (actual time=5,796.396..5,796.398 rows=1 loops=1)

2. 0.242 5,796.021 ↓ 47.0 47 1

Nested Loop (cost=4,100.41..48,506.44 rows=1 width=12) (actual time=3,991.208..5,796.021 rows=47 loops=1)

3. 0.215 5,795.591 ↓ 47.0 47 1

Nested Loop (cost=4,100.27..48,506.28 rows=1 width=16) (actual time=3,991.186..5,795.591 rows=47 loops=1)

4. 0.256 5,795.141 ↓ 47.0 47 1

Nested Loop (cost=4,100.00..48,505.99 rows=1 width=20) (actual time=3,991.166..5,795.141 rows=47 loops=1)

5. 0.237 5,794.603 ↓ 47.0 47 1

Nested Loop (cost=4,099.72..48,505.70 rows=1 width=24) (actual time=3,991.136..5,794.603 rows=47 loops=1)

6. 0.253 5,794.084 ↓ 47.0 47 1

Nested Loop (cost=4,099.59..48,505.54 rows=1 width=28) (actual time=3,991.078..5,794.084 rows=47 loops=1)

7. 0.249 5,793.596 ↓ 47.0 47 1

Nested Loop (cost=4,099.45..48,505.38 rows=1 width=32) (actual time=3,991.051..5,793.596 rows=47 loops=1)

8. 0.414 5,792.313 ↓ 47.0 47 1

Nested Loop (cost=4,099.16..48,505.04 rows=1 width=36) (actual time=3,990.958..5,792.313 rows=47 loops=1)

9. 0.223 5,791.664 ↓ 47.0 47 1

Nested Loop (cost=4,098.89..48,504.74 rows=1 width=40) (actual time=3,990.934..5,791.664 rows=47 loops=1)

10. 0.289 5,791.018 ↓ 47.0 47 1

Nested Loop (cost=4,098.61..48,504.45 rows=1 width=44) (actual time=3,990.904..5,791.018 rows=47 loops=1)

11. 13.219 5,790.400 ↓ 47.0 47 1

Nested Loop (cost=4,098.33..48,504.11 rows=1 width=48) (actual time=3,990.873..5,790.400 rows=47 loops=1)

12. 54.169 5,422.561 ↓ 2,086.0 2,086 1

Nested Loop (cost=3,969.19..48,264.97 rows=1 width=52) (actual time=167.309..5,422.561 rows=2,086 loops=1)

  • Join Filter: (((matricula.gradecurricularatual = historico.matrizcurricular) AND ((historico.historicocursandoporcorrespondenciaapostransferencia IS NULL) OR (NOT historico.historicocursandoporcorrespondenciaapostransferencia)) AND ((historico.transferenciamatrizcurricularmatricula IS NULL) OR ((historico.transferenciamatrizcurricularmatricula IS NOT NULL) AND (NOT (SubPlan 4))))) OR ((matricula.gradecurricularatual <> historico.matrizcurricular) AND historico.historicocursandoporcorrespondenciaapostransferencia AND (historico.transferenciamatrizcurricularmatricula IS NOT NULL) AND (historico.disciplina = (SubPlan 5)) AND ((NOT historico.historicoporequivalencia) OR (historico.historicoporequivalencia IS NULL))) OR ((matricula.gradecurricularatual <> historico.matrizcurricular) AND historico.historicoequivalente AND (SubPlan 6)) OR ((historico.matrizcurricular = matriculaperiodo.gradecurricular) AND (matricula.gradecurricularatual <> historico.matrizcurricular) AND historico.historicodisciplinafazpartecomposicao AND (NOT (SubPlan 7))))
  • Rows Removed by Join Filter: 1936
13. 0.000 183.015 ↓ 318.7 4,462 1

Gather (cost=3,968.90..46,112.74 rows=14 width=73) (actual time=167.094..183.015 rows=4,462 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
14. 10.569 984.159 ↓ 247.8 1,487 3

Parallel Hash Join (cost=2,968.90..45,111.34 rows=6 width=73) (actual time=132.133..984.159 rows=1,487 loops=3)

  • Hash Cond: (((historico.matricula)::text = (matriculaperiodo.matricula)::text) AND (historico.matriculaperiodo = matriculaperiodo.codigo))
15. 842.982 843.514 ↑ 123.4 1,487 3

Parallel Seq Scan on historico (cost=15.82..41,194.82 rows=183,514 width=81) (actual time=0.884..843.514 rows=1,487 loops=3)

  • Filter: (((historicoporequivalencia IS NULL) OR (NOT historicoporequivalencia)) AND ((historicodisciplinacomposta IS NULL) OR (NOT historicodisciplinacomposta)) AND ((((historicocursandoporcorrespondenciaapostransferencia IS NULL) OR (NOT historicocursandoporcorrespondenciaapostransferencia)) AND ((transferenciamatrizcurricularmatricula IS NULL) OR (transferenciamatrizcurricularmatricula IS NOT NULL))) OR (historicocursandoporcorrespondenciaapostransferencia AND (transferenciamatrizcurricularmatricula IS NOT NULL) AND ((NOT historicoporequivalencia) OR (historicoporequivalencia IS NULL))) OR historicoequivalente OR historicodisciplinafazpartecomposicao) AND ((situacao)::text <> ALL ('{AA,CC,CH,IS}'::text[])) AND ((disciplina = 232) OR (hashed SubPlan 8) OR (hashed SubPlan 9) OR (hashed SubPlan 10)))
  • Rows Removed by Filter: 265394
16.          

SubPlan (for Parallel Seq Scan)

17. 0.006 0.406 ↑ 1.0 1 3

Unique (cost=13.10..13.11 rows=1 width=4) (actual time=0.401..0.406 rows=1 loops=3)

18. 0.119 0.400 ↑ 1.0 1 3

Sort (cost=13.10..13.11 rows=1 width=4) (actual time=0.397..0.400 rows=1 loops=3)

  • Sort Key: turmadisciplina.disciplinaequivalenteturmaagrupada
  • Sort Method: quicksort Memory: 25kB
  • Worker 0: Sort Method: quicksort Memory: 25kB
  • Worker 1: Sort Method: quicksort Memory: 25kB
19. 0.059 0.281 ↑ 1.0 1 3

Bitmap Heap Scan on turmadisciplina (cost=9.08..13.09 rows=1 width=4) (actual time=0.278..0.281 rows=1 loops=3)

  • Recheck Cond: ((turma = 6497) AND (disciplina = 232))
  • Heap Blocks: exact=1
20. 0.006 0.222 ↓ 0.0 0 3

BitmapAnd (cost=9.08..9.08 rows=1 width=0) (actual time=0.221..0.222 rows=0 loops=3)

21. 0.100 0.100 ↑ 12.0 1 3

Bitmap Index Scan on ch_turmadisciplina_turma (cost=0.00..4.38 rows=12 width=0) (actual time=0.099..0.100 rows=1 loops=3)

  • Index Cond: (turma = 6497)
22. 0.116 0.116 ↓ 3.0 64 3

Bitmap Index Scan on ch_turmadisciplina_disciplina (cost=0.00..4.45 rows=21 width=0) (actual time=0.115..0.116 rows=64 loops=3)

  • Index Cond: (disciplina = 232)
23. 0.111 0.111 ↓ 0.0 0 3

Seq Scan on disciplinaequivalente (cost=0.00..1.35 rows=1 width=4) (actual time=0.110..0.111 rows=0 loops=3)

  • Filter: (equivalente = 232)
  • Rows Removed by Filter: 28
24. 0.015 0.015 ↓ 0.0 0 3

Seq Scan on disciplinaequivalente disciplinaequivalente_1 (cost=0.00..1.35 rows=1 width=4) (actual time=0.014..0.015 rows=0 loops=3)

  • Filter: (disciplina = 232)
  • Rows Removed by Filter: 28
25. 58.193 130.076 ↑ 1.8 27,822 3

Parallel Hash (cost=2,218.98..2,218.98 rows=48,940 width=20) (actual time=130.075..130.076 rows=27,822 loops=3)

  • Buckets: 131072 Batches: 1 Memory Usage: 5696kB
26. 71.883 71.883 ↑ 1.8 27,822 3

Parallel Seq Scan on matriculaperiodo (cost=0.00..2,218.98 rows=48,940 width=20) (actual time=0.113..71.883 rows=27,822 loops=3)

  • Filter: ((situacaomatriculaperiodo)::text <> 'PC'::text)
  • Rows Removed by Filter: 12
27. 178.480 178.480 ↑ 1.0 1 4,462

Index Scan using matricula_pkey on matricula (cost=0.29..0.32 rows=1 width=32) (actual time=0.039..0.040 rows=1 loops=4,462)

  • Index Cond: ((matricula)::text = (historico.matricula)::text)
  • Filter: (((situacao)::text <> 'CA'::text) AND ((situacao)::text <> 'TR'::text))
  • Rows Removed by Filter: 0
28.          

SubPlan (for Nested Loop)

29. 10.472 2,383.689 ↑ 1.0 1 1,309

Limit (cost=28.81..32.84 rows=1 width=4) (actual time=1.821..1.821 rows=1 loops=1,309)

30. 62.832 2,373.217 ↑ 1.0 1 1,309

Bitmap Heap Scan on historico his (cost=28.81..32.84 rows=1 width=4) (actual time=1.813..1.813 rows=1 loops=1,309)

  • Recheck Cond: (((matricula)::text = (historico.matricula)::text) AND (disciplina = historico.disciplina))
  • Filter: (historicocursandoporcorrespondenciaapostransferencia AND (matrizcurricular <> matricula.gradecurricularatual) AND ((anohistorico)::text = (historico.anohistorico)::text) AND ((semestrehistorico)::text = (historico.semestrehistorico)::text) AND (transferenciamatrizcurricularmatricula = historico.transferenciamatrizcurricularmatricula))
  • Rows Removed by Filter: 1
  • Heap Blocks: exact=2403
31. 23.562 2,310.385 ↓ 0.0 0 1,309

BitmapAnd (cost=28.81..28.81 rows=1 width=0) (actual time=1.765..1.765 rows=0 loops=1,309)

32. 572.033 572.033 ↓ 2.8 94 1,309

Bitmap Index Scan on idx_historico_matricula_gradedisciplina (cost=0.00..4.67 rows=33 width=0) (actual time=0.437..0.437 rows=94 loops=1,309)

  • Index Cond: ((matricula)::text = (historico.matricula)::text)
33. 1,714.790 1,714.790 ↓ 6.2 6,155 1,309

Bitmap Index Scan on ch_historico_disciplina (cost=0.00..23.89 rows=995 width=0) (actual time=1.310..1.310 rows=6,155 loops=1,309)

  • Index Cond: (disciplina = historico.disciplina)
34. 21.568 2,623.208 ↑ 1.0 1 1,348

Limit (cost=28.81..32.84 rows=1 width=4) (actual time=1.937..1.946 rows=1 loops=1,348)

35. 62.008 2,601.640 ↑ 1.0 1 1,348

Bitmap Heap Scan on historico his_1 (cost=28.81..32.84 rows=1 width=4) (actual time=1.929..1.930 rows=1 loops=1,348)

  • Recheck Cond: (((matricula)::text = (historico.matricula)::text) AND (disciplina = historico.disciplina))
  • Filter: (((historicocursandoporcorrespondenciaapostransferencia IS NULL) OR (NOT historicocursandoporcorrespondenciaapostransferencia)) AND ((anohistorico)::text = (historico.anohistorico)::text) AND ((semestrehistorico)::text = (historico.semestrehistorico)::text) AND (transferenciamatrizcurricularmatricula = historico.transferenciamatrizcurricularmatricula) AND (matrizcurricular = matricula.gradecurricularatual))
  • Rows Removed by Filter: 1
  • Heap Blocks: exact=2496
36. 21.568 2,539.632 ↓ 0.0 0 1,348

BitmapAnd (cost=28.81..28.81 rows=1 width=0) (actual time=1.883..1.884 rows=0 loops=1,348)

37. 667.260 667.260 ↓ 2.9 96 1,348

Bitmap Index Scan on idx_historico_matricula_gradedisciplina (cost=0.00..4.67 rows=33 width=0) (actual time=0.494..0.495 rows=96 loops=1,348)

  • Index Cond: ((matricula)::text = (historico.matricula)::text)
38. 1,850.804 1,850.804 ↓ 6.2 6,155 1,348

Bitmap Index Scan on ch_historico_disciplina (cost=0.00..23.89 rows=995 width=0) (actual time=1.372..1.373 rows=6,155 loops=1,348)

  • Index Cond: (disciplina = historico.disciplina)
39. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=81.23..85.28 rows=1 width=0) (never executed)

40. 0.000 0.000 ↓ 0.0 0

HashAggregate (cost=52.42..52.43 rows=1 width=25) (never executed)

  • Group Key: (his_2.matricula)::text, (his_2.anohistorico)::text, (his_2.semestrehistorico)::text, his_2.disciplina, his_2.transferenciamatrizcurricularmatricula
41. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on historico his_2 (cost=48.39..52.41 rows=1 width=25) (never executed)

  • Recheck Cond: (((matricula)::text = (historico.matricula)::text) AND (matrizcurricular = matricula.gradecurricularatual))
  • Filter: ((historicocursandoporcorrespondenciaapostransferencia IS NULL) OR (NOT historicocursandoporcorrespondenciaapostransferencia))
42. 0.000 0.000 ↓ 0.0 0

BitmapAnd (cost=48.39..48.39 rows=1 width=0) (never executed)

43. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_historico_matricula_gradedisciplina (cost=0.00..4.67 rows=33 width=0) (never executed)

  • Index Cond: ((matricula)::text = (historico.matricula)::text)
44. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on ch_historico_gc (cost=0.00..43.47 rows=2,006 width=0) (never executed)

  • Index Cond: (matrizcurricular = matricula.gradecurricularatual)
45. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on historico hist (cost=28.81..32.84 rows=1 width=25) (never executed)

  • Recheck Cond: (((matricula)::text = (historico.matricula)::text) AND (disciplina = his_2.disciplina))
  • Filter: (historicoporequivalencia AND (historico.mapaequivalenciadisciplina = mapaequivalenciadisciplina) AND (numeroagrupamentoequivalenciadisciplina = historico.numeroagrupamentoequivalenciadisciplina) AND ((his_2.anohistorico)::text = (anohistorico)::text) AND ((his_2.semestrehistorico)::text = (semestrehistorico)::text) AND (his_2.transferenciamatrizcurricularmatricula = transferenciamatrizcurricularmatricula))
46. 0.000 0.000 ↓ 0.0 0

BitmapAnd (cost=28.81..28.81 rows=1 width=0) (never executed)

47. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_historico_matricula_gradedisciplina (cost=0.00..4.67 rows=33 width=0) (never executed)

  • Index Cond: ((matricula)::text = (historico.matricula)::text)
48. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on ch_historico_disciplina (cost=0.00..23.89 rows=995 width=0) (never executed)

  • Index Cond: (disciplina = his_2.disciplina)
49. 0.000 0.000 ↓ 0.0 0

Index Only Scan using unq_historico_disciplina_matrper_matrperturm_grade_gd_gcgod on historico his_3 (cost=0.42..8.45 rows=1 width=4) (never executed)

  • Index Cond: ((disciplina = historico.disciplina) AND (matriculaperiodo = historico.matriculaperiodo) AND (matrizcurricular = matricula.gradecurricularatual))
  • Heap Fetches: 0
50. 350.653 354.620 ↓ 0.0 0 2,086

Index Scan using matriculaperiodoturmadisciplina_pkey on matriculaperiodoturmadisciplina (cost=129.14..239.14 rows=1 width=8) (actual time=0.170..0.170 rows=0 loops=2,086)

  • Index Cond: (codigo = historico.matriculaperiodoturmadisciplina)
  • Filter: (((semestre)::text = '2'::text) AND ((ano)::text = '2019'::text) AND ((hashed SubPlan 1) OR (hashed SubPlan 2) OR (hashed SubPlan 3)) AND ((alternatives: SubPlan 11 or hashed SubPlan 12) OR (SubPlan 13) OR (SubPlan 15)))
  • Rows Removed by Filter: 1
51.          

SubPlan (for Index Scan)

52. 0.047 0.047 ↑ 1.5 2 1

Index Scan using idx_turmaagrupada_turmaorigem on turmaagrupada (cost=0.28..16.30 rows=3 width=4) (actual time=0.041..0.047 rows=2 loops=1)

  • Index Cond: (turmaorigem = 6497)
53. 0.003 0.067 ↓ 0.0 0 1

Nested Loop (cost=0.84..54.87 rows=1 width=4) (actual time=0.066..0.067 rows=0 loops=1)

54. 0.011 0.064 ↓ 0.0 0 1

Nested Loop (cost=0.56..46.56 rows=1 width=8) (actual time=0.063..0.064 rows=0 loops=1)

55. 0.021 0.021 ↑ 1.5 2 1

Index Scan using idx_turmaagrupada_turmaorigem on turmaagrupada turmaagrupada_1 (cost=0.28..16.30 rows=3 width=8) (actual time=0.016..0.021 rows=2 loops=1)

  • Index Cond: (turmaorigem = 6497)
56. 0.032 0.032 ↓ 0.0 0 2

Index Scan using turma_pkey on turma turma_1 (cost=0.28..8.30 rows=1 width=4) (actual time=0.016..0.016 rows=0 loops=2)

  • Index Cond: (codigo = turmaagrupada_1.turma)
  • Filter: ((tiposubturma)::text = 'PRATICA'::text)
  • Rows Removed by Filter: 1
57. 0.000 0.000 ↓ 0.0 0

Index Scan using turma_pkey on turma turmaorigem (cost=0.28..8.30 rows=1 width=4) (never executed)

  • Index Cond: (codigo = 6497)
  • Filter: (NOT subturma)
58. 0.003 0.046 ↓ 0.0 0 1

Nested Loop (cost=0.84..57.54 rows=1 width=4) (actual time=0.045..0.046 rows=0 loops=1)

59. 0.010 0.043 ↓ 0.0 0 1

Nested Loop (cost=0.56..49.23 rows=1 width=8) (actual time=0.042..0.043 rows=0 loops=1)

60. 0.013 0.013 ↑ 1.5 2 1

Index Scan using idx_turmaagrupada_turmaorigem on turmaagrupada turmaagrupada_2 (cost=0.28..16.30 rows=3 width=8) (actual time=0.008..0.013 rows=2 loops=1)

  • Index Cond: (turmaorigem = 6497)
61. 0.020 0.020 ↓ 0.0 0 2

Index Scan using turma_pkey on turma turma_2 (cost=0.28..8.30 rows=1 width=4) (actual time=0.009..0.010 rows=0 loops=2)

  • Index Cond: (codigo = turmaagrupada_2.turma)
  • Filter: ((tiposubturma)::text = 'TEORICA'::text)
  • Rows Removed by Filter: 1
62. 0.000 0.000 ↓ 0.0 0

Index Scan using turma_pkey on turma turmaorigem_1 (cost=0.28..8.30 rows=1 width=4) (never executed)

  • Index Cond: (codigo = 6497)
  • Filter: (NOT subturma)
63. 0.141 2.021 ↓ 0.0 0 47

Nested Loop (cost=0.85..12.89 rows=1 width=0) (actual time=0.043..0.043 rows=0 loops=47)

64. 1.880 1.880 ↓ 0.0 0 47

Index Scan using historico_pkey on historico his_4 (cost=0.42..8.44 rows=1 width=4) (actual time=0.040..0.040 rows=0 loops=47)

  • Index Cond: (codigo = historico.codigo)
  • Filter: historicodisciplinafazpartecomposicao
  • Rows Removed by Filter: 1
65. 0.000 0.000 ↓ 0.0 0

Index Only Scan using matriculaperiodoturmadisciplina_pkey on matriculaperiodoturmadisciplina mptd (cost=0.42..4.44 rows=1 width=4) (never executed)

  • Index Cond: (codigo = his_4.matriculaperiodoturmadisciplina)
  • Heap Fetches: 0
66. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=1,000.42..37,181.34 rows=1 width=4) (never executed)

67. 0.000 0.000 ↓ 0.0 0

Gather (cost=1,000.00..37,176.90 rows=1 width=8) (never executed)

  • Workers Planned: 2
  • Workers Launched: 0
68. 0.000 0.000 ↓ 0.0 0

Parallel Seq Scan on historico his_5 (cost=0.00..36,176.80 rows=1 width=8) (never executed)

  • Filter: historicodisciplinafazpartecomposicao
69. 0.000 0.000 ↓ 0.0 0

Index Only Scan using matriculaperiodoturmadisciplina_pkey on matriculaperiodoturmadisciplina mptd_1 (cost=0.42..4.44 rows=1 width=4) (never executed)

  • Index Cond: (codigo = his_5.matriculaperiodoturmadisciplina)
  • Heap Fetches: 0
70. 0.141 1.786 ↑ 1.0 1 47

Result (cost=1.14..17.49 rows=1 width=0) (actual time=0.038..0.038 rows=1 loops=47)

  • One-Time Filter: (historico.matriculaperiodoturmadisciplina = matriculaperiodoturmadisciplina.codigo)
71. 0.282 1.645 ↑ 1.0 1 47

Nested Loop (cost=1.14..17.49 rows=1 width=0) (actual time=0.034..0.035 rows=1 loops=47)

72. 0.329 0.893 ↑ 1.0 1 47

Nested Loop (cost=0.85..16.89 rows=1 width=8) (actual time=0.019..0.019 rows=1 loops=47)

73. 0.282 0.282 ↑ 1.0 1 47

Index Scan using historico_pkey on historico his_6 (cost=0.42..8.44 rows=1 width=4) (actual time=0.006..0.006 rows=1 loops=47)

  • Index Cond: (codigo = historico.codigo)
74. 0.282 0.282 ↑ 1.0 1 47

Index Scan using matriculaperiodoturmadisciplina_pkey on matriculaperiodoturmadisciplina mptd_2 (cost=0.42..8.44 rows=1 width=12) (actual time=0.005..0.006 rows=1 loops=47)

  • Index Cond: (codigo = his_6.matriculaperiodoturmadisciplina)
75. 0.470 0.470 ↑ 1.0 1 47

Index Scan using ch_turmadisciplina_turma on turmadisciplina turmadisciplina_1 (cost=0.29..0.59 rows=1 width=8) (actual time=0.010..0.010 rows=1 loops=47)

  • Index Cond: (turma = mptd_2.turma)
  • Filter: (((definicoestutoriaonline IS NULL) OR ((definicoestutoriaonline)::text <> 'DINAMICA'::text)) AND (mptd_2.disciplina = disciplina))
  • Rows Removed by Filter: 3
76. 0.000 0.000 ↓ 0.0 0

Result (cost=1.99..79.45 rows=1 width=0) (never executed)

  • One-Time Filter: (historico.matriculaperiodoturmadisciplina = matriculaperiodoturmadisciplina.codigo)
77. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=1.99..79.45 rows=1 width=0) (never executed)

78. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=1.70..75.13 rows=1 width=4) (never executed)

  • Join Filter: (((NOT t.turmaagrupada) AND (mptd_3.turma = t.codigo)) OR (t.turmaagrupada AND (SubPlan 14)))
79. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=1.42..22.34 rows=1 width=12) (never executed)

  • Join Filter: (mptd_3.disciplina = turmadisciplina_2.disciplina)
80. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=1.13..18.32 rows=1 width=20) (never executed)

81. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=0.85..16.90 rows=1 width=16) (never executed)

82. 0.000 0.000 ↓ 0.0 0

Index Scan using historico_pkey on historico his_7 (cost=0.42..8.44 rows=1 width=8) (never executed)

  • Index Cond: (codigo = historico.codigo)
83. 0.000 0.000 ↓ 0.0 0

Index Scan using matriculaperiodoturmadisciplina_pkey on matriculaperiodoturmadisciplina mptd_3 (cost=0.42..8.45 rows=1 width=16) (never executed)

  • Index Cond: (codigo = his_7.matriculaperiodoturmadisciplina)
  • Filter: ((professor = 111020) AND (his_7.disciplina = disciplina))
84. 0.000 0.000 ↓ 0.0 0

Index Only Scan using disciplina_pkey on disciplina d (cost=0.28..1.42 rows=1 width=4) (never executed)

  • Index Cond: (codigo = mptd_3.disciplina)
  • Heap Fetches: 0
85. 0.000 0.000 ↓ 0.0 0

Index Scan using ch_turmadisciplina_disciplina on turmadisciplina turmadisciplina_2 (cost=0.29..4.00 rows=2 width=8) (never executed)

  • Index Cond: (disciplina = d.codigo)
  • Filter: ((definicoestutoriaonline)::text = 'DINAMICA'::text)
86. 0.000 0.000 ↓ 0.0 0

Index Scan using turma_pkey on turma t (cost=0.28..0.54 rows=1 width=5) (never executed)

  • Index Cond: (codigo = turmadisciplina_2.turma)
87.          

SubPlan (for Nested Loop)

88. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=4.66..99.76 rows=13 width=4) (never executed)

89. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on turmaagrupada ta (cost=4.38..27.86 rows=13 width=4) (never executed)

  • Recheck Cond: (turmaorigem = t.codigo)
90. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_turmaagrupada_turmaorigem (cost=0.00..4.38 rows=13 width=0) (never executed)

  • Index Cond: (turmaorigem = t.codigo)
91. 0.000 0.000 ↓ 0.0 0

Index Only Scan using turma_pkey on turma tu (cost=0.28..5.53 rows=1 width=4) (never executed)

  • Index Cond: (codigo = ta.turma)
  • Heap Fetches: 0
92. 0.000 0.000 ↓ 0.0 0

Index Only Scan using pessoa_pkey on pessoa prof (cost=0.29..4.31 rows=1 width=4) (never executed)

  • Index Cond: (codigo = 111020)
  • Heap Fetches: 0
93. 0.329 0.329 ↑ 1.0 1 47

Index Only Scan using turma_pkey on turma (cost=0.28..0.34 rows=1 width=4) (actual time=0.007..0.007 rows=1 loops=47)

  • Index Cond: (codigo = matriculaperiodoturmadisciplina.turma)
  • Heap Fetches: 47
94. 0.423 0.423 ↑ 1.0 1 47

Index Only Scan using gradecurricular_pkey on gradecurricular (cost=0.28..0.29 rows=1 width=4) (actual time=0.009..0.009 rows=1 loops=47)

  • Index Cond: (codigo = historico.matrizcurricular)
  • Heap Fetches: 47
95. 0.235 0.235 ↑ 1.0 1 47

Index Only Scan using disciplina_pkey on disciplina (cost=0.28..0.30 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=47)

  • Index Cond: (codigo = historico.disciplina)
  • Heap Fetches: 0
96. 1.034 1.034 ↑ 1.0 1 47

Index Only Scan using pessoa_pkey on pessoa aluno (cost=0.29..0.34 rows=1 width=4) (actual time=0.022..0.022 rows=1 loops=47)

  • Index Cond: (codigo = matricula.aluno)
  • Heap Fetches: 25
97. 0.235 0.235 ↑ 1.0 1 47

Index Only Scan using turno_pkey on turno (cost=0.14..0.16 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=47)

  • Index Cond: (codigo = matricula.turno)
  • Heap Fetches: 47
98. 0.282 0.282 ↑ 1.0 1 47

Index Only Scan using unidadeensino_pkey on unidadeensino (cost=0.13..0.15 rows=1 width=4) (actual time=0.006..0.006 rows=1 loops=47)

  • Index Cond: (codigo = matricula.unidadeensino)
  • Heap Fetches: 47
99. 0.282 0.282 ↑ 1.0 1 47

Index Only Scan using curso_pkey on curso (cost=0.28..0.29 rows=1 width=4) (actual time=0.006..0.006 rows=1 loops=47)

  • Index Cond: (codigo = matricula.curso)
  • Heap Fetches: 47
100. 0.235 0.235 ↑ 1.0 1 47

Index Only Scan using gradecurricular_pkey on gradecurricular matrizcurricular (cost=0.28..0.29 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=47)

  • Index Cond: (codigo = matricula.gradecurricularatual)
  • Heap Fetches: 47
101. 0.188 0.188 ↑ 1.0 1 47

Index Only Scan using configuracaoacademico_pkey on configuracaoacademico (cost=0.14..0.15 rows=1 width=4) (actual time=0.004..0.004 rows=1 loops=47)

  • Index Cond: (codigo = historico.configuracaoacademico)
  • Heap Fetches: 47
Planning time : 49.965 ms
Execution time : 5,803.005 ms