Skip to content

Structure Repeaters

This page provides implementation information related to structures when the goal is to be able to use the Structure Repeater functionality in IFS Business Reporter.

Overview

A structure defines a number of nodes to which leaves are attached. The leaves represent the information, e.g. basic data, that are defined in a hierarchy of nodes.

One example of a structure is the following where we have a geographical hierarchy with leaves that represent cities.

This is actually an accounting structure in one specific company where the code part B is defined to represent cost centers and the name of these cost centers are cities.

Many structures only consists of the following items and of course relations between them:

  • Nodes
  • Leaves

A structure also has levels but these are in many cases not used; they are only implicitly defined. In the example above the node ACME can be said to exist on the implicit level 1 and so on.

There are however also cases where the levels are explicitly defined, like in the case above for Accounting Structures in Financials. Each level in the structure is given an identity by the end-user. The main purpose is of course to simplify using accounting structures for analyzing purposes. So in this case a structure consists of the following items,

  • Levels
  • Nodes
  • Leaves

Business Reporting & Analysis services support both these cases and a client like IFS Business Reporter can take advantage of this functionality to create flexible, dynamic and advanced reports.

Structure Repeaters

The IFS Business Reporter client supports a special type of functionality called Structure Repeaters.

The purpose with these repeaters is to be able to design a report based on one or more structures and also to perform repetition on structure items, enabling the possibility to create flexible and powerful reports.

Structure Model for Structure Repeaters

Since there is no generic structure entity/functionality in IFS Cloud, a structure model has been defined in Business Reporting & Analysis services. This functionality does however not support the possibility to replace all other structures and does not contain any APIs' to be used by the business logic to define/modify etc product specific structures in a general representation. The sole purpose of this model is to support Business Reporting & Analysis services.

All structure repeater related references in the IFS Business Reporter design leads to creation of one or more Structure Requests (XlrStructRequest).

The structure requests are created by IFS Business Reporter and sent to Business Reporting & Analysis services that returns a Structure Response (XlrStructResponse). A structure in a request can have one or more parent items that has to be known when doing the request.

The response consists of the following parts (Entities):

  • XlrStructResponse This is the master entity and it keeps information about the dimension item that represents the structure identity and the description of the structure identity.
  • XlrStructResponseLevel Keeps information about explicit levels in a structure. It is rather common that a structure does not have any levels that can be defined by the end-user. One example is a Project in IFS Engineering. For e.g. Accounting Structures in IFS Financials, the levels can be defined by the end-user. Thus a response might have level information but does not have to.
  • XlrStructResponseNode Keeps information about all nodes in a structure.
  • XlrStructResponseLeaf Keeps information about all the leaves connected to each and every node. Important here to note that the leaf value represents the code in a base/target dimension. Examples:

    • For a Project the leaf values are activities. This means that the we want to add structure repeater support to the dimension DIM_ACTIVITY.
    • For an Accounting Structure based on code part B the code part B values are the leaves. So we want to add structure repeater support to the dimension DIM_CODE_B.

To be able to use the structure repeater support a set of dimensions with corresponding Meta Data has to be developed, to make it possible to Business Reporting & Analysis services to find the necessary requested structure information and build a structure response.

Structure Master

With structure master we mean the highest level in a structure, i.e. the structure header. The following items are mandatory in a developed structure dimension:

  • Structure Id

    1. Typed as Xlr_Structure_Util_API.STRUCTURE_ID_ITEM_
    2. Mandatory in structure master dimension.
    3. Mandatory in target dimension and to be added by the structure master Metadata.
  • Structure Id Description

    1. Typed as Xlr_Structure_Util_API.STRUCTURE_ID_DESC_ITEM_
    2. Mandatory in structure master dimension
    3. Mandatory in target dimension and to be added by structure master Metadata.

Dimension

Following the previous example we look at a the info in a dimension named DIM_ACC_STRUCT_CODE_B:

Note that:

  • The ID is defined as "<parent^key>" = "<company^structure_id>", e.g."900^LL_DOC"
  • Columns STRUCTURE_ID and STRUCTURE_ID_DESCRIPTION are present to satisfy the mandatory item criteria.

Meta Data

The Metadata file defines the dimension in a general way but:

  • The structure items/attributes are given a dedicated type
  • Two items, STRUCTURE_ID and STRUCTURE_ID_DESCRIPTION, are also added to the DIM_CODE_B dimension and these items also have to define the connected structure item, referring to an item in the structure dimension.


