Business Rules

This is the layer where your business logic will be applied to the data. It is a second layer on top of the business object, which can then be fed to the accesslayer. The business logic will be applied in the form of a database view. This enables you to make use of any functionality of the underlying database.

Definition

A business ruleset is a view on top of a business object. It allows the application of custom business logic.

Note

For auditability or performance reasons, it can sometimes make sense to loop back the data and persist it in the data vault. This procedure is called Business Vault.

  1. Search Bar

    Filters the business ruleset list.

  2. Business Ruleset List

    Lists the existing business rulesets. Grouped by Business Object > System. Select a business ruleset from the list to see and edit its code with the editor.

  3. Business Ruleset Editor
    The editor displays the SQL-Code of the view and allows implementation of new business logic.
    By using the split-view icon-icon in the top right corner, a horizontal split-view can be activated.
    The search icon next to it (de-)activates the data preview of the result at the bottom.
    Often used Keyboard-Shortcuts

    Action

    Windows/Linux

    Mac

    Find

    Ctrl-F

    Cmd-F

    Replace

    Ctrl-H

    Cmd-Option-F

    Fold

    Alt-L

    Cmd-Option-L

    Go to Line

    Ctrl-L

    Cmd-L

    Remove line

    Ctrl-D

    Cmd-D

    Move line up, down

    Alt-Up, Alt-Down

    Option-Up, Option-Down

  4. Add Business Ruleset

    Opens up the creation dialogue for adding a business ruleset.

  5. Business Ruleset Properties

    Clicking onto the BR_properties_icon opens up the slider from the left, containing the business ruleset properties.

  1. Quick Inserts
    Quick inserts can be used to search for tables/views on the database you would like to join to.
    This panel is made up of a search box at the top and a list of tables/views.
    • You can add more entries to the list using the search field.

    • Expand the name of the available list entries to see the fields available within the object.

    • Use the plus-icon or double-click to add the element to the view.

Adding Business Rules

To be able to add a business ruleset, an underlying business object needs to be created first.

Steps
  1. Navigate to the Business Rules module and click onto “Add Business Ruleset”. Alternatively, you can click onto plus_icon in the business ruleset list. This will automatically complete the first two fields of the creation dialogue.

  2. Complete the creation dialogue.

  3. Modify the view code in the editor to implement business logic.


../_images/addBR.png
  1. Business Object

    Selection of the underlying business object to build the business ruleset on top of.

  2. System

    Declaration of the source system, to define, for which related business object the rule should be created.

  3. Business Ruleset Name

    Displayed name of the newly created business ruleset.

  4. Business Ruleset ID

    Technical suffix ID for the business ruleset, which will be added to the view-name on the database.

  5. Add Business Ruleset

    Button to complete the business ruleset creation.

Business Ruleset Properties

../_images/businessRuleset_properties.png
  1. Include in Accesslayer

    The button toggles, whether the specific business ruleset is fed into the accesslayer. If enabled, a priorization can be given. The priorization is used, when combining different business rulesets in the accesslayer: If two rulesets have a different result for a field, then the value of the higher priorized business ruleset is taken.

  2. Is Error-Ruleset

    Defines the ruleset to be an error-view. The error-view will be mirrored into the errormart, as well as combined into an accesslayer-like errormart-view.

  3. Comment

    Custom notes about the business ruleset

Deleting a Business Ruleset

Steps
  1. Click onto the trash bin located next to a business ruleset in the business ruleset list.

  2. Confirm the deletion.

The deletion of a business ruleset will:
  • Delete the business ruleset view

  • Remove the business ruleset from the accesslayer (if fed into the accesslayer)

  • Remove error-mart view (if declared as error-ruleset)