Query Types for the Creation of Rule Templates

image_pdfimage_print

Related article: Rule Templates

The following query types are available to create a rule template, each allowing a different form of instantiation.

Name
Description
Domain
Example
Reference

Dimension element like

Set of elements from one dimension where the element name matches a regular expression pattern. Each matching element is returned as a record. If the regular expression pattern contains groups (also known as parenthesized subpatterns) the matching groups are returned, too.

     

Parameters

Dimension

Name of the dimension containing the set of elements.

db_dimension

Version

 
 

Pattern

RegEx pattern to filter elements from Dimension.
The example filters for all version starting with Budget or Forecast and will thus match elements like Forecast 3+9 or Budget 2013.

regex

^(Budget|Forecast)

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Element

Matching element.

     
 

Group1

1st matching group (parenthesized subpattern) of the regex pattern.

     
 

Group2

2nd matching group (parenthesized subpattern) of the regex pattern.

     
 

Up to 8 additional groups are possible.

     
         
Name
Description
Domain
Example
Reference

Dimension element
like (list)

Set of elements from one dimension where the element name matches a regular expression pattern. All matching elements are returned as a list in one record.

     

Parameters

Dimension

Name of the dimension containing the set of elements.

db_dimension

Version

 
 

Pattern

RegEx pattern to filter elements from Dimension.
The example filters for all version starting with Budget or Forecast and will thus match elements like Forecast 3+9 or Budget 2013.

regex

^(Budget|Forecast)

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Elements

Matching elements as a single quoted, comma separated list.
Example: ‘Budget’,’Forecast 3+9′,’Forecast 6+6′,’Forecast 9+3′.

     
         
Name
Description
Domain
Example
Reference

Dimension element
like attribute

Set of elements from one dimension where an attribute matches a regular expression pattern. Each matching element is returned as a record. If the regular expression pattern contains groups (also known as parenthesized subpatterns) the matching groups are returned, too.

     

Parameters

Dimension

Name of the dimension containing the set of elements.

db_dimension

Version

 
 

Attribute

Name of the attribute of dimension to be matched against the pattern.

dimension_attribute

Factor

{“dimension”: “Dimension”}

 

Pattern

RegEx pattern to match attribute values for elements of dimension.
The example filters for all version having 1.0 as attribute Factor.

regex

^1.0$

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Attribute

Name of the attribute.

     
 

Attribute value

Value of attribute matching the pattern.

     
 

Element

Element name of the queried dimension.

     
 

Group1

1st matching group (parenthesized subpattern) of the regex pattern.

     
 

Group2

2nd matching group (parenthesized subpattern) of the regex pattern.

     
 

Up to 8 additional groups are possible.

     
           
Name
Description
Domain
Example
Reference

Dimension element
like attribute (list)

Set of elements from one dimension where an attribute matches a regular expression pattern. All matching elements are returned as list in one record.

     

Parameters

Dimension

Name of the dimension containing the set of elements.

db_dimension

Version

 
 

Attribute

Name of the attribute of dimension to be matched against the pattern.

dimension_attribute

Factor

{“dimension”: “Dimension”}

 

Pattern

RegEx pattern to match attribute values for elements of dimension.
The example filters for all version having 1.0 as attribute Factor.

regex

^1.0$

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Attribute

Name of the attribute.

     
 

Elements

Matching elements as a single quoted, comma separated list.
Example: ‘Budget’,’Forecast 3+9′,’Forecast 6+6′,’Forecast 9+3′.

     
           
Name
Description
Domain
Example
Reference

Actual months

Returns a list of elements from a time dimension being lower or equal to an actual-months attribute of the version dimension. One record is returned for each version with an actual-months attribute.

     

Parameters

Version dimension

Name of the version dimension having an actual-month attribute.

cube_dimension

Version

 
 

Time dimension

Name of the time dimension containing the month elements. Month elements must match the pattern yyyy-MM or FYyyyy-MM.

cube_dimension

Month

 
 

Version dimension attribute

Attribute of version dimension with number of actual months (between 1 and 12).

dimension_attribute

Actual Months

{“dimension”: “Version dimension”}

Result

Cube

Name of the current cube.

     
 

VersionDimension

Name of the version dimension.

     
 

TimeDimension

Name of the time dimension.

     
 

ActualMonths

Non empty attribute value of the version dimension attribute.

     
 

Version

Element of the version dimension.

     
 

Elements

Months elements of the time dimension having a month less or equal to the actual-months attribute as a single quoted, comma separated list.
Example: ‘2016-01′,’2016-02′,’2016-03’.

     
           
Name
Description
Domain
Example
Reference

KPI calculation

Offers sophisticated calculations of a measure or account with a calculation expression. The calculation can optionally be restricted by dependencies.

     

Parameter

Dimension

This is the name of the dimension containing the calculated elements.
This dimension must have the Calculation attribute. Optionally it can also have a CalculationDependecies attribute.

cube_dimension

PnL account

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Element

Element name of the queried dimension.

     
 

Calculation

Expression in Jedox rule syntax.

     
           
Name
Description
Domain
Example
Reference

KPI calculation
(by Version)

Offers sophisticated calculations of a measure or account with a calculation expression. The calculations can be defined by calculation schema, which is an attribute of the Version dimension. The calculation can optionally be restricted by dependencies.

     

Parameter

Dimension

This is the name of the dimension containing the calculated elements.
This dimension must have a SCalculation attribute where S is the Calculation Schema for a version. For each Calculation Schema used in the Version attribute there must be a corresponding Calculation attribute. Optionally it can also have a SCalculationDependecies attributes.

cube_dimension

PnL account

 

Result

Cube

Name of the current cube.

     
 

Dimension

Name of the queried dimension.

     
 

Element

Element name of the queried dimension.

     
 

CalculationSchema

Calculation schema.
Example: A.

     
 

Versions

Version elements sharing the same Calculation Schema as a single quoted, comma separated list.
Example: ‘Budget’,’Forecast 3+9′,’Forecast 6+6′,’Forecast 9+3′.

     
 

Calculation

Expression in Jedox rule syntax.

     
           
Name
Description
Domain
Example
Reference

Attribute like

Set of attributes of a dimension where the attribute matches a regular expression pattern. Each matching attribute is returned as a record. If the regular expression pattern contains groups (also known as parenthesized subpatterns) the matching groups are returned, too.

     

Parameter

Pattern

RegEx pattern to match attributes.

regex

^ID_(Name)$

 

Result

Cube

Name of the current attribute cube.

     
 

Dimension

Name of the attributed dimension.

     
 

AttributeDimension

Name of the attribute dimension.

     
 

Attribute

Name of the attribute matching the pattern.

     
 

Group1

1st matching group (parenthesized subpattern) of the regex pattern.

     
 

Group2

2nd matching group (parenthesized subpattern) of the regex pattern.

     
  Up to 8 additional groups are possible.      
           
Name
Description
Domain
Example
Reference

Initial months

Returns a list of the first periods of each fiscal year from a time dimension. If the fiscal year feature is not used a list of January elements is returned.

     

Parameter

Time dimension

Name of the time dimension containing the month elements. Month elements must match the pattern yyyy-MM or FYyyyy-MM.

cube_dimension

Month

 

Result

Cube

Name of the current cube.

     
 

TimeDimension

Name of the time dimension.

     
 

Elements

Months elements of the time dimension being the first periods of each fiscal year as a single quoted, comma separated list.
Example: ‘2016-01′,’2017-01′,’2018-01’.

     

 

image_pdfimage_print
Was this post helpful?
NoYes (-1 rating, 5 votes)
Loading...