In the Chronological Key dialog, select a chronological key column, click Up or Click OK to return to the Level dialog.

9-10 Metadata Repository Builders Guide for Oracle Business Intelligence Enterprise Edition

7. Optional Type a description for the key and then click OK.

8. Repeat Step 2 through Step 7 to add primary keys to other logical levels.

9. In the Logical Level dialog, click OK.

Selecting and Sorting Chronological Keys in a Time Dimension At least one level of a time dimension must have a chronological key. Although you can select one or more chronological keys for any level and then sort keys in the level, only the first chronological key is used. To select and sort chronological keys for a time dimension: 1. In the Business Model and Mapping layer of the Administration Tool, expand a time dimension and then expand the highest level Grand Total level of the dimension.

2. Double-click a logical level below the Grand Total level.

3. In the Logical Level dialog, click the Keys tab.

4. To select a chronological key, in the Keys tab, select the Chronological Key option.

You may need to scroll to the right to see this option.

5. To sort chronological keys, in the Keys tab, double-click a chronological key.

6. In the Chronological Key dialog, select a chronological key column, click Up or

Down to reorder the column, and then click OK. Adding a Dimension Level to the Preferred Drill Path You can use the Preferred Drill Path tab to identify the drill path to use when Oracle BI Presentation Services users drill down in their data requests. You should use this only to specify a drill path that is outside the normal drill path defined by the dimensional level hierarchy. It is most commonly used to drill from one dimension to another. You can delete a logical level from a drill path or reorder a logical level in the drill path. To add a dimension level to the preferred drill path: 1. Click Add to open the Browse dialog, then select the logical levels to include in the drill path. You can select logical levels from the current dimension, or from other dimensions.

2. Click OK to return to the Level dialog.

The names of the levels are added to the Names pane. Automatically Creating Dimensions with Level-Based Hierarchies You can set up a dimension automatically from a logical dimension table if a dimension for that table does not exist. To create a dimension automatically, the Administration Tool examines the logical table sources and the column mappings in those sources and uses the joins between physical tables in the logical table sources to determine logical levels and level keys. Therefore, it is best to create a dimension in this way after all the logical table sources have been defined for a dimension table. The following rules apply: Note: For a dimension to be recognized as a time dimension, you must select Time on the General tab of the Dimension dialog. Working with Logical Dimensions 9-11 ■ Create Dimensions is only available if the selected logical table is a dimension table defined by 1:N logical joins and no dimension has been associated with this table. ■ An automatically created dimension uses the same name as the logical table, adding Dim as a suffix. For example, if a table is named Periods, the dimension is named Periods Dim. ■ A Grand Total level is automatically named logical_table_name Total. For example, the Grand Total level of the Periods Dim table is Periods Total. ■ When there are multiple tables in a source, the join relationships between tables in the source determine the physical table containing the lowest-level attributes. The lowest level in the hierarchy is named logical_table_name Detail. For example, the lowest level of the periods table is Periods Detail. ■ The logical key of the dimension table is mapped to the lowest level of the hierarchy and specified as the level key. This logical column should map to the key column of the lowest level table in the dimension source. – If there are two or more physical tables in a source, the columns that map to the keys of those tables become additional logical levels. These additional level names use the logical column names of these key columns. – The order of joins determines the hierarchical arrangement of the logical levels. The level keys of these new logical levels are set to the logical columns that map to the keys of the tables in the source. ■ If there are multiple logical table sources, the tool uses attribute mappings and physical joins to determine the hierarchical order of the tables in the physical sources. For example, you might have three sources A, B, C each containing a single physical table and attribute mappings for 10, 15, and 3 attributes, respectively not counting columns that are constructed from other logical columns. The following is a list of the results of creating a dimension for this table automatically: – The Administration Tool creates a dimension containing four logical levels, counting the Grand Total and detail levels. – The key of the table in source B that has the greatest number of columns mapped and contains the column mapping for the logical table key should be the level key for the detail level. – The parent of the detail level should be the logical level named for the logical column that maps to the key of the physical table in source A. – Any attributes that are mapped to both A and B should be associated with level A. – The parent of level A should be the logical level named for the logical column that maps to the key of the physical table in source C. – Any columns that are mapped to both A and C should be associated with level C. ■ Table joins in a physical source might represent a pattern that results in a split hierarchy. For example, the Product table can join to the Flavor table and a Subtype table. This would result in two parents of the product detail level, one flavor level and one subtype level. ■ You cannot create a dimension automatically in the following situations: 9-12 Metadata Repository Builders Guide for Oracle Business Intelligence Enterprise Edition – If a dimension with joins and levels has already been created, Create Dimension does not appear on the right-click menu. – If the table is not yet joined to any other table, the option is not available because it is considered a fact table. ■ In a snowflake schema, if you use a table with only one source and create the dimension automatically, the child tables are automatically incorporated into a hierarchy. The child tables form intermediate levels between the Grand Total level and detail level. If more then one child table exists for a dimension table, the hierarchy is a split hierarchy. To create a dimension automatically: 1. In the Administration Tool, open a repository. 2. In the Business Model and Mapping layer, right-click a logical dimension table that is not associated with any dimension .

3. From the right-click menu, select Create Logical Dimension, then select either