Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
NickIT91
Frequent Visitor

Summing total number of true vales per month, based on no. months filtered

Hi all,

 

I have a table that returns true for each month a client is active or inactive in a given month/period (if a value of true is not returned, then the client has dropped off completely). 

 

NickIT91_0-1614641162492.png

 

Is there a DAX formula where I can sum up the number times a value of true has been returned. E.g. if looking at the first 6 months of 2020, and a client has True appear 6 times, it will show 6 if the year 2020 is filtered

 

Many thanks

1 REPLY 1
amitchandak
Super User
Super User

@NickIT91 , with the client this will 1 active for 6 months

 

Rolling 6= if(CALCULATE(sumX(values('Date'[Month year]),if([Active],1,0)),DATESINPERIOD('Date'[Date ],MAX('Date'[Date ]),-6,MONTH)) =6, 1,0)

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors