Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
I am fairly new to Power BI and only know basic programming, so I might have missed the solution in my searches.
I will try to explain the best I can...
I am creating a bubble chart to analyze sales metrics and I want to size each bubble relative to Profits and order type.
Currently it sums all profits no matter order type. As seen in the picture below, the bubbles for customer ID "15760" are the same size as they both sum the collective profits for that customer.
Edit: The customer 15760 has previously purchased by two different order types, and I want to size the bubble by each respective profit. Currently, they are the same size because it sums the customers collective profits. Not the profits by order type.
The following code works, but only for one order type and I need it to sort for each order type.
I have been experimenting with IF/ELSE statements, but have not succeeded.
Profits by Order type =
CALCULATE(
SUM('EarningsTable'[Profits]),
'EarningsTable'[OrderType] = { "Order type 1" }
)
Each tables EarningsTable[] looks like the following:
| Customer ID | Order no. | Order type | Profits |
| 15760 | Order 1 | TRX | X |
| 15760 | Order 2 | R18 | Y |
| 15760 | Order 3 | R18 | Z |
| 17894 | Order 4 | SAT | K |
Table relationships are by Customer ID (Kund or Kundnr)
Expected results:
I believe this is all, thank you in advance!
Solved! Go to Solution.
Hello again,
I believe I have solved it.
I took out another Excel from our ERP with that summerized the total Cost for each Order No. and Order Type, set the Relation between Order No.
So far, it seems to be correct.
Hello again,
I believe I have solved it.
I took out another Excel from our ERP with that summerized the total Cost for each Order No. and Order Type, set the Relation between Order No.
So far, it seems to be correct.
@Anonymous , You are using order type as legend, why are you using order type filter in measure
Profits by Order type =
CALCULATE(
SUM('EarningsTable'[Profits])
)
Yes, because customers can purchase from all order types and I need to see the profits of each order type.
If I use 'EarningsTable'[Profits] it displays the same earnings for each bubble. I believe this is because it sums all profits for that Customer. I want it to be sorted by Customers and Order Type.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 63 | |
| 55 | |
| 42 | |
| 41 | |
| 23 |
| User | Count |
|---|---|
| 171 | |
| 136 | |
| 119 | |
| 79 | |
| 54 |