The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I have been asked to do a day and occurrence count, the only tricky thing about it is that it needs to look at a certain hierarchy it is the follwoing:
Manual black > manual red > model black > model red
So the highest hieararchy is manual black. Each one of them is a measure calculated in percentage of time. I'll create a table to hopefully give enough example data:
Location | Manual Black | Model Black | Manual Red | Model Red | Green |
ABC | 4% | 40% | 56% | ||
DEF | 1% | 4% | 10% | 5% | 80% |
GHI | 51% | 10% | 39% | ||
JKL | 1% | 60% | 39% |
So, per the requirements, there should be the following in the counts:
2 days with manual black
1 day with manual red
1 day with model black.
To my understanding, an IF or SWITCH function may work, though how can I apply that to a hierarchy?
Hi @AmazingRandom ,
So, per the requirements, there should be the following in the counts:
2 days with manual black
1 day with manual red
1 day with model black.
It would be helpful if you could elaborate on the computational logic behind these results, thanks.
How to Get Your Question Answered Quickly - Microsoft Fabric Community
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
I'm not sure I understand your question. The results are just an example. I asume you meant how they are calculated.
They are calculated by a Divide formula, where it gets values from three columns. An overflow column, which says if it is overflown (automatic black) or green.
A manual status column, whether it is defined as red manual, black manual or none (green).
Then a system model where it will show if it is a predicted red or green.
Then the measures divide the instances on each based the number of rows by the total rows, some conditions are applied to avoid overlapping and match the hierarchy.
I hope I made sense to you explaining it
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
81 | |
75 | |
52 | |
48 |
User | Count |
---|---|
134 | |
124 | |
78 | |
64 | |
63 |