Friday, March 30, 2012

Role playing dimension and member naming question.

I have a fact table with invoice information that has multiple date columns.

I had originaly only needed to join my time dimension to this fact table on it's create date, but I have now added a role-playing dimension to join to the invoice date.

When I had 1 date dimension all of it's members where called 'week','year', 'day', etc.
Now that I have the role-playing dimension I have two dimensions with member names like 'Date.week', 'Date.year', 'Date.day', 'Invoice Date.week', 'Invoice Date.year', 'Invoice Date.day'.

So many queries I had written to reference the original date dimension no longer work because of the extra 'Date.' prefix. Is there a way to hide this prefix for my original date dimension?

Thanks in advance.

I had the same problem earlier on. I had to bite the bullet and change my MDX when I had multiple 'date' dimensions. Can you globally change the MDX or are you using a third party tool?

Unless someone knows better.

|||

I am using ProClarity as a front end to the cube. I have found a sort of work around, rather than creating a role-playing dimension. I created a whole new date dimension on the same date table and it doesn't mess up the naming. The only downside I can see to this right now is that if I have one date dimension on rows and one date dimension on columns your result could look like:

may june july august
may
june
july
august

so it's not really clear which dimension is where, but I could get around this by changing the names of the members in the new date dimension.

-Preston

|||

Hi,

Although this solution will ultimately work, I guess we are duplicating process and space by repeating a dimension.

I've not tested it thorougly yet, but, the cube dimension has a property named HierarchyUniqueNameStyle, that allows for two values: IncludeDimensionName and ExcludeDimensionName. Using the later in the "default" dimension, let's say "Date" vs. "Delivery Date", the MDX will run fine as it was originally, without need to edit all of them.

Jordi Rambla

SQL Server MVP

Certia (http://www.certia.net)

SolidQualityLearning (http://www.solidqualitylearning.com)

No comments:

Post a Comment