explain.depesz.com

PostgreSQL's explain analyze made readable

Result: syUm

Settings
# exclusive inclusive rows x rows loops node
1. 0.091 978,311.458 ↑ 501.0 998 1

Limit (cost=36.00..357,771.38 rows=500,000 width=146) (actual time=978,269.243..978,311.458 rows=998 loops=1)

2. 29,289.376 978,311.367 ↑ 2,991.8 998 1

Merge Join (cost=36.00..2,136,318.65 rows=2,985,842 width=146) (actual time=978,269.241..978,311.367 rows=998 loops=1)

  • Merge Cond: (tkts.tem_registro_consumo_id = bcr.id)
  • Join Filter: (to_char(CASE WHEN (tkts.last_update > bcr.last_update) THEN tkts.last_update ELSE bcr.last_update END, 'yyyymmdd'::text) >= '20191201'::text)
  • Rows Removed by Join Filter: 17884244
3. 41,604.813 41,604.813 ↑ 1.0 17,885,242 1

Index Scan using idx_bill_ticket_call_rec on bill_tickets tkts (cost=0.44..616,519.98 rows=17,885,242 width=48) (actual time=0.010..41,604.813 rows=17,885,242 loops=1)

  • Filter: (id_tem_bill_ivn_central > 0)
4. 907,417.178 907,417.178 ↑ 1.0 17,885,242 1

Index Scan using idx_bill_call_records_id_status on tem_registro_consumo bcr (cost=0.44..1,176,844.96 rows=18,017,503 width=102) (actual time=18.528..907,417.178 rows=17,885,242 loops=1)

Total runtime : 978,311.729 ms