This part shows how the two structure items are defined as items in DIMENSION=DIM_ACC_STRUCT_CODE_B.

The items must also be added to DIM_ADD_ON=DIM_CODE_B. In this case we have to type the items but also specify the associated dimension item in the structure specific dimension. Also note that the items are prefixed with SRI_ since these structure items are different from the ones added for filter criteria support.

The Meta Data file is named metadata_genledbidimaccstructcodeb.zip

Structure Level

If the structure contains explicitly defined levels we have to create a dimension that defines the level information. The following items are mandatory in a developed structure level dimension:

  • Structure Id

    1. Typed as Xlr_Structure_Util_API.STRUCTURE_ID_ITEM_
    2. Mandatory in structure level dimension.
  • Level Id

    1. Typed as Xlr_Structure_Util_API.LEVEL_ID_ITEM_
    2. Mandatory in structure level dimension.
    3. Mandatory in target dimension and to be added by structure level Metadata.
  • Level Id Description

    1. Typed as Xlr_Structure_Util_API.LEVEL_ID_DESC_ITEM_
    2. Mandatory in structure level dimension.
    3. Mandatory in target dimension and to be added by structure level Metadata.
  • Parent Level Id

    1. Typed as Xlr_Structure_Util_API.PARENT_LEVEL_ID_ITEM_
    2. Mandatory in structure level dimension.

Dimension

Following the previous example we look at the info in a level dimension named DIM_ACC_STRUCT_LEVEL_CODE_B,

Note that:

  • The ID is defined as "<parent(s>)^key>" = "<company^structure_id^level_id>", e.g. "900^LL_DOC^COMPANY"
  • Columns STRUCTURE_ID, LEVEL_ID, LEVEL_ID_DESCRIPTION and PARENT_LEVEL_ID are present to satisfy the mandatory item criteria.

Meta Data

The Meta Data file defines the level dimension in a general way but:

  • The structure items are typed
  • Two items are added to the DIM_CODE_B dimension (LEVEL_ID and LEVEL_ID_DESCRIPTION) and these items also have to define the connected structure item,  referring to an item in the structure level dimension.

This part shows how the four structure specific items are defined as items in DIMENSION=DIM_ACC_STRUCT_LEVEL_CODE_B. The complete definition for PARENT_LEVEL_ID is not fully displayed!

Two of these items must also be added to DIM_ADD_ON=DIM_CODE_B. In this case we have to type the item but also specify the associated dimension item in the structure level specific dimension. Also note that the items are prefixed with SRI_ since these structure items are different from the ones added for filter criteria support.

The Meta Data file is named metadata_genledbidimaccstructlevelcodeb.zip

Structure Node

A specific dimension has to be created that defines the node information. The following items are mandatory in a developed structure node dimension:

  • Structure Id

    1. Typed as Xlr_Structure_Util_API.STRUCTURE_ID_ITEM_
    2. Mandatory in structure node dimension.
  • Node Id

    1. Typed as Xlr_Structure_Util_API.NODE_ID_ITEM_
    2. Mandatory in structure node dimension.
    3. Mandatory in target dimension and to be added by structure node Metadata.
  • Node Id Description

    1. Typed as Xlr_Structure_Util_API.NODE_ID_DESC_ITEM_
    2. Mandatory in structure node dimension.
    3. Mandatory in target dimension and to be added by structure node Metadata.
  • Parent Node Id

    1. Typed as Xlr_Structure_Util_API.PARENT_NODE_ID_ITEM_
    2. Mandatory in structure node dimension.

Dimension

Following the previous example we look at the info in a node dimension named DIM_ACC_STRUCT_NODE_CODE_B:

Note that:

  • The ID is defined as "<parent(s>)^key>" = "<company^structure_id^node_id>", e.g. "900^LL_DOC^SWEDEN"
  • Columns STRUCTURE_ID, NODE_ID, NODE_ID_DESCRIPTION and PARENT_NODE_ID are present to satisfy the mandatory item criteria.

Meta Data

The Meta Data file defines the node dimension in a general way but:

  • The structure items are typed.
  • Two items are added to the DIM_CODE_B dimension (NODE_ID and NODE_ID_DESCRIPTION) and these items also have to define the connected structure item.

