Data model Action group
  • 14 Jun 2024
  • 7 Minutes to read
  • Contributors
  • Dark
    Light

Data model Action group

  • Dark
    Light

Article summary

This topic describes the Procedure Actions included in the Data model Action group and their specific properties.

The Data model  Actions allow you to mainly perform maintenance activities on Data models, such as backing up and restoring Data models, extracting and reloading Cubes, Entities, and Relationship trees, and much more.

The Data model Action group offers the following steps:

Backup Data model

This step allows you to create a backup of the Data model where the Procedure step resides.

Board will create an exact copy of all files and folders of the Data model and save them, by default, in the Board\Database\_Backup directory. You can change the directory by entering a different path in the “Custom path” field.

When the "Expiration Days" property is active (i.e. when a value higher than “0” is entered), the Data model backup directory will also have a full timestamp in its name with the following format: YYYY-MM-DD HH-MM-SS-FFF@@DatamodelName.hbmp (for example, “2023-01-12 16-11-44-932@@Datamodel.hbmp”).

When running a Procedure with a configured "Expiration Days" value, for example “7”, all previous backups of the same Data model dating 7 days before the current execution of the Procedure step will be deleted.

contents/assets/images/dbbackupdm 1.png

Example:
If one or more backups were performed on the 20th of July 2023 and the Backup Data model Procedure step was executed again on the 28th of July 2023 with the "Expiration Days" property set to “7”, the backups performed on the 20th of July 2023 or before are deleted, since they were created more than 7 days before the execution of the step.
If the Expiration Days option is not active (i.e. when the value in the field is "0"), the backup directory will be saved with the same name as the Data model (for example, DatamodelName.hbmp) and will be overwritten every time the Procedure step is executed.

This step supports the following Substitution formulas in the “Custom path” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Custom path” field.

Restore Data model

This step allows you to restore an existing backup of the Data model where the Procedure step resides.

Board will automatically overwrite the Data model files and folders located in the Board\Database directory with the backup of the same name located in the Board\Database\_Backup directory, by default.

In the case of multiple backups of the same Data model, Board will restore the most recent one (i.e. with the most recent timestamp).

To restore the Data model backups that have been saved in a custom path, you have to enter that path in the “Custom path” field.

If you want to restore a specific backup, you have to insert the full path of the desired backup. For example, Board\Database\_Backup\2023-01-12 16-11-44-932@@Datamodel.hbmp.
contents/assets/images/dbrestoredm 1.png
While restoring the backup, the Data model will be locked and no action can be performed on it until the execution of the step terminates.

Please note that the action of restoring a backup cannot be undone, since the Data model files and directories are overwritten in the process.
See this page for more details about backing up and restoring a Data model

This step supports the following Substitution formulas in the “Custom path” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Custom path” field.

Extract all trees

This step allows you to extract members and Relationships of all Entities of the Data model where the Procedure step resides.

Entity Members and Relationships are extracted to  multiple CSV (Comma Separated Value) files in the Board\Dataset\DatamodelName\All\Trees default directory.

You can enter a custom path in the “Path/File” field. Board will automatically create an “All” directory inside of your custom path with a subsequent “Trees” directory where the extracted Entity and Relationship files will be saved.
The extracted CSV files are in the following format:

  • Axxx: Each of these files contains all Members of a custom Time Entity. Their names are made up of the letter “A” followed by an incremental number, for example A001, A002, A003, etc.

  • Dxxx:  Each of these files contains all Members of a non-Time Entity created in the “Entities” section of the Data model. Their names are made up of the letter “D” followed by an incremental number, for example D001, D002, D003, etc.

  • TreeAxxx: Each of these files contains the relationships between Time Entities. Their names are made up of the word "Tree" and the letter “A” followed by an incremental number, for example TreeA001, TreeA002, TreeA003, etc.

  • TreeDxxx: Each of these files contains the relationships between non-Time Entities created in the “Entities” section of the Data model. Their names are made up of the word "Tree" and the letter “D” followed by an incremental number, for example TreeD001, TreeD002, TreeD003, etc.

