Thursday, March 29, 2012

Description for Calculated Measures?

Hi,

is there no way to add a description for a Calculated Measure? Well, that would be something to add if it's not there already... Metadata is so important so I think it's very important to have a description at this point, it's even more important since it's something you calculate and so it might be not good known for all the users...

Hello

It is perfectly possible in MSAS 2005,You can go to the Script View of calculated Measure and you can add the description there

Thx and regards

Pankaj

|||

Pankaj,

that sounds great... However: How to you do that? There is no documentation about that... I'm not talking about some comment in the MDX script, I would like to have a description which is saved with the measure and clients can display to the user...

Thanks,

|||

hello Thomas,

indeed, it looks like there is an omission in the UI, and setting description is not currently exposed.

If you really need to set it a lot, however, you can still specify the Description in cube file, using the CalculationProperty. In the Solution Explorer right click on your cube and choose View Code. Find the MdxScript element. See if it contains CalculationProperties element under it. if it does, see if there is already CalculationProperty element corresponding to the calculated member that you are interested in. If there is simply add the <Description>...</Description> tag there. If there is no CalculationPorperty for the specific calculation yet - go to calculation Properies dialog in the Calculations tab of cube editor (there is a toolbar button for it), and set a Display Folder for the calc member you are interested in. This should create a calculation property. Then edit the cube file and add <Description> there, you can also remove DisplayFolder, if you really didn't need it. [of course you can just create the whole calc property by hand, but i'd probably suggest using UI as is less possibility to make a typo or something.]

Below is a sample of the script with a single Calculated Member calculation and a Description set for it.

<MdxScripts>
<MdxScript dwd:design-time-name="2f5f0150-ae7c-47bf-b4ef-df02e6456044">
<ID>MdxScript</ID>
<Name>MdxScript</Name>
<CreatedTimestamp>0001-01-01T08:00:00Z</CreatedTimestamp>
<LastSchemaUpdate>0001-01-01T08:00:00Z</LastSchemaUpdate>
<Commands>
<Command>
<Text>/*
The CALCULATE command controls the aggregation of leaf cells in the cube.
If the CALCULATE command is deleted or modified, the data within the cube is affected.
You should edit this command only if you manually specify how the cube is aggregated.
*/
CALCULATE;

CREATE MEMBER CURRENTCUBE.[MEASURES].[Calculated Member]
AS 1,
VISIBLE = 1 ; </Text>
</Command>
</Commands>
<CalculationProperties>
<CalculationProperty dwd:design-time-name="53d79ba5-3a54-4165-9798-3b19ba278ca0">
<CalculationReference>[MEASURES].[Calculated Member]</CalculationReference>
<CalculationType>Member</CalculationType>
<Description>My Calc Member Description</Description>
</CalculationProperty>
</CalculationProperties>
</MdxScript>
</MdxScripts>

One should use caution editing the files directly though.

Thank you for mentioning this, we will consider exposing this in the UI in next version.

Hope this helps,

No comments:

Post a Comment