explain.depesz.com

PostgreSQL's explain analyze made readable

Result: VjEg : Optimization for: plan #k8ys

Settings

Optimization path:

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 10,067.758 328,935.099 ↑ 5.9 592,088 1

Gather (cost=1,295,376.72..4,584,842.61 rows=3,498,302 width=281) (actual time=199,396.918..328,935.099 rows=592,088 loops=1)

  • Workers Planned: 4
  • Workers Launched: 4
2. 88,679.215 318,867.341 ↑ 7.4 118,418 5 / 5

Hash Join (cost=1,294,376.72..4,148,741.31 rows=874,576 width=281) (actual time=199,344.735..318,867.341 rows=118,418 loops=5)

  • Hash Cond: (bcr.id = tkts.tem_registro_consumo_id)
  • Join Filter: (CASE WHEN (tkts.last_update > bcr.last_update) THEN tkts.last_update ELSE bcr.last_update END >= to_timestamp('20200106'::text, 'YYYYMMDD'::text))
  • Rows Removed by Join Filter: 5,779,064
3. 136,140.784 136,140.784 ↑ 1.2 5,897,482 5 / 5

Parallel Seq Scan on tem_registro_consumo bcr (cost=0.00..2,010,436.35 rows=7,310,253 width=101) (actual time=0.030..136,140.784 rows=5,897,482 loops=5)

  • Filter: ((status)::text = 'CHAMADA_TARIFADA'::text)
  • Rows Removed by Filter: 10,451,981
4. 34,126.404 94,047.342 ↓ 1.0 29,487,408 5 / 5

Hash (cost=669,756.08..669,756.08 rows=29,339,971 width=47) (actual time=94,047.342..94,047.342 rows=29,487,408 loops=5)

  • Buckets: 524,288 Batches: 128 Memory Usage: 21,890kB
5. 59,920.938 59,920.938 ↓ 1.0 29,487,408 5 / 5

Seq Scan on bill_tickets tkts (cost=0.00..669,756.08 rows=29,339,971 width=47) (actual time=0.239..59,920.938 rows=29,487,408 loops=5)

  • Filter: (COALESCE(id_tem_bill_ivn_central, '-1'::integer) IS NOT NULL)
Planning time : 1.624 ms
Execution time : 329,014.767 ms