This part shows how the four structure specific items are defined as items in DIMENSION=DIM_ACC_STRUCT_NODE_CODE_B. The complete definition for PARENT_NODE_ID is not fully displayed!

Two of these items must also be added to DIM_ADD_ON=DIM_CODE_B. In this case we have to type the item but also specify the associated dimension item in the structure node specific dimension. Also note that the items are prefixed with SRI_ since these structure items are different from the ones added for filter criteria support.

The Meta Data file is named metadata_genledbidimaccstructnodecodeb.zip

Structure Leaf

A specific dimension has to be created that defines information about leaves connected to each node.

The leaf values should correspond to the item in the base dimension that has the attribute CODE_KEY=TRUE and practically this is the CODE attribute. The item typed as the leaf identity in the leaf dimension, normally the CODE, must be unique since it is not supported to have leafs with the same value. The reason is because:

  • The leaf dimension is never part of any SELECT statement representing fetch of a report specific data set.
  • The base dimension (e.g. DIM_CODE_B), will always be part of report specific data set SELECT statement, if the data set is affected by structure repeaters. The item defined as code key, CODE_KEY=TRUE, will be present in the SELECT statement and when the data set is retrieved by the IFS Business Reporter client, there must be a way to map the fetched code key values to leaf values in the structure.
  • The items typed as the leaf identity will be the one returned in the Structure Request and this value must match the code key in the different structure specific data sets.
  • If the leaf values are not unique, this means that it will not be possible to with 100% certainty find where in the structure the leaf value comes from.

In Project this means that the leaf describes activities and in the leaf dimension the code=leaf_id=activity_seq.

For Accounting Structures this means that the leaf describes code part values and in the leaf dimension the code=leaf_id=code_part_value.

The following items are mandatory in a developed structure leaf dimension:

  • Structure Id

    1. Typed as Xlr_Structure_Util_API.STRUCTURE_ID_ITEM_
    2. Mandatory in structure leaf dimension.
  • Node Id

    1. Typed as Xlr_Structure_Util_API.NODE_ID_ITEM_
    2. Mandatory in structure leaf dimension.
  • Leaf Id

    1. Typed as Xlr_Structure_Util_API.LEAF_ID_ITEM_
    2. Mandatory in structure leaf dimension.
    3. Mandatory in target dimension and to be added by structure leaf Metadata.

Dimension

Following the previous example we look at a the info in a leaf dimension named DIM_ACC_STRUCT_LEAF_CODE_B:

Note that:

  • The ID is defined as "<parent(s>)^key>" = "<company^structure_id^leaf_id>", e.g. "900^LL_DOC^CDY" As long as the leaf_id is unique within a structure, which it should, the ID does not have to consider the node identity.
  • Columns STRUCTURE_ID, NODE_ID  are present to satisfy the mandatory item criteria.

Meta Data

The Metadata file defines the leaf dimension in a general way but:

  • The structure items are typed.
  • One item is added to the DIM_CODE_B dimension (LEAF_ID) and for this one we also have to define the connected structure item.

This part shows how the structure specific item is defined as an item in DIMENSION=DIM_ACC_STRUCT_LEAF_CODE_B.

The item must also be added to DIM_ADD_ON=DIM_CODE_B. In this case we have to type the item but also specify the associated dimension item in the structure leaf specific dimension. Also note that the item is prefixed with SRI_ since this structure item is different from the ones added for filter criteria support.

Note: The leaf identity has to be added to the base dimension, DIM_CODE_B, but it should not be visible.

The Meta Data file is named metadata_genledbidimaccstructleafcodeb.zip

Remarks

Note: Structure Repeater items are not allowed as filter criteria items in IFS Business Reporter.

The structure items added to dimension DIM_CODE_B that are marked as visible have the attribute Display_Folder set to \Structure Repeater Items, which means that these items will appear in a sub folder with this name in the navigator in IFS Business Reporter.

Repeater Item Null Value - This is a configuration specific to Structure Repeaters (therefore implicitly meaning Structure Repeater Item Null Value). This should be specified if there is possibility of a node missing in one of the levels of your structure repeater so that your structure repeater shows data for all levels. However, this is handled automatically in dynamic structure repeaters and therefore you don't have to configure this manually if you are using a dynamic structure repeater. Please keep in mind that configuring this for a normal repeater does not have an impact on the report design as this functionality is meant to be used with structure repeaters only.