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 have issue calculating the difference between different column values in same table. The result in a new created column is wrong.
My data input table is here:
My output result is:
But expected result is:
Seems wrong answers because 0.87!=-3289.13
So how solve this issue?
My query is here:
Seems something wrong with my query.
HI @Analitika,
You can try to use the following calculated column formulas if it helps:
column =
VAR NextDate =
CALCULATE (
MIN ( Table[Date] ),
FILTER (
Table,
[ID] = EARLIER ( Table[ID] )
&& [OBJ_ID] = EARLIER ( Table[OBJ_ID] )
&& [Date] > EARLIER ( Table[Date] )
)
)
VAR CRE =
CALCULATE (
MAX ( Table[CRE] ),
FILTER (
Table,
[ID] = EARLIER ( Table[ID] )
&& [OBJ_ID] = EARLIER ( Table[OBJ_ID] )
&& [Date] = NextDate
)
)
RETURN
IF ( [DEF] <> 0, CRE - [DET] )
Regards,
Xiaoxin Sheng
User | Count |
---|---|
25 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
30 | |
13 | |
11 | |
9 | |
6 |