Hi.
I know how to do the price calculation (invoice table ) for todays year.
But i would like to do the price calculation for every year in the past too, and then compsre it with what my customers did paid. So i will get a history.
I have a table calles invoice:
Name start.year end.year fee
It's a contract as you can see. The difficsualt part is that the fees/charges changes every year according to "consumer price index". they only pay once a year.
Since the dates in the invoice table is a range it is difficault to compare it to what have been paid.
How can i solve that?
Here is the calculation:
(this years cpi)*fee/(cpi for the start.year)
So if start year is 1995 and the fee is 500 and i want to see what thr customet paid 1998 I Have to calculate it like (start years cpi)*fee/(CPI for 1998)
I want a query which shows all the years 1980-2012 with what was inoiced that specific year and compare it with what was paid.
Thanks a lot
I know how to do the price calculation (invoice table ) for todays year.
But i would like to do the price calculation for every year in the past too, and then compsre it with what my customers did paid. So i will get a history.
I have a table calles invoice:
Name start.year end.year fee
It's a contract as you can see. The difficsualt part is that the fees/charges changes every year according to "consumer price index". they only pay once a year.
Since the dates in the invoice table is a range it is difficault to compare it to what have been paid.
How can i solve that?
Here is the calculation:
(this years cpi)*fee/(cpi for the start.year)
So if start year is 1995 and the fee is 500 and i want to see what thr customet paid 1998 I Have to calculate it like (start years cpi)*fee/(CPI for 1998)
I want a query which shows all the years 1980-2012 with what was inoiced that specific year and compare it with what was paid.
Thanks a lot