I need a select statement that calculates when someone's membership is new, continuing or a lapsed membership per term
Example of one person in the table:
Table:
term person_id type
1078 1 New Member Status: First term they purchased a membership
1084 1 Continuing Status
1086 1 Continuing Status
1088 1 Continuing Status
1094 1 Lapsed Status: Membership expired in 1088 and did not renew (only want to count the person as lapsed for this term since it is the next term after their membership expired)
1096 Don't want to count: Do not want to count since this isn't the next term after the membership expired
1098 Don't want to count: Do not want to count since this isn't the next term after the membership expired
1104 1 Continuing Status: They renewed their membership this term
1106 1 Continuing Status
1108 1 Continuing Status
1114 1 Lapsed Status Again:
1116 Don't want to count: Do not want to count since this isn't the next term after the membership expired again
I hope I have provided all of the data needed.
Help is appreciated.
Thanks
Example of one person in the table:
Table:
term person_id type
1078 1 New Member Status: First term they purchased a membership
1084 1 Continuing Status
1086 1 Continuing Status
1088 1 Continuing Status
1094 1 Lapsed Status: Membership expired in 1088 and did not renew (only want to count the person as lapsed for this term since it is the next term after their membership expired)
1096 Don't want to count: Do not want to count since this isn't the next term after the membership expired
1098 Don't want to count: Do not want to count since this isn't the next term after the membership expired
1104 1 Continuing Status: They renewed their membership this term
1106 1 Continuing Status
1108 1 Continuing Status
1114 1 Lapsed Status Again:
1116 Don't want to count: Do not want to count since this isn't the next term after the membership expired again
I hope I have provided all of the data needed.
Help is appreciated.
Thanks