Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Hello,
I am trying to implement difference calculation. Here is my data table:
My expected result is here:
But I am getting this output which is wrong:
0.87!=3289.13
Below is DAX query:
Column =
VAR _0 = MAXX(FILTER('x','x'[date]<EARLIER('x'[date]) && 'x'[ID]= EARLIER('x'[ID])),[date])
VAR _1 = MAXX(FILTER('x','x'[date] =_0 && 'x'[ID]= EARLIER('x'[ID]) ),[cre])
return
if('x'[deb] <> 0,_1 - 'x'[deb], blank(
Solved! Go to Solution.
Hi @Analitika ,
Please try:
Column =
VAR _0 = MAXX(FILTER('x', 'x'[ID]= EARLIER('x'[ID])),[date])
VAR _1 = MAXX(FILTER('x','x'[date] =_0 && 'x'[ID]= EARLIER('x'[ID]) ),[CRE])
return
if('x'[DET] <> 0,_1 - 'x'[DET],BLANK())
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Analitika ,
Please try:
Column =
VAR _0 = MAXX(FILTER('x', 'x'[ID]= EARLIER('x'[ID])),[date])
VAR _1 = MAXX(FILTER('x','x'[date] =_0 && 'x'[ID]= EARLIER('x'[ID]) ),[CRE])
return
if('x'[DET] <> 0,_1 - 'x'[DET],BLANK())
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 83 | |
| 48 | |
| 36 | |
| 31 | |
| 29 |