I need to ask for your help again!
(please see attachment)
I have to find a proper way how to flag a Customer Account with 90+ day past due balance.
“The Flag” should be applied to each Customer invoice, even if it’s not due, but Custmer account does.
And one more exception :“The Flag” filter should be applied to each individual file in the column [Source.Name].
It should be something like that:
-Apply “The Flag” rule into each individual file in [Source.Name]
Mark with “The Flag” rule Customer’s transactions if one of them labeled “Over 90” in [Aging Bucket]
-If Customer doesn’t have records labeled “Over 90” in [Aging Bucket] mark as “Other”.
I’ve added a Calculated Column because you didn’t supply data files. However imo you should translate this logic to Power Query/M to achieve the same result.
Flag (CC) =
VAR cCust = 'GP_ AR Aging'[Customer Number]
VAR cFile = 'GP_ AR Aging'[Source.Name]
VAR t =
COUNTROWS(
FILTER( 'GP_ AR Aging',
'GP_ AR Aging'[Customer Number] = cCust &&
'GP_ AR Aging'[Source.Name] = cFile &&
'GP_ AR Aging'[Aging Bucket] = "Over 90"
)
)
RETURN
IF( t > 0,
"Flag",
"Other"
)