Find my approach below,
Create a string parameter like this
Then create a calculated field using parameter. Modify the logic with your fields.
Once done then drag the fields and show the parameter
Workbook attached for your reference. Let us know if this help.
Book2_v10.5.twbx 96.8 KB
May I know the logic behind of the formula?
IF DATEDIFF([Select Period],[Order Date],TODAY())=0 THEN [Sales] END
1 of 1 people found this helpful
Logic is quite simple,
We're taking datediff() between date from your data source and TODAY() based on parameter.
MTD=month //default value is month whereas MTD is display value
Hope this help.