Skip to main content
Version: I2023.1.0

Add a Degenerate Dimension or a Common Degenerate Dimension

This section explains how to model a logical dimension off of one or more columns that are in a single fact dataset or in multiple fact datasets.

note

Note: Unhandled NULL values in key columns will result in incomplete aggregate tables and unexpected query results. See the Custom Empty Member feature for more details.

Procedure

  • To add a degenerate dimension:

    1. Open the main cube canvas.
    2. Locate a fact dataset of your cube.
    3. Drag a dimension column from the fact dataset to the Dimensions panel.

    The degenerate dimension is automatically created and linked to the fact dataset.

  • To share the degenerate dimension among two or more fact datasets:

    If your AtScale model has more than one fact dataset and more than one of the fact datasets contain values that you want to include in the degenerate dimension, drag the relevant column from each of those fact datasets to the degenerate dimension.

[!IMPORTANT] When you create a common degenerate dimension, you must ensure that it conforms to these constraints: You must use the same number of columns from each fact dataset. The data types must be consistent. Key columns used from each fact dataset must all use the same data types. Value columns used from each fact dataset must all use the same data types. If an order column is selected in one dataset, the order column from each of the other fact tables must be selected, too.

The result is a common degenerate dimension.

  • To create a hierarchical (multiple level) shared degenerate dimension among two or more fact datasets:

    1. Create a degenerate dimension by dragging a fact table column to the dimension panel.
    2. Double click the the dimension dataset to enter the dimension canvas. As is standard dimension design in AtScale, the system created a hierarchy with a single level for the dimension.
    3. Add the next higher hierarchy level by choosing its key column from the dataset and drag it to the hierarchy panel above the leaf level. Be sure to obey the type restrictions mentioned in the previous example as well as the rules for modeling hierarchies.
    4. Repeat the previous step to model additional levels based on different dataset columns.
    5. Return to the main canvas. The degenerate dimension is now rendered as a hierarchy with an arrow from each fact table column used as each level's key.
    6. Connect a different fact table to the hierarchical degenerate dimension by dragging columns that represent the same keys to the appropriate level. Repeat this process for each level in the hierarchy.
    7. You may now aggregate measures from both of the connected fact tables by the shared dimensional key values.
  • To create degenerate dimensions in bulk:

    1. In the cube canvas, click the fact dataset's menu icon and select Bulk Degenerate Dimensions. The dialog Create Degenerate Dimensions in Bulk opens.
    2. Select the columns to base your degenerate dimensions on from the list in the dialog. You can use the search bar to narrow down the column list.
    3. In the Dimension Name field beside each selected column, name your degenerate dimensions. For each degenerate dimension, the dimension, hierarchy, and one level will all be created using this name. You can rename any of these after creation.
    4. Select Create Degenerates. The dialog closes and your degenerate dimensions appear on the cube canvas.

What to do next

After the dimension is created, open it in the dimension editor canvas and complete the following modeling tasks: