explain.depesz.com

PostgreSQL's explain analyze made readable

Result: GaO9

Settings
# exclusive inclusive rows x rows loops node
1. 2.479 87.098 ↑ 23,470.0 1 1

HashAggregate (cost=45,427.93..45,662.63 rows=23,470 width=250) (actual time=87.072..87.098 rows=1 loops=1)

  • Group Key: arquivo.codigo, arquivo.nome, arquivo.descricao, arquivo.dataupload, arquivo.datadisponibilizacao, arquivo.dataindisponibilizacao, arquivo.manterdisponibilizacao, arquivo.origem, arquivo.situacao, arquivo.controlardownload, arquivo.responsavelupload, arquivo.disciplina, arquivo.turma, arquivo.extensao, arquivo.permitirarquivoresposta, arquivo.arquivoresposta, arquivo.pastabasearquivo, arquivo.professor, arquivo.niveleducacional, arquivo.arquivoexistehd, arquivo.cpfalunodocumentacao, arquivo.cpfrequerimento, arquivo.apresentarportalcoordenador, arquivo.apresentarportalprofessor, arquivo.apresentarportalaluno, arquivo.curso, arquivo.apresentardeterminadoperiodo, arquivo.indice, arquivo.agrupador, arquivo.indiceagrupador, arquivo.arquivoassinadodigitalmente, arquivo.pessoa, arquivo.descricaoarquivo, arquivo.servidorarquivoonline, arquivo.codorigem, arquivo.codigoant, arquivo.codigomaterial
2. 0.326 84.619 ↑ 23.7 989 1

Hash Join (cost=37,738.48..43,256.95 rows=23,470 width=250) (actual time=54.005..84.619 rows=989 loops=1)

  • Hash Cond: (matricula.curso = curso.codigo)
3. 1.298 84.122 ↑ 23.7 989 1

Hash Join (cost=37,713.72..42,909.49 rows=23,470 width=254) (actual time=53.828..84.122 rows=989 loops=1)

  • Hash Cond: ((matriculaperiodo.matricula)::text = (matricula.matricula)::text)
4. 19.769 32.453 ↑ 23.7 989 1

Hash Join (cost=32,443.29..37,110.98 rows=23,470 width=263) (actual time=3.407..32.453 rows=989 loops=1)

  • Hash Cond: (matriculaperiodo.codigo = mptd.matriculaperiodo)
5. 10.368 10.368 ↑ 1.0 128,628 1

Seq Scan on matriculaperiodo (cost=0.00..3,468.28 rows=128,628 width=17) (actual time=0.003..10.368 rows=128,628 loops=1)

6. 1.078 2.316 ↑ 23.7 989 1

Hash (cost=32,149.91..32,149.91 rows=23,470 width=254) (actual time=2.316..2.316 rows=989 loops=1)

  • Buckets: 4096 Batches: 1 Memory Usage: 371kB
7. 0.248 1.238 ↑ 23.7 989 1

Nested Loop (cost=6.06..32,149.91 rows=23,470 width=254) (actual time=0.043..1.238 rows=989 loops=1)

8. 0.007 0.030 ↑ 405.0 1 1

Bitmap Heap Scan on arquivo (cost=5.63..405.98 rows=405 width=250) (actual time=0.029..0.030 rows=1 loops=1)

  • Recheck Cond: ((codigomaterial)::text = '129893786324172'::text)
  • Heap Blocks: exact=2
9. 0.023 0.023 ↑ 202.5 2 1

Bitmap Index Scan on idx_arquivo_codigomaterial (cost=0.00..5.53 rows=405 width=0) (actual time=0.023..0.023 rows=2 loops=1)

  • Index Cond: ((codigomaterial)::text = '129893786324172'::text)
10. 0.960 0.960 ↓ 1.2 989 1

Index Scan using ch_matriculaperiodoturmadisciplina_disciplina on matriculaperiodoturmadisciplina mptd (cost=0.43..70.44 rows=794 width=8) (actual time=0.009..0.960 rows=989 loops=1)

  • Index Cond: (disciplina = arquivo.disciplina)
11. 23.828 50.371 ↑ 1.0 126,634 1

Hash (cost=3,686.86..3,686.86 rows=126,686 width=17) (actual time=50.371..50.371 rows=126,634 loops=1)

  • Buckets: 16384 Batches: 1 Memory Usage: 6450kB
12. 26.543 26.543 ↑ 1.0 126,634 1

Seq Scan on matricula (cost=0.00..3,686.86 rows=126,686 width=17) (actual time=0.004..26.543 rows=126,634 loops=1)

13. 0.056 0.171 ↑ 1.0 389 1

Hash (cost=19.89..19.89 rows=389 width=4) (actual time=0.171..0.171 rows=389 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 14kB
14. 0.115 0.115 ↑ 1.0 389 1

Seq Scan on curso (cost=0.00..19.89 rows=389 width=4) (actual time=0.004..0.115 rows=389 loops=1)