---
title: "list_sum function in Strata | Oplema"
description: "Calculate the sum of the values in a list, returning one total. For example, list_sum([3,3,9]) returns 15. Works in a Strata Formula or Filter."
url: "https://oplema.com/docs/strata/functions/list-sum"
updated: "2026-11-04"
---

# list\_sum

Add up the values in a list.

## Try an expression

In [Formula](https://oplema.com/docs/strata/prep/formula), enter the expression and set Output type to **VARCHAR**.

### Expression

```
list_sum([3,3,9])
```

### Result

```
'15'
```

The expression returns `HUGEINT`. Formula stores it as `VARCHAR` in this example. To use your own data, replace the example values with column names. Keep format strings and other options as written.

Try it live in Formula

Result
| id | result |
| --- | --- |
| 1 | 15 |

## Arguments and types

```
list_sum(l)
```

**l**

Any value

Supported signatures (1)

```
list_sum(l: ANY)
```

The result type can depend on the input types. See DuckDB for the full argument rules.

## Things to know

If the first argument is missing, the result is NULL.

## Related functions

[list\_avg

Calculate the arithmetic mean from the values in a list.

](https://oplema.com/docs/strata/functions/list-avg)[list\_min

Calculate the smallest value from the values in a list.

](https://oplema.com/docs/strata/functions/list-min)[list\_max

Calculate the largest value from the values in a list.

](https://oplema.com/docs/strata/functions/list-max)[list\_count

Calculate the number of non-missing values from the values in a list.

](https://oplema.com/docs/strata/functions/list-count)

[Browse lists & arrays](https://oplema.com/docs/strata/functions#lists-&-arrays) [DuckDB documentation](https://duckdb.org/docs/current/sql/functions/list.html#list_sumlist)

Function metadata from DuckDB, used under the [MIT license](https://github.com/duckdb/duckdb/blob/v1.5.4/LICENSE).
