Skip to main content

Using Property Values as the Member Names

Using Property Values as the Member Names

By default, the source values for a level become the names for the members of the level.

You can instead specify the member names by defining a property for this level and using the values of that property as the member names. This is useful in the following scenarios:

  • To enable member names to be accessed at runtime — Values of properties can be accessed at runtime (the same is not true for levels).

  • To provide user-friendly member names for members — In some cases, you must base a level on a unique value that is not user-friendly. For example, suppose that you have a level based on the patient’s primary care physician. People’s names are not reliably unique, so you would have to base the level on a unique doctor identifier instead, which might have no meaning for the users. In this case, you would also define a property that accesses the doctor’s name, and you would use that property as the name of the member.

To use property values as the names for members of a level:

  1. Define a property for this level, as described in the next chapter.

    Each member of the level has a value for this property.

  2. For this property, select the Use as member names option.

  3. Optionally, to retrieve the property value at runtime, select the Get value at run time option.

    If you use this option, note the following requirement: For the parent level (the level that contains the property), the source property or source expression of that level must evaluate to an ID. The system assumes that (at least for this level), the source data is normalized. That is, for the level, the data is in a different table and the source table contains a link to that table.

Examples

The SAMPLES namespace provides the following examples of levels that have properties with Use as member names, Get value at run time, or both:

  • The DxDoc level in the Patients cube. This level has the property Name, which is configured with Use as member names. The DxDoc level is based on the unique ID of the doctor. Depending on the number of patients you generate, you may see multiple doctors with the same name. Because of how this level is defined, those doctors are not combined with each other.

  • The City level in the Patients cube. This level has the property Name, which is configured with Use as member names and with Get value at run time.

  • The City and Channel Name levels in the HoleFoods Sales cube. These levels have properties that are configured with Use as member names.

  • The Product Name level in the HoleFoods Sales cube. This level has a property that is configured with Use as member names and with Get value at run time.

FeedbackOpens in a new tab