Thursday, March 22, 2012

Changing the caption of a member name in a Named Set

I have created a named set that includes a list of five customers. One of the customers is named "XYZ Corp.". For the named set, I want to display the customer with a name of "XYZ Corporation". Could someone supply me with the syntax needed to do this? Thank you.

David

Normally it is not possible to change captions/names of the existing hierarchy members. The usual workaround is to create calculated member which aliases the original member. This, however, has couple of implications, for example Exists rules for the calculation member are different etc.

CREATE Customers.[XYZ Corporation] = Customers.[XYZ Corp];

CREATE SET NamedSet AS { ..., [XYZ Corporation], ... };

|||

Mosha,

If there are implications when creating an alias to be used in a named set, would it be better to handle this issue in the reporting client rather than in Analysis Services. For example, I can rename an item in an Excel 2007 pivot table connected to an AS cube. The renamed item becomes a caption while the MDX still points to the original member name in the cube.

The only problem with this approach is that I would have to repeat this process for each report instead of doing it once as part of the named set.

David

|||This is really up to you which approach to take. I think you recognize now advantages and disadvantages of each approach so you can make informed decision.

No comments:

Post a Comment