Forum Discussion

Justas4478's avatar
Justas4478
Icon for Post Prodigy rankPost Prodigy
4 years ago

Limiting data from specific filtered date for target

Hello, I have this measure.

Model stores Sales Forum Average = CALCULATE (Averagex(Values('Store'[Store Number]) , [Sales Value LFL]),FILTER (
'Store','Store'[Store Number] IN {"0716","0711"}))
 
I was trying to modify the measure so that it would filter [Sales Value LFL] sales before 30/05/2022 would be ignored for store 0716 and that it would not ignore sales before 30/05/2022 for rest of the store numbers in the filter.
 
I am really stuck with this and I dont know is it even possible to do.
I appreciate any help.
Thanks

4 Replies

  • Justas4478 , Try like

     

    Model stores Sales Forum Average = CALCULATE (Averagex(Values('Store'[Store Number]) , [Sales Value LFL]),FILTER (
    'Store',('Store'[Store Number] IN {"0716"} && [Sales Value LFL] > date(2022,5,31) ) || 'Store'[Store Number] IN {"0711"}))

    • Justas4478's avatar
      Justas4478
      Icon for Post Prodigy rankPost Prodigy

      amitchandak It looks to be working but I dont have means to check numbers. I will reply back once I check numbers next week. Thanks.

    • Justas4478's avatar
      Justas4478
      Icon for Post Prodigy rankPost Prodigy

      amitchandakHello, I have manage to check the numbers and it seems that when I try to use solution that you provided it ignores stores 0716 sales from all weekly sales figures and only uses store 0711 sales. Exemption to total at the bottom.

      You can see in the image that I attached what are figures from the measure and figures of the stores. I hope it helps to explain it better.

       

      Let me know if you have any questions.

      Thank you.

      • Justas4478's avatar
        Justas4478
        Icon for Post Prodigy rankPost Prodigy

        amitchandak Do you know if measure is able to archieve expected results from the attached image. Since I dont know is it possible to do that kind of data manipulation to a measure because of its nature.

        I appreciate any help. Thank you.