explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 8oLJ

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 0.807 ↓ 4.0 4 1

Nested Loop (cost=9.45..111.40 rows=1 width=89) (actual time=0.213..0.807 rows=4 loops=1)

2. 0.027 0.788 ↓ 4.0 4 1

Nested Loop (cost=9.16..103.09 rows=1 width=82) (actual time=0.203..0.788 rows=4 loops=1)

  • Join Filter: (cid.fk_estado_id = est.id)
  • Rows Removed by Join Filter: 20
3. 0.002 0.741 ↓ 4.0 4 1

Nested Loop (cost=9.16..101.87 rows=1 width=86) (actual time=0.186..0.741 rows=4 loops=1)

4. 0.004 0.727 ↓ 4.0 4 1

Nested Loop (cost=9.02..101.63 rows=1 width=73) (actual time=0.178..0.727 rows=4 loops=1)

5. 0.039 0.699 ↓ 4.0 4 1

Hash Join (cost=8.87..101.45 rows=1 width=60) (actual time=0.158..0.699 rows=4 loops=1)

  • Hash Cond: (e.fk_pessoa_juridica_id = jur.id)
6. 0.210 0.631 ↑ 1.0 341 1

Merge Join (cost=0.57..92.24 rows=345 width=49) (actual time=0.028..0.631 rows=341 loops=1)

  • Merge Cond: (e.id = en.id)
7. 0.263 0.263 ↑ 101.0 342 1

Index Scan using estacionamento_pkey on estacionamento e (cost=0.29..3,792.29 rows=34,534 width=35) (actual time=0.010..0.263 rows=342 loops=1)

  • Filter: (valorhora > '20'::numeric)
  • Rows Removed by Filter: 659
8. 0.158 0.158 ↑ 1.0 1,000 1

Index Scan using endereco_pkey on endereco en (cost=0.28..49.27 rows=1,000 width=18) (actual time=0.014..0.158 rows=1,000 loops=1)

9. 0.006 0.029 ↑ 1.0 1 1

Hash (cost=8.29..8.29 rows=1 width=19) (actual time=0.028..0.029 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
10. 0.023 0.023 ↑ 1.0 1 1

Index Scan using idx_cnpj on pessoa_juridica jur (cost=0.28..8.29 rows=1 width=19) (actual time=0.022..0.023 rows=1 loops=1)

  • Index Cond: ((cnpj)::text = 'pzpnd-cnpj'::text)
11. 0.024 0.024 ↑ 1.0 1 4

Index Scan using bairro_pkey on bairro b (cost=0.14..0.17 rows=1 width=21) (actual time=0.006..0.006 rows=1 loops=4)

  • Index Cond: (id = en.fk_bairro_id)
12. 0.012 0.012 ↑ 1.0 1 4

Index Scan using cidade_pkey on cidade cid (cost=0.14..0.24 rows=1 width=21) (actual time=0.003..0.003 rows=1 loops=4)

  • Index Cond: (id = b.fk_cidade_id)
13. 0.020 0.020 ↑ 1.7 6 4

Seq Scan on estado est (cost=0.00..1.10 rows=10 width=4) (actual time=0.004..0.005 rows=6 loops=4)

14. 0.016 0.016 ↑ 1.0 1 4

Index Scan using pessoa_pkey on pessoa pes (cost=0.29..8.31 rows=1 width=15) (actual time=0.004..0.004 rows=1 loops=4)

  • Index Cond: (id = jur.fk_pessoa_id)