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
ChrisC33
New Member

Running total / cumulative count - problem adding legend

Hey community,

 

it is my first request for help. Since being very new to Power Bi I was trying to help myself and searched for solutions in the community. But unfortuetly I haven't found any solution yet.

 

Objective:

I want to show lines for each production year (legend).

Values of the lines are running total of parts [Parts] (y-axis) over month in service [MIS] (x-axis).

 

I used an addtional measure as values


Running Total = CALCULATE(COUNT(Table[Parts]); FILTER(ALLSELECTED(Table[MIS]); Table[MIS]<=MAX(Table[MIS])))

 

Problem:

It works without adding production year to legend. Then I have one line combining all production years. If I add it to legend, I get multiple lines which increase and drop 😞

 

I tried to check  "show items with no data" - it doesn't help.

 

Thank you

Chris

1 REPLY 1
kcantor
Community Champion
Community Champion

@ChrisC33 

Do you have a seperate date table that you are using to populate the years or are you populating the years from the fact table?

A good rule of thumb is to create measures and use value from the fact table and to populate rows and axis from the lookup/dimension table.






Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




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.