March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi
I have 2 columns that i would like to subtract from one another after applied filters.
Eg.
Column B (with version type x and month number x) - Column A (with version type x and month number x)
What I currently have and is giving me wrong answer:
How do I go about writing this dax?
Hi @EMSSS22
Are version type and month number from the same table or different tables? What are the relationship between the tables? When you refer to "x" is it the same value used to filter both columns?
Hi
Yes its the same table.
and
Yes the same filter needs to be applied to both columns.
Thanks 🙂
Apologies for the late reply. Please try
ForecastCMVariance =
SUMX (
FILTER ( Commercial, Commercial[Version] = "x" && Commercial[month number] = y ),
Commercial[Forecast] - Commercial[Capital Rental]
)
Try something like
ForecastCMVariance =
CALCULATE (
SUMX (
FilteredCommercial,
FilteredCommercial[Forecast] - FilteredCommercial[Capital Rental]
),
FilteredCommercial[Version] = "x",
FilteredCommercial[month number] = y
)
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
22 | |
19 | |
16 | |
9 | |
5 |
User | Count |
---|---|
37 | |
28 | |
16 | |
14 | |
12 |