cancel
Showing results for 
Search instead for 
Did you mean: 

Conditions in OLAP Universe (Analysis Services)

0 Kudos

Hi,

We have an OLAP universe connected to Analysis Services 2005. We would like to create a condition to use it as a filter to the reports in Web Intelligence. I have searched documentation about this, and i'm trying to get this code into the condition...

<CONSTANT CAPTION="@Select(MeasuresValor), .[Jerarquia Tiempo].Año].PrevMember)/></CONDITION></FILTER>

We want to determine the scope of the report dinamically so we can bring last year and actual year only, without having to define it as a constant.

Even though when I insert this statement, the parse it, the parse failed.

I would appreciate any suggestions.

CO

Accepted Solutions (0)

Answers (3)

Answers (3)

0 Kudos

Hi Didier,

The purpose of the condition is to use it as a filter in the reports, so I can have a range of data and this one can be dinamic. This way I can get the last three years, and this range would move with the years, and so on with other periods, last 12 months, last 30 days, etc.

I would appreciate if you know any other way to get this done.

Tks for your help.

Claudia

0 Kudos

The parse is successfull, but when i use it in a report as a filter it doesn't get me any data.

In Analysis Services i have a named set declared as follow

Filter(Intersect([Fecha].[Jerarquia Tiempo].[Año].Members, [Fecha].[Jerarquia Tiempo].[Año].Members), Val([Fecha].[Jerarquia Tiempo].CurrentMember.Properties("Año Actual")) = 1).Item(0).PrevMember

The Value of the propertie "Año Actual" identifies the current year, and with this sentence it brings me the previous year.

What I'm trying to do is get the same funcionality from the Universe in BO.

How can I get this?

Tks

Former Member
0 Kudos

Hi Claudia,

I didn't realize that the solution I proposed was in fact incorrect.

Because we are not proposing in this current version the ability to manipulate Named Sets, we only have the ability to define calculated measures.

If you need to retrieve only the previous year, here are 2 propositions depending on the property values you have defined.

The first syntax will retrieve all periods except the current year:

<FILTER EXPRESSION="IIF ([Fecha].[Jerarquia Tiempo].Properties("Año Actual") = 1, 0, 1)"><CONDITION OPERATORCONDITION="Equal">
<CONSTANT CAPTION="1"></CONSTANT></CONDITION></FILTER>

The second syntax will retrieve only previous years if we assume that the "Año Actual" property is equal to "0":

<FILTER EXPRESSION="IIF ([Fecha].[Jerarquia Tiempo].Properties("Año Actual") = 0, 1, 0)"><CONDITION OPERATORCONDITION="Equal">
<CONSTANT CAPTION="1"></CONSTANT></CONDITION></FILTER>

Regards,

Didier

Former Member
0 Kudos
Hi,

If the filter parse failed it is because:
    • @Select statement doesn't refer to an object
    • @Prompt synatx is incorrect
After having a look on the syntax, it seems that the XML syntax is incorrect but maybe the @Select also is incorrect: @Select doesn't refer to an object. The syntax for @Select is:
@Select(parent classobject name)
Be sure that the class you are referring in the @Select is the class or sub-class parent of the object.

Moreover I noticed that your MDX syntax is also incorrect, try this:
<FILTER KEY="[Fecha].[Año].[Año]"><CONDITION OPERATORCONDITION="InList">
<CONSTANT CAPTION="(@Select(MeasuresValor), [Fecha].[Jerarquia Tiempo].[Año].PrevMember)"></CONSTANT></CONDITION></FILTER>

Didier