Forum Discussion
Anonymous
7 years agoNot applicable
Calculating Last 3 Month Production
I need to calculate the Last 3 Months of Production using Dax. I feel like the code below should be correct, but is missing something simple. Can I use the word month, when using FiscalMonth Sales?...
v-yuta-msft
Community Support
7 years agoAnonymous ,
Please modify the measure using dax below and check if it can meet your requirement:
3 month =
CALCULATE (
SUM ( FactProductionTransactionDetail[Quantity] ),
DATESINPERIOD (
DimDate[CalendarMonthNumber],
DimDate[CalendarMonthNumber] = SELECTEDVALUE ( Table[Selection] ),
-3,
MONTH
)
)
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
7 years agoNot applicable
Can you use SELECTEDVALUE in an Analysis Services connection?