---
title: "List Container Rules"
slug: "list-container-rules"
description: "This document discusses List Container Rules and how to use them. List Container Rules are designed to go through a list of items, and add a desired condition to each one; those conditions are Contains All, Contains Any, and Does Not Contain Any. "
updated: 2025-06-17T18:01:01Z
published: 2025-06-17T18:01:01Z
---

> ## Documentation Index
> Fetch the complete documentation index at: https://documentation.decisions.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List Container Rules

## Overview

**List Container Rules** are implemented in Decisions in the Rule Engine. These Rules are designed to process a list of items and apply desirable conditions to each item in the list. The List Container Rules have three options:

- **Contains All** – Each item in the list should satisfy the condition for Rule to evaluate as True.
- **Contains Any** – At least one item in the list should satisfy the condition for Rule to evaluate as True.
- **Does Not Contain Any** – None of the items on the list should satisfy the condition for Rule to evaluate as True.

---

## Example

In this example, the Rule will take in an array of Accounts. It should evaluate as True if all Accounts in the array have an email address that contains “decisions”. This example requires List Container Rules to test each Account in the array. Below is a downloadable example to [import](/v9/docs/importing-and-exporting-projects) into Decisions.

[List Container Rules-07042020-042501.zip](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/List%20Container%20Rules-07042020-042501.zip)

1. In a Designer Folder, select **CREATE RULE** from the top action bar. When the **Create Rule** window appears, select **Statement Rule,**enter a name for the Rule (List Container Rule) and click **CREATE**.
2. In the **Rule Designer**, select **SETUP INPUT DATA**.  
![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h36_02.png)
3. Click **DEFINE** under Define Input Data on the **Rule Input Data** dialog box that appears.
4. To set up the data, enter Accounts in the Name field. Next, click the dropdown list under Type and search for "account". Select Account and click **PICK**.
5. Next, check the **Is List** checkbox, this will enable this data to be an array that will display the Contains All, Contains Any, or Does not Contain Any as options when selecting the condition to check.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h55_32.png)
6. Click **Save** then close the Input Data Designer window.
7. Click the **Select Data Element** dropdown. Choose Accounts then click **NEXT**.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h56_05.png)
8. Choose the **Contains All** option under the **List Container Rules** category and select NEXT.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h56_27.png)
9. Under the **Collection Information** category, in the **Each List Item Name** field, enter "Email" as the Item Name and select **DONE**.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h56_49.png)
10. Click CLOSE to save the Rule statement.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h57_12.png)
11. In the new **If Statement** block, click **Add** and then choose **Add Condition.** Each item passed through the Rule will need to pass this condition that will check to see if Account.EmailAddress contains "decisions".![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h58_05.png)
12. Click Select Data Element, click Email, then scroll down to select **EmailAddress****[String]**. Click NEXT.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h58_31.png)
13. Select the **Contains** option under the **Text Rules** category then click NEXT.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h58_54.png)
14. Under the **Inputs**category, enter "decisions.com" as the value and select DONE.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_13h59_35.png)
15. Click CLOSE to save the Rule and return to the Rule Designer.

### Debug

1. To ensure the Rule works, select **Debug** on the top panel of the Rule Designer.
2. To add accounts to test, click **ADD NEW** under Accounts.
3. Enter a name in the Name field. Under the Settings category, enter an email address under the EmailAddress field.
4. Click DEFINE to save.
5. After adding the desired number of accounts, click **START DEBUGGING**.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_14h00_19.png)
6. The Rule runs and stops at the first False result evaluating the entire Rule as False since the Rule was built using the Contains All option and the email that was first found did not match the condition.![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/2025-06-17_14h00_45.png)

---

For further information on Rules, visit the [Decisions Forum](https://community.decisions.com/categories/Rules).
