Framework:RowBased: Difference between revisions

From CoPlanner 11
Jump to navigationJump to search
No edit summary
No edit summary
 
(One intermediate revision by the same user not shown)
Line 8: Line 8:
|-
|-
|Dimension 1 to Dimension n
|Dimension 1 to Dimension n
|Optional: If you define dimensions, the mapping is made with these dimensions. If nothing ist defined, the mapping is made with all dimensions with the same alias in the table.
|Optional: If you define dimensions, the mapping is made with these dimensions. If nothing is defined, the mapping is made with all dimensions with the same alias in the table.
|-
|-
|Expression
|Expression
|Expression, wich will be executed.
|Expression, which will be executed.
|}
|}
This function belongs to [[:Category:Functions_-_client-side|client-side functions]].
This function belongs to [[:Category:Functions_-_client-side|client-side functions]].
Line 20: Line 20:
==Example==
==Example==


Tow tables are available, a table with quantities and a table with prices. Both tables contain the dimensions product, time and company. The Input mask should contain the measures Quantity, Price and Revenue.
Two tables are available, a table with quantities and a table with prices. Both tables contain the dimensions product, time and company. The Input mask should contain the measures Quantity, Price and Revenue.


The CoPlanner Cube has to contain the tables quantity and price, all dimensions have to be matched. Following measures have to be defined:
The CoPlanner Cube has to contain the tables quantity and price, all dimensions have to be matched. Following measures have to be defined:
Line 26: Line 26:
{| class="wikitable" width={{{breite|80%}}}
{| class="wikitable" width={{{breite|80%}}}
|- {{Tabellentitel}}
|- {{Tabellentitel}}
| Typ
| Type
| Field
| Field
| Caption-Property
| Caption-Property
Line 51: Line 51:
| Price
| Price
| True
| True
| <span {{CoPFormel}}>[Priceorg]=WAP([Price])</span>
| <span {{CoPFormel}}>[Price org]=WAP([Price])</span>
| <span {{CoPFormel}}>FKT_CIF([Quantity]=0,[Price org],[Revenue]/[Quantity])</span>
| <span {{CoPFormel}}>FKT_CIF([Quantity]=0,[Price org],[Revenue]/[Quantity])</span>
|-
|-

Latest revision as of 12:56, 18 October 2012

Function

RowBased(<Dimension 1>,..,<Dimension n>)=Expression

Parameter Description
Dimension 1 to Dimension n Optional: If you define dimensions, the mapping is made with these dimensions. If nothing is defined, the mapping is made with all dimensions with the same alias in the table.
Expression Expression, which will be executed.

This function belongs to client-side functions.

Redult

Returns the result of the expression on the basis of leaf-elements.

Example

Two tables are available, a table with quantities and a table with prices. Both tables contain the dimensions product, time and company. The Input mask should contain the measures Quantity, Price and Revenue.

The CoPlanner Cube has to contain the tables quantity and price, all dimensions have to be matched. Following measures have to be defined:

Type Field Caption-Property Visible-Property CalcBackExpression-Property Expression-Property
Measure Quantity from quantity table Quantity True
Measure Price from price table Price org False
Calculated Measure Price True [Price org]=WAP([Price]) FKT_CIF([Quantity]=0,[Price org],[Revenue]/[Quantity])
Calculated Measure Revenue True [Quantity]=[Revenue]/[Price] RowBased=[Quantity]*[Price org]

Description

Formula RowBased=[Quantity]*[Price org]: The base of calculation of the revenues are leaf-elements. Because of no definition of dimensions, all dimensions with the same alias will be matched.

Formula RowBased(Period,Products)=[Quantity]*[Price org]: The base of calculation of the revenues are leaf-elements. Because of definition of dimensions Period and Products only these two dimensions will be matched.