explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Ugqm : Optimization for: plan #IkBn

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 2.232 30.514 ↓ 21.2 5,141 1

Nested Loop (cost=396.14..3,627.69 rows=243 width=1,055) (actual time=5.007..30.514 rows=5,141 loops=1)

2. 5.859 12.859 ↓ 7.0 5,141 1

Hash Join (cost=395.72..2,443.82 rows=731 width=982) (actual time=4.987..12.859 rows=5,141 loops=1)

  • Hash Cond: ((fec.ccm_clave_acceso)::text = (cnc.cnc_clave_acceso)::text)
3. 2.160 2.962 ↓ 1.0 7,066 1

Bitmap Heap Scan on fe_comprobante fec (cost=135.04..2,149.34 rows=7,064 width=274) (actual time=0.915..2.962 rows=7,066 loops=1)

  • Recheck Cond: ((ccm_documento)::text = 'NCC'::text)
  • Heap Blocks: exact=992
4. 0.802 0.802 ↓ 1.0 7,066 1

Bitmap Index Scan on idx_fe_comprobante_ccm_documento (cost=0.00..133.27 rows=7,064 width=0) (actual time=0.802..0.802 rows=7,066 loops=1)

  • Index Cond: ((ccm_documento)::text = 'NCC'::text)
5. 2.611 4.038 ↑ 1.0 5,152 1

Hash (cost=194.75..194.75 rows=5,275 width=708) (actual time=4.038..4.038 rows=5,152 loops=1)

  • Buckets: 8192 Batches: 1 Memory Usage: 1160kB
6. 1.427 1.427 ↑ 1.0 5,275 1

Seq Scan on cnotacre cnc (cost=0.00..194.75 rows=5,275 width=708) (actual time=0.003..1.427 rows=5,275 loops=1)

7. 15.423 15.423 ↑ 1.0 1 5,141

Index Scan using ccomproba_uk_llave on ccomproba ccm (cost=0.42..1.61 rows=1 width=73) (actual time=0.003..0.003 rows=1 loops=5,141)

  • Index Cond: ((ccm_periodo = cnc.cnc_periodo) AND (cti_id = cnc.cti_id) AND (pve_id = cnc.pve_id) AND (ccm_numero = cnc.cnc_numero))