explain.depesz.com

PostgreSQL's explain analyze made readable

Result: aXmM

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

Aggregate (cost=122,797.36..122,797.37 rows=1 width=8) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

HashAggregate (cost=122,797.29..122,797.32 rows=3 width=8) (actual rows= loops=)

  • Group Key: (CASE WHEN (ssh.rateduptodate >= ssh.subservlifecyclestatetodate) THEN ssh.subservlifecyclestatetodate ELSE ssh.rateduptodate END)
3. 0.000 0.000 ↓ 0.0

Gather (cost=1,004.97..122,797.29 rows=3 width=8) (actual rows= loops=)

  • Workers Planned: 2
4. 0.000 0.000 ↓ 0.0

Parallel Append (cost=4.97..121,796.99 rows=3 width=8) (actual rows= loops=)

5. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.97..40,601.84 rows=1 width=8) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.42..40,593.26 rows=1 width=49) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Hash Join (cost=3.86..13,416.22 rows=10,492 width=33) (actual rows= loops=)

  • Hash Cond: ((subscriptionservices.prodid)::text = (products.prodid)::text)
8. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on subscriptionservices (cost=0.00..13,103.70 rows=110,170 width=66) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Hash (cost=3.79..3.79 rows=6 width=33) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Seq Scan on products (cost=0.00..3.79 rows=6 width=33) (actual rows= loops=)

  • Filter: ((prodtypeid)::text = 'D0EF6CD182DA43E190032CC0AAD607E8'::text)
11. 0.000 0.000 ↓ 0.0

Index Scan using ix_subsrvlifecyc01 on subservicelifecyclestatehist ssh (cost=0.55..2.58 rows=1 width=82) (actual rows= loops=)

  • Index Cond: ((subserviceid)::text = (subscriptionservices.subserviceid)::text)
  • Filter: (((accrecid)::text = '2F0E3E2A76714D918CB1BDA3193D9D47'::text) AND ((billingdirective)::text = 'TO_BE_BILLED'::text))
12. 0.000 0.000 ↓ 0.0

Index Scan using pk_subservicelifec on subservicelifecyclestatehist ssh1 (cost=0.55..8.57 rows=1 width=33) (actual rows= loops=)

  • Index Cond: ((subservlifecyclestateid)::text = (ssh.replacedbylifecyclestatehistid)::text)
  • Filter: ((billingdirective)::text = 'TO_BE_CREDITED'::text)
13. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.97..40,601.84 rows=1 width=8) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.42..40,593.26 rows=1 width=41) (actual rows= loops=)

15. 0.000 0.000 ↓ 0.0

Hash Join (cost=3.86..13,416.22 rows=10,492 width=33) (actual rows= loops=)

  • Hash Cond: ((subscriptionservices_1.prodid)::text = (products_1.prodid)::text)
16. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on subscriptionservices subscriptionservices_1 (cost=0.00..13,103.70 rows=110,170 width=66) (actual rows= loops=)

17. 0.000 0.000 ↓ 0.0

Hash (cost=3.79..3.79 rows=6 width=33) (actual rows= loops=)

18. 0.000 0.000 ↓ 0.0

Seq Scan on products products_1 (cost=0.00..3.79 rows=6 width=33) (actual rows= loops=)

  • Filter: ((prodtypeid)::text = 'D0EF6CD182DA43E190032CC0AAD607E8'::text)
19. 0.000 0.000 ↓ 0.0

Index Scan using ix_subsrvlifecyc01 on subservicelifecyclestatehist ssh_1 (cost=0.55..2.58 rows=1 width=74) (actual rows= loops=)

  • Index Cond: ((subserviceid)::text = (subscriptionservices_1.subserviceid)::text)
  • Filter: (((accrecid)::text = '2F0E3E2A76714D918CB1BDA3193D9D47'::text) AND ((billingdirective)::text = 'TO_BE_BILLED'::text))
20. 0.000 0.000 ↓ 0.0

Index Scan using pk_subservicelifec on subservicelifecyclestatehist ssh1_1 (cost=0.55..8.57 rows=1 width=33) (actual rows= loops=)

  • Index Cond: ((subservlifecyclestateid)::text = (ssh_1.replacedbylifecyclestatehistid)::text)
  • Filter: ((billingdirective)::text <> 'TO_BE_CREDITED'::text)
21. 0.000 0.000 ↓ 0.0

Nested Loop (cost=4.42..40,593.26 rows=1 width=8) (actual rows= loops=)

22. 0.000 0.000 ↓ 0.0

Hash Join (cost=3.86..13,416.22 rows=10,492 width=33) (actual rows= loops=)

  • Hash Cond: ((subscriptionservices_2.prodid)::text = (products_2.prodid)::text)
23. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on subscriptionservices subscriptionservices_2 (cost=0.00..13,103.70 rows=110,170 width=66) (actual rows= loops=)

24. 0.000 0.000 ↓ 0.0

Hash (cost=3.79..3.79 rows=6 width=33) (actual rows= loops=)

25. 0.000 0.000 ↓ 0.0

Seq Scan on products products_2 (cost=0.00..3.79 rows=6 width=33) (actual rows= loops=)

  • Filter: ((prodtypeid)::text = 'D0EF6CD182DA43E190032CC0AAD607E8'::text)
26. 0.000 0.000 ↓ 0.0

Index Scan using ix_subsrvlifecyc01 on subservicelifecyclestatehist ssh_2 (cost=0.55..2.58 rows=1 width=41) (actual rows= loops=)

  • Index Cond: ((subserviceid)::text = (subscriptionservices_2.subserviceid)::text)
  • Filter: ((replacedbylifecyclestatehistid IS NULL) AND ((accrecid)::text = '2F0E3E2A76714D918CB1BDA3193D9D47'::text) AND ((billingdirective)::text = 'TO_BE_BILLED'::text))