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,
I'm doing a quick measure to divide 2 columns without doing any calculation on the denominator column.
So here's the scenario: The numerator column(lesson count) does a count of lessons and i have a criteria for each school. I entered the criteria(required lesson) by creating a table in powerbi and joining by school in the relationships tab. The issue is that when i try to divide lesson count(i did a count distinct on this column which is what i wanted) by required lesson, it forces me want to use some form of aggregation(sum, count, standard deviation, etc) to the required lesson column which is not want i want. I just want to divide lesson count/required lesson without the aggregation to the denominator. Is there a dax that does this perfectly? I've looked at some post but the answers i see is not working for me.
Please help.
Solved! Go to Solution.
@oriabbhou1 try the following
% Completion = DIVIDE('Lessons(SQL Table)'[Count of Lesson],RELATED('Lesson Required Table'[Lesson Required]))
I've added a PBIX file to this one drive link that shows how I achieved it for you.
@oriabbhou1 try the following
% Completion = DIVIDE('Lessons(SQL Table)'[Count of Lesson],RELATED('Lesson Required Table'[Lesson Required]))
I've added a PBIX file to this one drive link that shows how I achieved it for you.
This worked Perfect. Thanks soo much @Anonymous
Hey @oriabbhou1 ,
Can you share a sample of the data you're working with and your desired results, please?
Karlos.
Hey @oriabbhou1
I'd Suggest you to create a Calculated column for your solution
column=divide(table[LessonCount],table[RequiredLesson],0)
if you dont want to use above solution can you please share some sample data
Did I answer your question? If Yes, Please mark this as a solution
Best Regards
Jay Patel
iXpert Analytics
Hi @iXpert_info & @Anonymous ,
I tried creating a calulated column but the required lessons column from the lessons required table is not popping up as the denominator.
Both columns are whole numbers so i dont see why it shouldnt work. I'm pretty much trying to accomplish the % completion colum in the sample data below.
Here's my sample data below:
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 |
---|---|
47 | |
24 | |
20 | |
15 | |
13 |
User | Count |
---|---|
55 | |
48 | |
43 | |
19 | |
19 |