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.
Hello, I have a column "Open" that lists the number of open positions and a column "Name" that I would like to have a total count of. The math formula would look like this. Open/Name*100=__%. I've set it up to work in Excel, but not sure how to enter it in power query since there are multiple calculations. Is it best to build from a blank query or advanced editor? Current status: Table.RowCount(Query 1) Any help would be appreciated. Thank you!
Solved! Go to Solution.
Hi @Anonymous ,
You can use this code:
[Open] / List.Count(#"Changed Type"[Name])
This DAX solution would be better to handle it:
@Anonymous ,
You are inputing a DAX language in Power Query.
Try importing the table and try it creating measure.
Take a look at this file: Download PBIX
This example only has DAX code, let me know if you still need to do it using Power Query.
Ricardo,
Thank you. The synax worked, but it produced an error in the cell stating that it can't find column [Open]. I merged it as a query from another source, so the top is listed as [1.2 Open]. Would that change the formula?
Thank you!
Derek
Here you go. Ultimately I'll need two different final values. If I can just get one to work I want to continue learning and figure out the other one. Thank you!
% Open against Total Names (Open/(Name)*100 = __%
and
% Open against Total Name and Open (Open/(Name+Open))*100 = __%
There are (7) names, let's call them Employees and there are (3) Open positions. So out of a total of (10) positions, the company is 70% staffed.
Open / (Active+Open) = % Staffed
Does that help?
Hi @Anonymous ,
You can use this code:
[Open] / List.Count(#"Changed Type"[Name])
This DAX solution would be better to handle it:
Ricardo,
I changed the table name and here is what I'm getting back. I've played around with it a few different ways, but have been unable to get rid of the error. Any thoughts?
@Anonymous ,
You are inputing a DAX language in Power Query.
Try importing the table and try it creating measure.
Take a look at this file: Download PBIX
This example only has DAX code, let me know if you still need to do it using Power Query.
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.