explain.depesz.com

PostgreSQL's explain analyze made readable

Result: qBDF : Optimization for: plan #SdI8

Settings

Optimization path:

# exclusive inclusive rows x rows loops node
1. 92.181 931.469 ↑ 1.3 148,890 1

WindowAgg (cost=365,455.17..369,283.47 rows=191,415 width=84) (actual time=806.773..931.469 rows=148,890 loops=1)

2. 139.631 839.288 ↑ 1.3 148,890 1

Sort (cost=365,455.17..365,933.71 rows=191,415 width=64) (actual time=806.760..839.288 rows=148,890 loops=1)

  • Sort Key: vw.femea_id, vw.data_hora_cobertura DESC
  • Sort Method: external merge Disk: 10,536kB
3. 63.982 699.657 ↑ 1.3 148,890 1

Hash Join (cost=1,387.78..344,445.16 rows=191,415 width=64) (actual time=268.428..699.657 rows=148,890 loops=1)

  • Hash Cond: (vw.propriedade_id = pr.id)
4. 626.658 626.658 ↑ 1.3 161,073 1

Index Scan using vw_data_hora_cobertura_tipo_cobertura_idx on vw_modelo_reprodutivo vw (cost=0.56..342,499.60 rows=212,670 width=64) (actual time=259.351..626.658 rows=161,073 loops=1)

  • Index Cond: ((data_hora_cobertura < '2018-07-20'::date) AND (contrato_id = 16))
5. 2.953 9.017 ↑ 1.0 27,876 1

Hash (cost=1,037.68..1,037.68 rows=27,963 width=4) (actual time=9.016..9.017 rows=27,876 loops=1)

  • Buckets: 32,768 Batches: 1 Memory Usage: 1,237kB
6. 6.064 6.064 ↑ 1.0 27,876 1

Seq Scan on mbw_propriedade pr (cost=0.00..1,037.68 rows=27,963 width=4) (actual time=0.012..6.064 rows=27,876 loops=1)

  • Filter: (ativo IS TRUE)
  • Rows Removed by Filter: 3,093
Planning time : 0.291 ms
Execution time : 944.377 ms