In addition to the CSV files, Board generates structure definition files with the same name and a ".cfg" extension: the information contained in these files is used for Board to automatically read and import the contents of the extracted CSV files.
contents/assets/images/dbextractalltrees 1.png

This step supports the following Substitution formulas in the “Path/File” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Path/File” field.

Extract all Cubes

This step allows you to extract all Cubes of the Data model where the Procedure step resides.
Values of each Cube are extracted to a CSV (Comma Separated Value) file in the Board\Dataset\DatamodelName\All\Cubes default directory.
You can enter a custom path in the “Path/File” field. Board will automatically create an “All” directory inside of your custom path with a subsequent “Cubes” directory where the extracted Cube files will be saved, one file per Cube.
The extracted CSV files are named after the Physical name of the Cube and the extracted version (which is always the Structure of the Cube) in the following format: Vxxxxxxxx  (i.e. V00010001).
In addition to the CSV files, Board generates structure definition files with the same name and a ".cfg" extension: The information contained in these files is useful to have Board automatically read and import the contents of the extracted CSV files.
The “Floating point” option is meant only for numeric Cubes. If enabled, the Procedure step will extract the values in the floating-point data format, which will include every decimal digit in most cases. If this option is disabled, the extracted values will only have a maximum of 5 decimals digits.
contents/assets/images/dbextractallcubes 1.png

This step supports the following Substitution formulas in the “Path/File” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Path/File” field.

Reload all trees

This step allows you to reload previously extracted Entity members and Relationships in the Data model where the Procedure step resides.
Board automatically imports Entity and Tree content based on the files in the default directory of Board\Dataset\DatamodelName\All\Tree.
In the case where these files were extracted to a custom directory, manually enter the path of that directory in the “Path/File” field.
When the “Clear before load” option is enabled, all Entities that will be updated are automatically cleared before the reloading process. Entities that won't be updated will not be cleared.
Enable the “Delete ASCII files” option if you want the Procedure to delete all the files after the reloading process.
contents/assets/images/dbreloadalltrees 1.png

This step supports the following Substitution formulas in the “Path/File” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Path/File” field.

Reload all Cubes

This step allows you to reload previously extracted Cube data in the Data model where the Procedure step resides.
Board automatically imports Cube data based on the extracted files in the Board\Dataset\DatamodelName\All\Cubes default directory.
In the case where these files were extracted in a custom directory, manually enter the path of that directory in the “Path/File” field.
When the “Clear before load” option is enabled, all Cubes that will be updated are automatically cleared before the reloading process. Cubes that won't be updated will not be cleared.
Enable the “Delete ASCII files” option if you want the Procedure to delete all the files after the reloading process.
contents/assets/images/dbreloadallcubes 1.png

This step supports the following Substitution formulas in the “Path/File” field: @User, @UserName, @Database, @ProcedureId, and all the @Date variants except @Datetime. In addition, environment variables such as %bss% can also be used in the “Path/File” field.

Clear Entity

This step allows you to clear an Entity.

To configure this step, select the desired Entity you want to clear from the “Entities” dropdown list.

All members of the selected Entity will be deleted, regardless of the active selection.
contents/assets/images/dbclearentity 1.png

Normalize tree

This step allows you to perform the “Normalize” feature on one or all relationship trees.

To configure this step, select a tree from the “Tree” dropdown list or choose “All” to perform the Normalization on all trees. The drop-down list shows only the least aggregate Entity of each tree.

The “Do not fix missing relationships” option is enabled by default, meaning that no changes will be made to Entity members with missing relationships (also called "orphan members"). Disable this option If you want to automatically fix missing relationships.

See this page for more information about the Normalize feature
contents/assets/images/dbnormalizetree 1.png

In the case of a Capsule Procedure, the Data model dropdown menu allows you to select the Data model on which the Procedure step will be executed, except in cases where the Procedure step has specific options that act on other Data models (for example, the "Save Pending Changes to Disk" step in the "Advanced Action Group" can be configured to act on all Data models or only on the Data model where the Procedure resides).


Was this article helpful?