explain.depesz.com

PostgreSQL's explain analyze made readable

Result: vaAE

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

HashSetOp Except (cost=2,366,729.33..4,622,523.06 rows=21,606 width=92) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Append (cost=2,366,729.33..4,586,544.00 rows=2,878,325 width=92) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 1 (cost=2,366,729.33..3,222,048.59 rows=21,606 width=92) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,366,729.33..3,221,778.52 rows=21,606 width=60) (actual rows= loops=)

  • Hash Cond: (c.term_code = b1.term_code)
5. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,342,521.43..3,197,327.54 rows=21,606 width=60) (actual rows= loops=)

  • Hash Cond: (to_char(c.service_uid) = (d.inst_prod_id)::text)
  • Join Filter: (((d.nap_packeage)::text = ' '::text) OR (c.tc_finterms_line_no IS NOT NULL))
6. 0.000 0.000 ↓ 0.0

Seq Scan on ip_service_billing c (cost=0.00..830,954.64 rows=4,711,403 width=60) (actual rows= loops=)

  • Filter: (service_end_date IS NULL)
7. 0.000 0.000 ↓ 0.0

Hash (cost=2,338,976.96..2,338,976.96 rows=283,557 width=12) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Index Only Scan using psfrf_inst_prod on ps_rf_inst_prod d (cost=0.56..2,338,976.96 rows=283,557 width=12) (actual rows= loops=)

  • Filter: (((setid)::text || ''::text) = 'SHARE'::text)
9. 0.000 0.000 ↓ 0.0

Hash (cost=22,413.51..22,413.51 rows=143,551 width=4) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

HashAggregate (cost=20,978.00..22,413.51 rows=143,551 width=4) (actual rows= loops=)

  • Group Key: b1.term_code
11. 0.000 0.000 ↓ 0.0

Seq Scan on tv_finterm b1 (cost=0.00..20,438.01 rows=215,998 width=4) (actual rows= loops=)

  • Filter: (((pricing_method_code)::text = ANY ('{2,4}'::text[])) AND ((term_type_ss)::text <> '1'::text))
12. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 2 (cost=24,207.90..1,364,495.41 rows=2,856,719 width=66) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Hash Join (cost=24,207.90..1,335,928.22 rows=2,856,719 width=38) (actual rows= loops=)

  • Hash Cond: (a.nap_billing_catnum = (b.term_code)::numeric)
14. 0.000 0.000 ↓ 0.0

Seq Scan on nap_ip_debit a (cost=0.00..1,246,729.96 rows=5,713,438 width=38) (actual rows= loops=)

  • Filter: (nap_finterm_end_dt IS NULL)
15. 0.000 0.000 ↓ 0.0

Hash (cost=22,413.51..22,413.51 rows=143,551 width=4) (actual rows= loops=)

16. 0.000 0.000 ↓ 0.0

HashAggregate (cost=20,978.00..22,413.51 rows=143,551 width=4) (actual rows= loops=)

  • Group Key: (b.term_code)::numeric
17. 0.000 0.000 ↓ 0.0

Seq Scan on tv_finterm b (cost=0.00..20,438.01 rows=215,998 width=4) (actual rows= loops=)

  • Filter: (((pricing_method_code)::text = ANY ('{2,4}'::text[])) AND ((term_type_ss)::text <> '1'::text))