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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
adieball
Helper I
Helper I

Calculate Dynamic Rolloing Total Based on Slicer

Hi all

 

I have two tables

Training: contains name, email address, country and data relevant to whether a person has taken the training, exam, etc

AllStaff: contains name, email address, country and department of ALL users

 

That means, the Table "training" does not contain all possible users, only those who have registered for the training, participated, taken the exam, etc)

 

I then created a relationship between the two tables based on "email address"

 

From Table "Training" I have a slicer which is using the "country" field.

From Table "AllStaff" I have a Card which should show the count of email from "All Staff" based on slicer value

 

When no country is chosen, the card shows the correct value, but when I chose a country I get a value which is unclear to me.

E.g. I choose Germany

The number of entries in "Training" having country set to Germany is 46

The number of lines from "AllStaff" having country set as Germany is 125

But the card shows 36

 

Same is true when I choose different countries.

 

This is just a first step. Finally I want cards that show the percentage of total users from a country and given department that have already taken the training or passed the exam, but the first simple count doesn't work.

 

I'm sure I'm just overseeing soimething very obvious.

 

Any help is appreciated.

2 REPLIES 2
Anonymous
Not applicable

Hi,

 

Based on what you have written, I have not understood the reason behind creating the "Country" slicer based on "Training" table. Because "AllStaff" is likely to have unique values. But in Training table, If one staff had opted for multiple training, exams etc..., this table will likely to have multiple entries per staff.

 

Therefore, assuming that you have created the relationships correctly between these two tables and if there are 125 Staffs from Germany and out of which 36 of them had participated in any training or exams, but some of the staffs have taken more than one training / exam because of which the Training table shows 46 entries. In this scenario, choosing the "Germany" will not give 36 as a the result because it is the number of unique Staffs in Training table for which master is available in the "AllStaff" table.

 

If you want 46 as the result, then you must link the card to Training table so that it will count the duplicate entries also. If you want number of unique users from Germany who wave participated in training or exam, then you have to link the card to "AllStaff" table. 

 

The choice is up to you. I don't see any other reason for the unintended output.

 

Hi

 

"Training" has one unique entry per employee, so does "AllStaff"

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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