explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 5uIH

Settings
# exclusive inclusive rows x rows loops node
1. 0.047 1.228 ↓ 5.0 5 1

Nested Loop (cost=1.42..104.87 rows=1 width=89) (actual time=0.186..1.228 rows=5 loops=1)

  • Join Filter: (cid.fk_estado_id = est.id)
  • Rows Removed by Join Filter: 26
2. 0.004 1.161 ↓ 5.0 5 1

Nested Loop (cost=1.42..103.64 rows=1 width=93) (actual time=0.168..1.161 rows=5 loops=1)

3. 0.003 1.152 ↓ 5.0 5 1

Nested Loop (cost=1.28..103.40 rows=1 width=80) (actual time=0.165..1.152 rows=5 loops=1)

4. 0.097 1.139 ↓ 5.0 5 1

Merge Join (cost=1.14..103.23 rows=1 width=67) (actual time=0.161..1.139 rows=5 loops=1)

  • Merge Cond: (e.id = en.id)
5. 0.600 0.905 ↑ 16.7 6 1

Nested Loop (cost=0.86..5,058.90 rows=100 width=53) (actual time=0.123..0.905 rows=6 loops=1)

  • Join Filter: (jur.id = e.fk_pessoa_juridica_id)
  • Rows Removed by Join Filter: 1685
6. 0.305 0.305 ↑ 59.1 1,691 1

Index Scan using estacionamento_pkey on estacionamento e (cost=0.29..3,542.29 rows=100,000 width=35) (actual time=0.008..0.305 rows=1,691 loops=1)

7. 0.000 0.000 ↑ 1.0 1 1,691

Materialize (cost=0.57..16.61 rows=1 width=26) (actual time=0.000..0.000 rows=1 loops=1,691)

8. 0.001 0.024 ↑ 1.0 1 1

Nested Loop (cost=0.57..16.60 rows=1 width=26) (actual time=0.024..0.024 rows=1 loops=1)

9. 0.018 0.018 ↑ 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.017..0.018 rows=1 loops=1)

  • Index Cond: ((cnpj)::text = 'pzpnd-cnpj'::text)
10. 0.005 0.005 ↑ 1.0 1 1

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

  • Index Cond: (id = jur.fk_pessoa_id)
11. 0.137 0.137 ↑ 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.005..0.137 rows=1,000 loops=1)

12. 0.010 0.010 ↑ 1.0 1 5

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

  • Index Cond: (id = en.fk_bairro_id)
13. 0.005 0.005 ↑ 1.0 1 5

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

  • Index Cond: (id = b.fk_cidade_id)
14. 0.020 0.020 ↑ 1.7 6 5

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