Forum Discussion

imranami's avatar
imranami
Helper I
6 years ago

User Defined Date Range for a Calendar Table

Hi everyone,

 

Is there a way to dynamically contract/expand the date range of DAX calendar table based off a selected number?

 

So for example instead of:

 

 

Table = CALENDAR(TODAY()-30, TODAY())

 

 

I want:

 

 

Table = CALENDAR(TODAY()-[random variable number], TODAY())

 

 

Ultimately I am trying to filter a date slicer to display only dates relevant to specific days selected by the user (e.g. the last 7 days). I could create a separate relative date slicer, but the customer would prefer a slicer containing values such as 7, 14, 30, 90 days etc.

 

Best regards,

ImranAmi

3 Replies