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.
Hi there,
My first post! Fairly new to Power BI. I think this is an issue with how I've setup my query, but here goes.
I have two tables linked via an ID. One containing Student details and one attendance data. It's a one-many relationship.
I have created two calculated columns in the attdnance table that result in columns of ones and zeros, which is working fine.
I have created a measure that divides the sum of one columns ones by the other columns ones to give a % and this works too.
The final step in my measure is a condition that returns a one or zero if a value is below 90.
Welcome to the world of PowerBI 😀. One of the first problem Excel migrants face is the same one you are facing (the totals don't add up or aren't correct). The totals in PowerBI don't work as you might think. In your case, when the formula comes to the total part of the table it considers the 9 and the 6 (the totals of the first two columns as per your snippet) and evaulates the formula based on these two values which is why you are probably always getting "0". There is a number of way to add these numbers and without knowing your exact data model / end goals I cannot suggest the best one but one method would be to use an aggregator function such as SUMX (see below) and drag it into the table and see if the correct result shows up in the total (again this may not be correct becase I do not know the table structure for the attendance table)
PA Puplis Total = SUMX (attendance, [PU Pupils])
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
43 | |
22 | |
21 | |
16 | |
15 |
User | Count |
---|---|
46 | |
31 | |
29 | |
18 | |
18 |