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!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello
I would like to get a different result depending on 2 columns:
Sales Last Year
Sales Current Year
if current year sales are 0 I classify this as "Discontinued" and I would like to have a column displaying that in a table.
I have achieved this with Dax with no problem BUT check the total row, it displays Zero, and I would like to have the sum of the column "Sum if CY is 0", e.g. -3, -2, -1, -2-
I understand that the measure I am using will not apply in total because the Sales CY in total is not 0; but I don't know how to sum the rows.
Thanks in advance for your time and attention.
Solved! Go to Solution.
Hi, @JNMx
To change the wrong total, please try measure as below:
Measure =
SUMX ( VALUES ( Table[Item] ), [Sum IF CY is 0] )
Best Regards,
Community Support Team _ Eason
Hello:
You can add a calculated column to your table. I'm calling the table "Data". It just has a bit of conditional logic.
Then a measure to sum up the negatives only. Please see below. I hope this helps!
Unfortunately those aren't physical columns, those are measures, that's the difficulty.
Hi, @JNMx
To change the wrong total, please try measure as below:
Measure =
SUMX ( VALUES ( Table[Item] ), [Sum IF CY is 0] )
Best Regards,
Community Support Team _ Eason
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 9 | |
| 5 | |
| 4 |
| User | Count |
|---|---|
| 27 | |
| 22 | |
| 20 | |
| 17 | |
| 12 |