Forum Discussion
Need help on this Formula
I been using PowerBI for awhile and I got stuck on this logic.
So basically i have two tables.
Table 1
| Item | Requirement |
| A | 200 |
| B | 150 |
| V | 150 |
| D | 200 |
| G | 350 |
| H | 69 |
Table 2
| Qty |
| 100 |
| 222 |
| 150 |
| 100 |
| 58 |
| 44 |
The goal is to sum Table 2 - which is 674 (sum of qty)
Then distribute those to Table 1 base on requirements from top to bottom.
so you see that item A got 200, Item B got 150 and so on, but on Item D it should only use 174 because the total QTY of table two is 674.
here's the desired outcome. the sum from answer column is 674 which should match the table 2 sum.
Hi Anonymous ,
Check this file: Download PBIX
If you consider it as a solution, please mark as a solution and kudos.
Ricardo
2 Replies
- camargos88Community Champion
Hi Anonymous ,
Check this file: Download PBIX
If you consider it as a solution, please mark as a solution and kudos.
Ricardo
- az38Community Champion
Hi Anonymous
How do you plan to rank values in your Table1? If it's alphabetic ranking, why V before D? If not - whats rule do define that A is first, B is second?