Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Dynamic Calculation Based on Date

Hi Everyone,  I am writing to ask question to the following problem: I am attempting to calculate deltas based on varying time intervals that are picked by the user with a slicer built on my M Date ...
  • AllisonKennedy's avatar
    AllisonKennedy
    4 years ago

    Anonymous  DAX can do all the work that relationships do, so if you want to pick up all data between dates, you don't actually need any relationship. Seems really counter-intuitive, but it works.

     

    Other option is to keep the relationship between Date and Fact table, but then need to use the ALL or similar function  (such as DATESBETWEEN ) to ensure that the relationship doesn't restrict you to only seeing the date that is selected. As you have pointed out, it all comes down to using the right date in the right place in the DAX formulas.

     

    Feel free to mark your most recent post as a solution, as it looks like you've solved this now?