Forum Discussion
Anonymous
5 years agoNot applicable
Flag Occurrences after specific date
Hello, I Have created some dummy data to simulate a problem I'm trying to solve in Power BI Desktop: I am trying to create a column which flags "TRUE" every time a customer orders a...
- Anonymous5 years ago
Hi Anonymous ,
Based on your description, you can create a calculated column as follows.
Column = VAR x1 = SUMMARIZE ( FILTER ( ALL ( 'Orders' ), [item Name ] = "Apple" ), [Customer Name ] ) RETURN IF ( [Customer Name ] IN x1 && [item Name ] <> "Apple" && [Order ID ] > MINX ( FILTER ( ALL ( 'Orders' ), [Customer ID ] = EARLIER ( Orders[Customer ID ] ) ), [Order ID ] ), "True" )Result:
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
5 years agoNot applicable
Hi Anonymous ,
Based on your description, you can create a calculated column as follows.
Column =
VAR x1 =
SUMMARIZE (
FILTER ( ALL ( 'Orders' ), [item Name ] = "Apple" ),
[Customer Name ]
)
RETURN
IF (
[Customer Name ]
IN x1
&& [item Name ] <> "Apple"
&& [Order ID ]
> MINX (
FILTER ( ALL ( 'Orders' ), [Customer ID ] = EARLIER ( Orders[Customer ID ] ) ),
[Order ID ]
),
"True"
)
Result:
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.