> For the complete documentation index, see [llms.txt](https://helpcenter.channable.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://helpcenter.channable.com/manage-improve-product-data/manage-product-and-improve-data-nl/regels-bulkbewerken-en-verrijken/how-to-use-actions-then-in-rules/berekenacties/rule-action-calculate-list-length.md).

# Bereken lengte van een lijstveld

Tel alle of unieke waarden in een lijstveld.

gebruik **`bereken lengte van lijst`** om waarden in een veld van het type Lijst te tellen.

Deze actie is handig voor taken zoals:

* Beschikbare productmaten of afbeeldings-URL's tellen.
* Unieke waarden tellen en dubbele waarden negeren.

***

## Voorbeeld `bereken lengte van lijst` gebruiksscenario's

{% hint style="info" %}

#### Tip

Selecteer de optie voor unieke waarden als dubbele waarden niet moeten meetellen.
{% endhint %}

{% hint style="info" icon="lightbulb" %}

#### Tip

Toevoegen **`item groep samenstellen`** ervoor **`bereken lengte van lijst`**. Het lijstveld moet bestaan voordat je de waarden ervan kunt tellen.
{% endhint %}

### Beschikbare maten tellen

Gebruik deze regel wanneer elk item een waarde heeft in het `size` veld. Gebruik eerst [Itemgroepen maken](https://helpcenter.channable.com/manage-improve-product-data/manage-product-and-improve-data-nl/regels-bulkbewerken-en-verrijken/how-to-use-actions-then-in-rules/itemacties/rule-action-build-item-group.md) om de `size` waarden te verzamelen van items met dezelfde `item_group_ID` in een nieuwe `size_list` veld. Dan, gebruik **`bereken lengte van lijst`** om de waarden te tellen in `size_list` en sla het aantal op in `size_count`.

#### Hoe je een Regel aanmaakt

* Voorwaarde: **`Voor alle Items`**
* Actie: DAN **`item groep samenstellen`** op basis van `item_group_ID` van `size` en zet in `size_list`
* Actie: DAN **`bereken lengte van lijst`** van `size_list` en zet in `size_count`

### Tel unieke afbeeldings-URL's

Gebruik deze regel wanneer elk item een waarde heeft in het `image_url` veld. Gebruik eerst **`Item groep samenstellen`** om de `image_url` waarden te verzamelen van items met dezelfde `item_group_ID` in een nieuwe `image_url_list` veld. Dan tel je de unieke waarden in `image_url_list` en sla het aantal op in `image_count`.

#### Hoe je een Regel aanmaakt

* Voorwaarde: **`Voor alle Items`**
* Actie: DAN **`item groep samenstellen`** op basis van `item_group_ID` van veld `image_url` en zet in `image_url_Lijst`
* Actie: DAN **`bereken lengte van lijst`** van unieke waarden in `image_url_list` en zet in `image_count`


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://helpcenter.channable.com/manage-improve-product-data/manage-product-and-improve-data-nl/regels-bulkbewerken-en-verrijken/how-to-use-actions-then-in-rules/berekenacties/rule-action-calculate-list-length.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
