DB TM1 Function: Use and Syntax
The DB function returns the contents from a specific intersection in a TM1 cube (either string or numeric). It allows you to interrogate one TM1 cube from another and return a value from a specific intersection from the source cube.
For example, you might have an assumption cube with a standard Wage Increase of 5% and you want to apply that to all of your employees. Using a DB within the rules of your Labour cube will allow you to pull that standard wage increase into the Labour cube for all employees. In this way it is entered once in the assumption cube and used everywhere.
Syntax of DB
The syntax is DB (cube, element1, element2, element3, elementn); where
- cube is the cube you want to look up the value from
- element1 is an element from the first dimension of the source cube
- element2 is an element from the second dimension of the source cube
- element3 is an element from the third dimension of the source cube
- elementn are the elements from subsequent dimensions in order from the source cube
An example is DB (‘Opex’, !Year, !Month, ‘Actual’, !Opex Account, !Cost Centre, !Measures Opex ); which will return the value from the Opex cube that corresponds to the currently addressed values in the Year, Month, Opex Account, Cost Centre and Measures Opex for the ‘Actual’ element from the scenario dimension.