Forum Discussion

JarnoVisser's avatar
JarnoVisser
Icon for Helper I rankHelper I
7 years ago

Calculate donor loyalty

Hi,

 

I need to calculate the loyalty of donors. So when a donor gives a donation for the first time he is active for that year. When he gives the next year again he is still active and so on. When he is not giving in a year he becomes inactive. When he gives the year thereafter again he starts to be active again.

My data is like:

DonorIDDateAmount
1001-2-2016100
1001-2-2017100
1001-2-2018100
1011-1-2015100
1011-1-2017100
1011-1-2018100

 

The outcome should be:

Inflowactive Year 1 active year 2active year 3
2015100
2016111
2017110
2018000

 

Thanks in advance!


Regards,

Jarno 

 

1 Reply