explain.depesz.com

PostgreSQL's explain analyze made readable

Result: lFxL

Settings
# exclusive inclusive rows x rows loops node
1. 0.015 743.150 ↑ 5.0 1 1

HashAggregate (cost=51,118.37..51,118.42 rows=5 width=24) (actual time=743.150..743.150 rows=1 loops=1)

  • Group Key: linpedido.codigo
2. 15.291 743.135 ↑ 9.0 1 1

Hash Right Join (cost=50,448.54..51,118.28 rows=9 width=24) (actual time=743.133..743.135 rows=1 loops=1)

  • Hash Cond: (linalbaran.codlinpedido = lped.codigo)
3. 340.651 727.213 ↓ 7.9 223,757 1

HashAggregate (cost=49,125.46..49,407.45 rows=28,199 width=16) (actual time=651.960..727.213 rows=223,757 loops=1)

  • Group Key: linalbaran.codlinpedido
4. 386.562 386.562 ↓ 1.0 455,657 1

Seq Scan on linalbaran (cost=0.00..46,853.64 rows=454,364 width=16) (actual time=0.004..386.562 rows=455,657 loops=1)

5. 0.008 0.631 ↑ 9.0 1 1

Hash (cost=1,322.97..1,322.97 rows=9 width=24) (actual time=0.631..0.631 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
6. 0.021 0.623 ↑ 9.0 1 1

Nested Loop Left Join (cost=5.34..1,322.97 rows=9 width=24) (actual time=0.619..0.623 rows=1 loops=1)

7. 0.030 0.030 ↑ 5.0 1 1

Index Scan using linpedido_pedidoempresa_idx on linpedido (cost=0.42..24.49 rows=5 width=18) (actual time=0.029..0.030 rows=1 loops=1)

  • Index Cond: (((codpedido)::text = 'GM/20/02936'::text) AND ((cod_empresa)::text = 'GMTECHNOLOGY'::text))
8. 0.499 0.572 ↑ 1.0 1 1

Bitmap Heap Scan on linpedido lped (cost=4.92..259.69 rows=1 width=26) (actual time=0.570..0.572 rows=1 loops=1)

  • Recheck Cond: ((codproducto)::text = (linpedido.codproducto)::text)
  • Filter: ((historico IS FALSE) AND (codigo <> linpedido.codigo) AND ((codalmacen)::text = (linpedido.codalmacen)::text))
  • Rows Removed by Filter: 263
  • Heap Blocks: exact=263
9. 0.073 0.073 ↓ 4.0 264 1

Bitmap Index Scan on linpedido_codproducto_idx (cost=0.00..4.92 rows=66 width=0) (actual time=0.073..0.073 rows=264 loops=1)

  • Index Cond: ((codproducto)::text = (linpedido.codproducto)::text)
Planning time : 1.733 ms
Execution time : 745.887 ms