explain.depesz.com

PostgreSQL's explain analyze made readable

Result: b7UVO

Settings
# exclusive inclusive rows x rows loops node
1. 190,007.973 436,983.594 ↓ 24.0 33,257,173 1

Hash Join (cost=1,298,892.40..6,811,710.37 rows=1,386,343 width=144) (actual time=39,227.774..436,983.594 rows=33,257,173 loops=1)

  • Hash Cond: (bcr.id = tkts.tem_registro_consumo_id)
  • Join Filter: (to_char(CASE WHEN (tkts.last_update > bcr.last_update) THEN tkts.last_update ELSE bcr.last_update END, 'yyyymmdd'::text) >= '20180101'::text)
2. 207,765.603 207,765.603 ↓ 1.1 33,257,173 1

Seq Scan on tem_registro_consumo bcr (cost=0.00..3,760,996.60 rows=30,422,519 width=101) (actual time=4.732..207,765.603 rows=33,257,173 loops=1)

  • Filter: ((status)::text = 'CHAMADA_TARIFADA'::text)
  • Rows Removed by Filter: 69554346
3. 9,095.938 39,210.018 ↓ 2.6 33,257,173 1

Hash (cost=1,025,530.55..1,025,530.55 rows=12,840,468 width=47) (actual time=39,210.018..39,210.018 rows=33,257,173 loops=1)

  • Buckets: 32768 Batches: 256 (originally 128) Memory Usage: 14337kB
4. 30,114.080 30,114.080 ↓ 2.6 33,257,173 1

Seq Scan on bill_tickets tkts (cost=0.00..1,025,530.55 rows=12,840,468 width=47) (actual time=6.330..30,114.080 rows=33,257,173 loops=1)

  • Filter: (COALESCE(id_tem_bill_ivn_central, (-1)) > 0)
Total runtime : 438,144.759 ms