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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

show value for one month for different year power bi dax

Hello, 

 

I'm working on a dax and I would regroup two measures in one to use it on a matrix table in order to display them in the following format : 

Capture14.PNG

 

The measures that I'm using are : 

 

Nbp = CALCULATE(SUM('Forecast'[Nje]))
Nbpre = CALCULATE(SUM('Time_records'[Nb Hours])/8))


So the purpose of regrouping these to measures is to show the results, for example, in January 2020 the Nbp measure will appear and in January 2021 Nbpre will appear as I show in the figure above. 
I tried to show it on the matrix table but I can't find the results! 

 

Capture13.PNG

Do you have any ideas? Any tips? 

Thank you in advance

Regards, 

 

1 REPLY 1
lbendlin
Super User
Super User

You are overcomplicating things.

 

- merge your measures into one measure that calculates differently based on the year.

- add a sort column to your dates table that allows you to sort the yearmonth column according to your display needs  and then wire it in via "sort by other column"

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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

Top Kudoed Authors