Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

Count the repeating outlets based on current week to previous week

Hi,

I want to write the dax for No of unique outlets and No of Reordered Outlets and Reorder Rate as in below expected output table.

unique outlets: cumulative number of outlets are sold till that week (above expected output table unique outlets)

 

The data in the Database stores as follows,

 

 

Reordered outlets  is as follows, 

 

                                                                                                       

Thanks

3 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi,

    I found out unique outlets from above table by using below dax.

    unique outlets = CALCULATE(COUNT(SalesOrder[cust id]),FILTER(ALL('Calendar'[Date]),'Calendar'[Date] <= Max('Calendar'[Date])))
     
    i want to want to find out the Reordered outlets as shown in below figure. i.e. count of repeating outlets based current week outlets (below table i.e. second table unique outlets) to previous week cumulative outlets (above tablei.e. first table unique outlets)
     
    Thanks.
  • v-xicai's avatar
    v-xicai
    Icon for Community Support rankCommunity Support

    Hi Anonymous ,

     

    Could you please share your sample data for further analysis? You may upload sample pbix to OneDrive and post the link here. Do mask sensitive data before uploading.

     

    Best Regards,

    Amy