Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi,
I'm stuck and hope to get some help from the Power BI community...
Let me please paint the picture..:
In Power BI I've created a PriceTable with a PriceScale, something like this:
Brand | Min | Max | PPS |
Thingy_1_UK | 1 | 25 | 25 |
Thingy_1_UK | 26 | 50 | 24 |
Thingy_1_UK | 51 | 75 | 22 |
Thingy_1_UK | 76 | 1000 | 20 |
Thingy_1_US | 1 | 25 | 30 |
Thingy_1_US | 26 | 50 | 28 |
Thingy_1_US | 51 | 75 | 26 |
Thingy_1_US | 76 | 100 | 24 |
Thingy_1_US | 101 | 1000 | 22 |
Thingy_1_Rest | 1 | 25 | 20 |
Thingy_1_Rest | 26 | 50 | 18 |
Thingy_1_Rest | 50 | 1000 | 15 |
I'm looking for a way to (preferably in a Matrix visual) calculate the Total Amount based on the total sum of #Sales per Geographic and the corresponding PPS in the PriceTable, something like this:
Geographic | #Sales | Total Amount | Calculation | |
United Kingdom | 27 | 648 | (27*24) | |
United States | 16 | 480 | (16*30) | |
Rest of the World | 75 | 1125 | (75*15) |
Any ideas are welcome...
Thanks a lot in advance...
Solved! Go to Solution.
@Anonymous this is what I will do and it will show the total value correctly, add a measure:
Total Amount =
SUMX (
SUMMARIZE (
Sales,
Sales[Brand],
"@Sales",
VAR __sales = CALCULATE ( SUM ( Sales[#Sales] ) ) //get the brand sales
RETURN
__sales * //multiply the brand sales with PPS base on the sales
CALCULATE(
MAX ( PriceRanges[PPS] ),
TREATAS ( VALUES ( Sales[Brand] ), PriceRanges[Brand] ),
__sales >= PriceRanges[Min],
__sales <= PriceRanges[Max]
) //this calculate logice gets the PPS based on the sale
),
[@Sales] //sum sale after the calculation
)
✨ Follow us on LinkedIn
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Hi,
Share the link from where i can download your PBI file.
@Anonymous this is what I will do and it will show the total value correctly, add a measure:
Total Amount =
SUMX (
SUMMARIZE (
Sales,
Sales[Brand],
"@Sales",
VAR __sales = CALCULATE ( SUM ( Sales[#Sales] ) ) //get the brand sales
RETURN
__sales * //multiply the brand sales with PPS base on the sales
CALCULATE(
MAX ( PriceRanges[PPS] ),
TREATAS ( VALUES ( Sales[Brand] ), PriceRanges[Brand] ),
__sales >= PriceRanges[Min],
__sales <= PriceRanges[Max]
) //this calculate logice gets the PPS based on the sale
),
[@Sales] //sum sale after the calculation
)
✨ Follow us on LinkedIn
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
116 | |
82 | |
47 | |
42 | |
31 |
User | Count |
---|---|
186 | |
80 | |
72 | |
48 | |
45 |