Here is a dummy dataset to illustrate my question:
<colgroup><col><col><col></colgroup><tbody>
</tbody>
I am wondering if it is possible to write measures that would enable me to count how many clients in one month have paid more / less / the same compared to the previous month.
The resulting pivot from the above would look as follows:
<colgroup><col><col><col><col></colgroup><tbody>
</tbody>
If anyone could advise how to write the measure for the "higher" example, this would be much appreciated.
(In this example, each client makes just one payment per month. I would also like to understand how the measure would need to be adapted if clients made several payments per month i.e. if I need to compare the sum of payments in two months).
Thank you in advance!
Client_Ref | Start_of_Payment Month | Payment_Amount |
101 | 01/01/2018 | 20 |
101 | 01/02/2018 | 20 |
101 | 01/03/2018 | 25 |
102 | 01/01/2018 | 15 |
102 | 01/02/2018 | 25 |
102 | 01/03/2018 | 10 |
<colgroup><col><col><col></colgroup><tbody>
</tbody>
I am wondering if it is possible to write measures that would enable me to count how many clients in one month have paid more / less / the same compared to the previous month.
The resulting pivot from the above would look as follows:
No of Clients with Payment Higher than Previous Month | No of Clients with Payment Lower than Previous Month | No of Clients with Payment Same as Previous Month | |
01/02/2018 | 1 | 1 | |
01/03/2018 | 1 | 1 |
<colgroup><col><col><col><col></colgroup><tbody>
</tbody>
If anyone could advise how to write the measure for the "higher" example, this would be much appreciated.
(In this example, each client makes just one payment per month. I would also like to understand how the measure would need to be adapted if clients made several payments per month i.e. if I need to compare the sum of payments in two months).
Thank you in advance!