Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello, I am looking to create a formula that calculates a sum for certain attributes in a list of attributes based on whether or not I have selected those attributes in a slicer. I want a different result depending on whether they are selected or not. If they are selected, I want the sum of their values. If they are not selected, I want the values to be 0 for each attribute. If they are not selected, I still want them to appear in my result table, so I need to remove the interaction so that the slicer does not filter my result table. I want all attributes to appear in my result table, even those that are not selected, but with a value of 0 for those that are not selected. There are 100 attributes in the list, so I should not name them in my formula. There are sometimes multiple values for each attribute, so the sum needs to be calculated.
@JimmyCruyp
In this case the Attribute slicer has to come from a dim table. Just create a dim table with all unique attributes and connect it to the main table then use the column from the dim table in the slicer. It should work if add (+ 0) to your measure.
I would like to find a solution without creating an additional table if possible?
No it is not possible. Try this:
Proud to be a Super User!
Thanks, I tried this but only one table and it doesnt work. So there is no solution to do that without creating an additonal column?
No, because you want the filter the column and also modify the filter context. This is not possible.
Proud to be a Super User!
Can you please make a good data example with the underlaying data how with 1-2 different slicer value and how it should look like? Thank you 🙂
Proud to be a Super User!
For example if I filter in a slicer on attribut B and E (if I select only these attributes in my slicer)
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
26 | |
10 | |
10 | |
9 | |
6 |