Jump to content

Question

Posted

Hey Everyone

 

What I am looking to do is get a report of all active services

that will show an estimated annual income.

 

The issue I see some services will bill monthly, quarterly .... annually

 

How can we normalize this and generate a report?

 

Any help or if this is already there please let me know :)

1 answer to this question

Recommended Posts

  • 0
Posted

For a custom report, you'll need to calculate the cost estimate of every service in the SELECT clause for a column in your query.

 

Below is pseudo-code for the algorithm to calculate annual cost for a service. You can implement it as SQL in your query.

// Annual income is price * period / term in days
annual_service_income :=
(service_price)
* (
if service_period is 'day'
return 365.24
elseif service_period is 'week'
return 52
elseif service_period is 'month'
return 12
else
return 1
)
/ (service_term)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...