Application Integration
- Application Integration
- All Products
fn:sum(arg, zero)
Argument | Required/Optional | Description |
|---|---|---|
arg
| Required | Numeric data type. Passes the values you want to add. You can
enter any valid transformation expression. You can use operators
to add values in different fields. |
zero | Required | The return condition for an empty sequence. If
$zero is not specified, the value returned
for an empty sequence is the xs:integer value
0. If $zero is specified, the value returned
for an empty sequence is $zero . |
|
|
|---|---|
fn:sum( (1, 2, 3) ) | 6 |
fn:sum( (1, 2, 3, () ) ) | 6 |
fn:sum( () ) | 0 |
fn:sum( (), () ) | () |
sum( SALES, SALES > 2000 )
|
|---|
|
|
|
|
|
|
|
sum( QTY * PRICE - DISCOUNT )