Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Sales Data analisys

I need to create a Dashboard that shows the status of the clients: Recurring, Inactive for 6 months, or Inactive for 12 months.

The problem is, I have tho analyse the sales monthly, so I can map if we have new clients or if someone reactivated.

 

I got a column bringing the date of the last purchase of each client (can be several within the same month). But I also need a column to bring me the last sale of the previous month (and not the previous sales within the same month), and I cant seem to do it.

 

Does anyone have a solution for that?

  • LastsalePreviousMonth = CALCULATE( MAX( Base[Dt Entrega]),ALLEXCEPT('Calendar,'Calendar'[Start of the month]), PREVIOUSMONTH("Your Calendar Table Here"))
     

4 Replies

  • The last sale of the month is a collumn or a measure?

     

    You can try the PREVIOUSMONTH function:

     

    Depends on the structure of your data

    • Anonymous's avatar
      Anonymous
      Not applicable

      The last sale of the month is a measure 

      Lastsale = CALCULATE( MAX( Base[Dt Entrega]),ALLEXCEPT('Calendar,'Calendar'[Start of the month]))
      • LuizKoller's avatar
        LuizKoller
        Icon for Resolver I rankResolver I
        LastsalePreviousMonth = CALCULATE( MAX( Base[Dt Entrega]),ALLEXCEPT('Calendar,'Calendar'[Start of the month]), PREVIOUSMONTH("Your Calendar Table Here"))
         
  • Hi,

    Share some data to work with (in a format that can be pasted in an MS Excel file) and show the expected result.