explain.depesz.com

PostgreSQL's explain analyze made readable

Result: QMVm

Settings
# exclusive inclusive rows x rows loops node
1. 0.005 0.248 ↑ 1.0 6 1

Limit (cost=1.68..52.63 rows=6 width=2,813) (actual time=0.088..0.248 rows=6 loops=1)

2. 0.007 0.243 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=1.68..1,474,704.96 rows=173,657 width=2,813) (actual time=0.087..0.243 rows=6 loops=1)

  • Join Filter: ("Coleta".fk_tipo_veiculo = "TipoVeiculo".codigo)
  • Rows Removed by Join Filter: 42
3. 0.006 0.230 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=1.68..1,450,785.46 rows=173,657 width=2,802) (actual time=0.082..0.230 rows=6 loops=1)

4. 0.005 0.224 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=1.40..1,356,258.50 rows=173,657 width=2,777) (actual time=0.081..0.224 rows=6 loops=1)

5. 0.008 0.219 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=1.12..1,305,399.85 rows=173,657 width=2,764) (actual time=0.080..0.219 rows=6 loops=1)

6. 0.015 0.199 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=0.99..1,278,571.35 rows=173,657 width=1,735) (actual time=0.073..0.199 rows=6 loops=1)

  • Join Filter: ("Coleta".fk_tipo_coleta = "TipoColeta".codigo)
  • Rows Removed by Join Filter: 6
7. 0.005 0.184 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=0.99..1,274,228.90 rows=173,657 width=1,727) (actual time=0.070..0.184 rows=6 loops=1)

8. 0.015 0.173 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=0.71..1,222,563.84 rows=173,657 width=1,701) (actual time=0.067..0.173 rows=6 loops=1)

  • Join Filter: ("Remessa".fk_estado = ("Remessa.Estado".sigla)::bpchar)
  • Rows Removed by Join Filter: 154
9. 0.008 0.140 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=0.71..1,152,231.42 rows=173,657 width=672) (actual time=0.058..0.140 rows=6 loops=1)

10. 0.015 0.114 ↑ 28,942.8 6 1

Nested Loop (cost=0.56..1,124,028.42 rows=173,657 width=648) (actual time=0.050..0.114 rows=6 loops=1)

11. 0.009 0.027 ↑ 28,942.8 6 1

Nested Loop Left Join (cost=0.00..36,637.50 rows=173,657 width=428) (actual time=0.014..0.027 rows=6 loops=1)

  • Join Filter: ("Coleta"."TipoDocumentoCodigo" = "TipoDocumento".codigo)
  • Rows Removed by Join Filter: 60
12. 0.006 0.006 ↑ 28,942.8 6 1

Seq Scan on "Coleta" (cost=0.00..10,152.57 rows=173,657 width=415) (actual time=0.005..0.006 rows=6 loops=1)

13. 0.009 0.012 ↑ 1.0 11 6

Materialize (cost=0.00..1.17 rows=11 width=17) (actual time=0.001..0.002 rows=11 loops=6)

14. 0.003 0.003 ↑ 1.0 11 1

Seq Scan on "TipoDocumento" (cost=0.00..1.11 rows=11 width=17) (actual time=0.002..0.003 rows=11 loops=1)

15. 0.072 0.072 ↑ 1.0 1 6

Index Scan using "Remessa_pkey" on "Remessa" (cost=0.56..6.26 rows=1 width=232) (actual time=0.012..0.012 rows=1 loops=6)

  • Index Cond: ((codigo)::text = ("Coleta".fk_remessa)::text)
16. 0.018 0.018 ↑ 1.0 1 6

Index Scan using "Servico_pkey" on "Servico" "Remessa.Servico" (cost=0.14..0.16 rows=1 width=28) (actual time=0.003..0.003 rows=1 loops=6)

  • Index Cond: ("Remessa".fk_servico = codigo)
17. 0.013 0.018 ↑ 1.0 27 6

Materialize (cost=0.00..1.41 rows=27 width=1,032) (actual time=0.001..0.003 rows=27 loops=6)

18. 0.005 0.005 ↑ 1.0 27 1

Seq Scan on "Estado" "Remessa.Estado" (cost=0.00..1.27 rows=27 width=1,032) (actual time=0.002..0.005 rows=27 loops=1)

19. 0.006 0.006 ↑ 1.0 1 6

Index Scan using "CentroCustoCliente_pkey" on "CentroCustoCliente" "Remessa.CentroCustoCliente" (cost=0.28..0.30 rows=1 width=30) (actual time=0.001..0.001 rows=1 loops=6)

  • Index Cond: ("Remessa".fk_centro_custo = codigo)
20. 0.000 0.000 ↑ 1.0 2 6

Materialize (cost=0.00..1.03 rows=2 width=12) (actual time=0.000..0.000 rows=2 loops=6)

21. 0.001 0.001 ↑ 1.0 2 1

Seq Scan on "TipoColeta" (cost=0.00..1.02 rows=2 width=12) (actual time=0.001..0.001 rows=2 loops=1)

22. 0.012 0.012 ↑ 1.0 1 6

Index Scan using idx_estado_sigla on "Estado" "EstadoColetar" (cost=0.14..0.16 rows=1 width=1,032) (actual time=0.002..0.002 rows=1 loops=6)

  • Index Cond: (("Coleta".fk_estado_coleta)::text = (sigla)::text)
23. 0.000 0.000 ↓ 0.0 0 6

Index Scan using "RotaColetaEntrega_pkey" on "RotaColetaEntrega" "RotaPadrao" (cost=0.28..0.29 rows=1 width=17) (actual time=0.000..0.000 rows=0 loops=6)

  • Index Cond: ("Coleta".fk_rota = codigo)
24. 0.000 0.000 ↓ 0.0 0 6

Index Scan using "Entregador_pkey" on "Entregador" "MotoristaPadrao" (cost=0.28..0.54 rows=1 width=29) (actual time=0.000..0.000 rows=0 loops=6)

  • Index Cond: ("Coleta".fk_entregador = codigo)
25. 0.004 0.006 ↑ 1.2 8 6

Materialize (cost=0.00..1.15 rows=10 width=11) (actual time=0.000..0.001 rows=8 loops=6)

26. 0.002 0.002 ↑ 1.2 8 1

Seq Scan on "TipoVeiculo" (cost=0.00..1.10 rows=10 width=11) (actual time=0.002..0.002 rows=8 loops=1)

Planning time : 5.518 ms