explain.depesz.com

PostgreSQL's explain analyze made readable

Result: om3w : Optimization for: plan #2HOa

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 51.900 86,810.230 ↓ 12,802.0 12,802 1

Nested Loop (cost=1.40..197.76 rows=1 width=288) (actual time=46,265.010..86,810.230 rows=12,802 loops=1)

2. 37.816 86,681.518 ↓ 12,802.0 12,802 1

Nested Loop (cost=0.98..197.09 rows=1 width=270) (actual time=46,244.096..86,681.518 rows=12,802 loops=1)

3. 28.060 28.060 ↑ 1.0 1 1

Index Scan using uax_id_pk on up_account_xref uax (cost=0.41..8.43 rows=1 width=16) (actual time=28.055..28.060 rows=1 loops=1)

  • Index Cond: (((xref_type)::text = 'merchant'::text) AND ((xref_key)::text = '5d5d5f3989391377c7228c34'::text))
4. 86,615.642 86,615.642 ↓ 1,828.9 12,802 1

Index Scan using utx_accts_master_date_idx on up_transaction ut (cost=0.56..188.58 rows=7 width=270) (actual time=46,214.707..86,615.642 rows=12,802 loops=1)

  • Index Cond: ((account_id_from = uax.account_id) AND (account_reg_to = 3) AND (create_time >= COALESCE(to_timestamp('01-10-2020 00'::text, 'DD-MM-YYYY HH24'::text))) AND (create_time <= COALESCE(to_timestamp('01-10-2020 10'::text, 'DD-MM-YYYY HH24'::text))))
  • Filter: (status = 'C'::bpchar)
5. 76.812 76.812 ↑ 1.0 1 12,802

Index Scan using uax_accid_idx on up_account_xref uaxbil (cost=0.41..0.66 rows=1 width=34) (actual time=0.005..0.006 rows=1 loops=12,802)

  • Index Cond: (account_id = ut.account_id_to)
  • Filter: (((xref_type)::text = 'biller'::text) AND ((xref_key)::text = ANY ('{telcel,movistar,iusacell,unefon,nextel,virgin,maztiempo,cierto,alo,att}'::text[])))
Planning time : 1,050.347 ms
Execution time : 86,887.020 ms