Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Looking to get count of ex-members (using their TIN in TIN column) from last 24 months based on MembershipEndDate.
Solved! Go to Solution.
Hi @tzaveri,
Here is the measure formula that can get rolling 2 year records and get distinct member count, you can try it if it suitable for your requirement.
formula =
VAR currDate =
MAX ( Table1[MembershipEndDate] )
RETURN
CALCULATE (
COUNTROWS ( VALUES ( Table1[TIN] ) ),
FILTER (
ALLSELECTED ( Table1 ),
[MembershipEndDate]
>= DATE ( YEAR ( currDate ) - 2, MONTH ( currDate ), DAY ( currDate )
&& [MembershipEndDate] <= currDate )
)
)
Regards,
Xiaoxin Sheng
Hi @tzaveri,
Here is the measure formula that can get rolling 2 year records and get distinct member count, you can try it if it suitable for your requirement.
formula =
VAR currDate =
MAX ( Table1[MembershipEndDate] )
RETURN
CALCULATE (
COUNTROWS ( VALUES ( Table1[TIN] ) ),
FILTER (
ALLSELECTED ( Table1 ),
[MembershipEndDate]
>= DATE ( YEAR ( currDate ) - 2, MONTH ( currDate ), DAY ( currDate )
&& [MembershipEndDate] <= currDate )
)
)
Regards,
Xiaoxin Sheng