Sum

Syntax

Sum(Index|Value|Section|Delimiter)

Description

Sum works with the HTMLTable indexes.

Note:

In PeopleTools releases prior to 8.53 commas were supported as a delimiter for the sum function parameters. If any tests exist in the database using that format, the commas will be converted to pipes in the upgrade.

Parameters

Parameter Description

Index

The HTMLTable index string, such as 2/5/4. An index string is the return value of CellGetIndex.

See CellGetIndex.

Value

The value that you want to add or subtract. The default action is addition.

Section

The section of the index that will be modified.

Delimiter

The character that delimits each section in the text value.

The character must be enclosed in quotes.

Example

The following table presents examples of using the Sum function.

Expression Result

sum("2/5/4"|2|1|"/")

4/5/4

2 is added to the first section of the string.

sum("2/5/4"|-1|3|"/")

2/5/3

1 is subtracted from the third section of the string.

Sum(&index|-4|3|"/")

4 is subtracted from the third section of the string in the variable &index.