explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 136x

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Limit (cost=45,702.52..45,702.53 rows=1 width=630) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=45,702.52..45,702.53 rows=1 width=630) (actual rows= loops=)

  • Sort Key: (lower((cliente1_.nome)::text)), cliente1_.id
3. 0.000 0.000 ↓ 0.0

Group (cost=45,702.49..45,702.51 rows=1 width=630) (actual rows= loops=)

  • Group Key: cliente1_.id, negativaca0_.data_negativacao, funcionari2_.nome, loja3_.nome
4. 0.000 0.000 ↓ 0.0

Sort (cost=45,702.49..45,702.50 rows=1 width=598) (actual rows= loops=)

  • Sort Key: cliente1_.id, negativaca0_.data_negativacao, funcionari2_.nome, loja3_.nome
5. 0.000 0.000 ↓ 0.0

Nested Loop (cost=38,200.61..45,702.48 rows=1 width=598) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=38,200.32..45,701.00 rows=1 width=565) (actual rows= loops=)

  • Join Filter: (negativaca0_.loja_id = loja3_.id)
7. 0.000 0.000 ↓ 0.0

Nested Loop (cost=38,200.32..45,699.85 rows=1 width=57) (actual rows= loops=)

  • Join Filter: (negativaca0_.funcionario_id = funcionari2_.id)
8. 0.000 0.000 ↓ 0.0

Nested Loop (cost=38,200.32..45,692.29 rows=1 width=40) (actual rows= loops=)

  • Join Filter: (negativaca0_.cliente_id = prestacao4_.cliente_id)
9. 0.000 0.000 ↓ 0.0

Unique (cost=38,200.32..45,504.69 rows=1 width=8) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Gather Merge (cost=38,200.32..45,504.69 rows=1 width=8) (actual rows= loops=)

  • Workers Planned: 2
11. 0.000 0.000 ↓ 0.0

Merge Anti Join (cost=37,200.30..44,504.55 rows=1 width=8) (actual rows= loops=)

  • Merge Cond: (prestacao4_.cliente_id = prestacao5_.cliente_id)
12. 0.000 0.000 ↓ 0.0

Sort (cost=28,329.67..28,799.42 rows=187,898 width=8) (actual rows= loops=)

  • Sort Key: prestacao4_.cliente_id
13. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on prestacao prestacao4_ (cost=0.00..9,301.19 rows=187,898 width=8) (actual rows= loops=)

  • Filter: ((recebimento_id IS NOT NULL) AND (data_vencimento < '2020-07-07'::date))
14. 0.000 0.000 ↓ 0.0

Sort (cost=8,870.62..8,920.79 rows=20,065 width=8) (actual rows= loops=)

  • Sort Key: prestacao5_.cliente_id
15. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on prestacao prestacao5_ (cost=387.30..7,436.74 rows=20,065 width=8) (actual rows= loops=)

  • Recheck Cond: (recebimento_id IS NULL)
  • Filter: (data_vencimento < '2020-07-07'::date)
16. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on prestacao_recebimento_id_ix (cost=0.00..382.28 rows=20,515 width=0) (actual rows= loops=)

  • Index Cond: (recebimento_id IS NULL)
17. 0.000 0.000 ↓ 0.0

Seq Scan on negativacao_cliente negativaca0_ (cost=0.00..155.99 rows=2,528 width=32) (actual rows= loops=)

  • Filter: (data_remocao_negativacao IS NULL)
18. 0.000 0.000 ↓ 0.0

Seq Scan on funcionario funcionari2_ (cost=0.00..5.58 rows=158 width=33) (actual rows= loops=)

19. 0.000 0.000 ↓ 0.0

Seq Scan on loja loja3_ (cost=0.00..1.07 rows=7 width=524) (actual rows= loops=)

20. 0.000 0.000 ↓ 0.0

Index Scan using cliente_pkey on cliente cliente1_ (cost=0.29..1.48 rows=1 width=49) (actual rows= loops=)

  • Index Cond: (id = negativaca0_.cliente_id)