Archived discussions are read-only. Learn more about SAP Q&A

Can we Implement YTD using MDX syntax in olap universe.

Hi,

I am trying to implement YTD prompt from universe level. Can any one suggest how can i implement it using MDX syntax in olap universe.

Regards,

Anil Kumar.

  • SAP Employee
replied

Hi,

In MDX, you need to generate the technical name to have you expression valid.

Moreover the correct syntax is: SUM(MTD(member),measure)

So in your case the prompt must be constrained on the technical name and cannot be free, the correct syntax is:

<EXPRESSION> SUM(MTD(@Prompt('YYYYMM','A','Cal. year / month\L01 Cal. year / month',mono,primary_key)),
@(Select(Key Figures\Total Variance)) </EXPRESSION>

Last, the result will be not really significant because you are asking for a MTD with a Year-Month as time member: the result will be the measure value for the selected month.

In your case you need to have a time series function for an upper level like YTD or QTD. If you want to use MTD, the the time member selected would be at a lowest level, such as week or day.

Regards

Didier

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question