cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
erosales
Frequent Visitor

Is there a DAX function that will allow me to see if a value does not show up in a future period?

Hi All,

 

Hope someone can give me guidance on this Power BI problem I'm having. I need to be keep track of all increases and decreases in account support each month. Part of this is being able to see if a value appears in the succeeding month.

 

I have a table that looks like below:

 

Activity MonthEmployee IDClient NameEIDClientNameEmployee CountIn Succeeding Month?
Jul-21John DoeABCJohn DoeABC1No
Sep-21John DoeABCJohn DoeABC1Yes
Oct-21John DoeABCJohn DoeABC1No
Jul-21John DoeXYZJohn DoeXYZ1Yes
Aug-21John DoeXYZJohn DoeXYZ1Yes
Sep-21John DoeXYZJohn DoeXYZ1Yes
Oct-21John DoeXYZJohn DoeXYZ1Yes
Nov-21John DoeXYZJohn DoeXYZ1N/A

 

Is there a DAX function that will allow me to get the results similar to the 'In Succeeding Month?' column?

 

N/A in November is because the latest report date is Nov-2021 so there is no future month to refer to.

 

Thanks,
E

1 ACCEPTED SOLUTION
Aburar_123
Resolver II
Resolver II

Hi @erosales ,

 

Please find the below solution,

// Calculated column

Available_in_Succeeding_month =
var is_exists = COUNTROWS(FILTER(ALL('Table'),'Table'[Client Name]=EARLIER('Table'[Client Name]) && DATEDIFF(EARLIER('Table'[Activity Date]),'Table'[Activity Date],MONTH)=1))
return IF(is_exists=1,"Yes","No")
 
 
Aburar_123_0-1638349025620.png

 

 

Please like and mark my Post as a solution if it meets your expectation. Thank you.

View solution in original post

2 REPLIES 2
erosales
Frequent Visitor

I'm relatively new to Power BI and this problem has been racking my brain for the past few days. So your formula is such an immense help to me. Thank you!!!

Aburar_123
Resolver II
Resolver II

Hi @erosales ,

 

Please find the below solution,

// Calculated column

Available_in_Succeeding_month =
var is_exists = COUNTROWS(FILTER(ALL('Table'),'Table'[Client Name]=EARLIER('Table'[Client Name]) && DATEDIFF(EARLIER('Table'[Activity Date]),'Table'[Activity Date],MONTH)=1))
return IF(is_exists=1,"Yes","No")
 
 
Aburar_123_0-1638349025620.png

 

 

Please like and mark my Post as a solution if it meets your expectation. Thank you.

View solution in original post

Helpful resources

Announcements
Power BI December 2021 Update_carousel 768x460.jpg

Check it Out!

Click here to read more about the December 2021 Updates!

Jan 2022 Dev Camp 768x460 copy.png

Power BI Dev Camp- January 27th, 2022

Mark your calendars and join us for our next Power BI Dev Camp!

UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Top Solution Authors
Top Kudoed Authors