Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Customers with 0 usage, Last 'x' months

Hi all,   I am looking to create a formula that counts (or flags) the number of customers that have had 0 usage within the last x months (where x can be changed if needed - for this example let x =...
  • Anonymous's avatar
    Anonymous
    6 years ago

    Thank you both.  I think I have got the answer.

     

    Using Greg_Deckler's solution as the starting point and an idea from amitchandak., I have the following, which gives me the expected result.

     

    GregSolution =
    VAR __Table =
    SUMMARIZE(
    FILTER('Phone Usage','Phone Usage'[Date]<=DATE(2020,5,1) && [Date]>=EOMONTH(DATE(2020,5,1),-2)+1),
    [Customer],
    "__Usage",SUM([Usage]), "months", COUNTROWS('Phone Usage')
    )
    RETURN
    COUNTROWS(FILTER(__Table,[__Usage]=0 && [months] = 3))
     
    Really appreciate the help from you both