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.
Hi.
I just wanted to know whether using CALCULATE and DAX, can we create a measure such that a specific column value is ignored.
I have a table called 'Environment Name' and "Quantitiy'.
Environment Table contains names as 'Air','Water' and 'Land'.
I want to create 3 measures each for Air, Water and Land such that the first measure(Air) can have just the values from Water and Land and vice versa.
I have tried doing the same using two DAX queries, but I am not getting a s atisfactory solution.
2 ways which I used to write the query is given below;
1)No Air = CALCULATE(SUM(Purchase[Quantity]),VALUES(Environment[EnvironmentName])<>"Air")
Solved! Go to Solution.
@SanketBhagwat , Try like
CALCULATE(SUM(Purchase[Quantity]),filter(Environment, Environment[EnvironmentName]<>"Air"))
assuming slicer is no filtering the value
else
CALCULATE(SUM(Purchase[Quantity]),filter(all(Environment), Environment[EnvironmentName]<>"Air"))
or
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
if needed check
Need of an Independent Table in Power BI: https://youtu.be/lOEW-YUrAbE
@SanketBhagwat , Try like
CALCULATE(SUM(Purchase[Quantity]),filter(Environment, Environment[EnvironmentName]<>"Air"))
assuming slicer is no filtering the value
else
CALCULATE(SUM(Purchase[Quantity]),filter(all(Environment), Environment[EnvironmentName]<>"Air"))
or
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
if needed check
Need of an Independent Table in Power BI: https://youtu.be/lOEW-YUrAbE
Hi Amit.
The query
'CALCULATE(SUM(Purchase[Quantity]),filter(Environment, Environment[EnvironmentName]<>"Air"))' worked perfectly fine.
Thanks for the help!
Regards,
Sanket Bhagwat
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
23 | |
8 | |
7 | |
6 | |
6 |
User | Count |
---|---|
28 | |
12 | |
10 | |
10 | |
6 |