This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hi,
1. This is some dummy data I created in excel but my query returns something similar to this kind of scenario
2. Transform Data > Select Fruit Column > Pivot Column > Values Column (Quantity) > Aggregate Function (Sum).It creates something like this below
3. Now I need to create another column that adds all the quantities related to melons category. For ex sometimes the query may return only Watermelon and Muskmelon and sometimes maybe just Honeydew melon and sometimes maybe Honeydew and Muskmelon. How to create total column by checking if a column exists and then add? However I know for sure the query returns only four fruits related to melons (i.e they are hardcoded)
Hi,
Your first table was in the best structure. Why have you pivoted the data in the Query Editor?
Checking to see if what I am trying to achieve here is clear or not. I can reframe the requirement if it is not clear.
Hi,
I do not know how to solve this question in your revised structure.
Hi,
My end user requires it that way.
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 25 | |
| 24 | |
| 22 | |
| 20 | |
| 19 |
| User | Count |
|---|---|
| 51 | |
| 48 | |
| 44 | |
| 21 | |
| 21 |