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.
Hey everyone, I'm a newer user, who's been doing lots of training, and have learned a lot, but am currently struggling with an employee count calculation I'm working on right now. I think I've seen posts that I can't seem to find that basically amount to a nested if statement that performance various calculations depending on the circumstance or hierarchy. However, I'm completely open to any solution that best solves this.
So the goal of this dashboard is to provide accurate PEPM (Per Employee Per Month) based on various products and subscriptions. Usage can vary by the employee within the organization however, below are a few issues I'm encountering (sorry if this is too much detail):
Please let me know if I can answer any questions to help get this solution, or attach anything else. In the excel screenshot and file, I've highlighted in Green where I'm performing the correct calculation in BI, and red where it's not calculating correctly.
Thanks!
Hello again,
I've been tinkering with the previous formula, and I was able to solve for that previous post (hierarchy 3) by creating a table within BI that sums the solution to a single number to prevent the weighted average from diluting. I now have a new table (which I'll attach as a reference in the update power bi file).
I am now trying to solve for the final three levels of my matrix, and was hoping to get some assistance. Here are screenshots of my BI dashboard, the current DAX measure, and what it should look like in excel with an explanation of the function I'm attempting to perform at each level. In the power BI screen shot, I left my old columns as a reference to my previous posts, but the only three columns that would be final would be the EE Calc2, the TTL BU SUM ARR, and the BU PM SUM PEPM2.
As stated in my excel, for Account level, I'm attempting to do a weighted average of my hierachy 3 calculation (the next hierarchy down. So Customer 1 should be a weighted average of 4000 HCM and 4000 time (note that in Time, there are two pieces an Hourly and a Salaried piece - which is why I've been currently struggling to get the calculation to work). After Account, is Hierarchy 2, which is HCM/Time & Add-On - that needs to be a SUM of the customer/account level data. So Customer 1 will be 4000 + Customer 5 of 2300, totaling 6200. Lastly, the EE Band will be a weighted average of Hierarchy 2, so a weighted average based on ARR of 6200 (HCM/Time) and 6138 (add-on).
Even if someone could point me in the direction of formulas/functions I could use to help tackle these calculations I'd appreciate it - I'm very happy to do most of the leg work, but I'm struggling to find other relevant examples to draw from to help solve these calculations.
BI file as a reference:
Hi @Muffin ,
Do you want to calculate by different logics in different hierarchy in Power BI ?Here I suggest you to try
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ISINSCOPE() definitely helps, I can use it to fix the lowest level (the field name/Product). I was having trouble calculating the next level up, Hierarchy 3. I've attached a screenshot of the current calculation and issue (FYI, I attached screenshots of my desired calculation and excel and power bi files in the original post if it helps). Is there a way to get a weighted average where essentally, you aggregate at the Product (Field Name/Solution Key) level before iterating through the Employee Count * Revenue? I attempted to do this through an allselected - knowing this wouldn't be the correct math, since I was assuming it would overlay 15,000 for all EE counts instead of the sum at the product level, but that still didn't calculate as I thought it would. There is also a screenshot from my excel of how I'd ideally like it to calculate to get a value of 3,785.
From Excel:
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 |
---|---|
114 | |
100 | |
81 | |
70 | |
62 |
User | Count |
---|---|
148 | |
116 | |
104 | |
90 | |
65 |