I have a data model with a Sales fact file and Date table and am trying to calculate, for each customer by month, what are the last year sales where the customer has been lost? Lost is defined as where there has been no sale for 3 months past the last order date.
So my formula is
But this just gives me blank for everything. Not sure what the issue is?
So my formula is
Code:
=
CALCULATE (
CALCULATE ( SUM ( Sales[Net Revenue] ), SAMEPERIODLASTYEAR ( 'Date'[Period] ) ),
FILTER (
Sales,
MIN ( 'Date'[Period] )
> CALCULATE ( EDATE ( MAX ( Sales[Period] ), 3 ), ALL ( 'Date' ) )
)
)
But this just gives me blank for everything. Not sure what the issue is?