AnsweredAssumed Answered

Finding accounts for recurring billing based on two fields

Question asked by TomFairley on Sep 3, 2013
Latest reply on Sep 10, 2013 by philmodjunk

Title

Finding accounts for recurring billing based on two fields

Post

     Here's the business case...

      

     I have a number of clients that I bill on a Quarterly, Annual, Semi-Annual or Monthly basis.  I need to script a find that will show all the accounts that require an invoice to be generated in a certain month.

     The field "Billing_Cycle" records the frequency of billing (Quarterly, Annual, Semi-Annual or Monthly as "3", "12", "6", and "1" respectively)

      

     The field "Billing_Renewal" records the month they signed up ("January", "February" and so on)

      

     So for instance for February I would need to see the following criteria met:

     Billing_Cycle = "1"

     OR

     Billing_Cycle = "3" AND Billing_Renewal = "February" OR "May" OR "August" OR "November"

     OR

     Billing_Cycle = "6" AND Billing_Renewal = "February" OR "August" 

     OR

     Billing_Cycle = "12" AND Billing_Renewal = "February" 

      

     HELP!  I've tried a number of scripts and nothing seems to test correctly!! :(

      

Outcomes