A calculation formula in a row definition can include the +, -, *, and /operators, along with IF/THEN/ELSEstatements. Additionally, a calculation can involve individual cells and absolute amounts, which are actual numbers included in the formula. The formula can be up to 1024 characters long.
Calculations cannot be applied to rows that contain cells defined as the Link to Financial Dimensions(FD) type. However, you can place calculations on consecutive rows, suppress the printing of those rows, and then total the calculation rows for report purposes.
Operators in a calculation formula
A calculation formula uses more complex operators than a row total formula, but allows you to multiply ( *) and divide ( /) amounts with the additional operators.
To use a range or sum in a calculation formula, you must use the at sign ( @) in front of any row code, unless you are using a column in the row definition. For example, to add the amount in row 100 to the amount in row 330, you could use the row total formula 100+330, or the calculation formula @100+@330.
Note |
---|
You must use the at sign ( @) before each row code that you use in a calculation formula, or the number is read as a real number. For example, the formula @100+330would add $330 USD to the amount in row 100. |
When you reference a column in a calculation formula, the at sign ( @) is not required. For more information about columns in a calculation formula, see Select report columns in a row definition .
Create a calculation formula
-
In Report Designer, click Row Definitions, and then open the row definition to modify.
-
Double-click the Format Codecell and select CAL.
-
In the Related Formulas/Rows/Unitscell, type the calculation formula.
Example
The following is an example of a row definition that shows a total that includes a calculation.
Row Code |
Description |
Format Code |
Related Formulas/Rows/Unit |
Print Control |
Row Modifier |
Link to Financial Dimensions |
---|---|---|---|---|---|---|
340 |
Cash at Beginning of Period |
|
|
NP |
BB |
+Account=[1100:1110] |
370 |
Cash at Beginning of Year |
CAL |
@100+@330 |
NP |
|
|
400 |
Cash at Beginning of Period |
TOT |
340+370 |
|
|
In this example, the calculation formula @100+@330means that the amount in row 100 is added to row 330. The row total formula of 340+370adds the amount in row 340 to the amount in row 370, which includes the amount from the calculation formula.