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

> Reference material for ARRAY_CONTAINS function

# ARRAY_CONTAINS

Returns `true` if a specified argument is present in the array, or `false` otherwise. Note that `ARRAY_CONTAINS` employs `IS NOT DISTINCT FROM` semantics when comparing values, i.e. `NULL` is considered equal to `NULL`.

**Alias:** `CONTAINS`

## Syntax

```sql theme={"theme":{"light":"css-variables","dark":"css-variables"}}
ARRAY_CONTAINS(<array>, <value>)
```

## Parameters

| Parameter | Description                                     | Supported input types                                           |
| :-------- | :---------------------------------------------- | :-------------------------------------------------------------- |
| `<array>` | The array to be checked for the given element.  | `ARRAY`                                                         |
| `<value>` | The element to be searched for within the array | Any type that can be converted to the element type of the array |

## Return Type

The `BOOLEAN` value `true` if the element to be searched is present in the array, or `false` otherwise.

## Examples

Returns `true`, since `'danielle53'` is an element of the input array:

<div className="query-window">
  ```
  SELECT ARRAY_CONTAINS(['sabrina21', 'rileyjon', 'ywilson', 'danielle53', NULL], 'danielle53');
  ```

  | array\_contains <span>boolean</span> |
  | :----------------------------------- |
  | True                                 |

  <p><span>Rows: 1</span><span>Execution time: 5.39ms</span></p>
</div>

Returns `false`, since `'danielle53'` is not an element of the input array:

<div className="query-window">
  ```
  SELECT ARRAY_CONTAINS(['sabrina21', 'rileyjon', 'ywilson', NULL], 'danielle53');
  ```

  | array\_contains <span>boolean</span> |
  | :----------------------------------- |
  | False                                |

  <p><span>Rows: 1</span><span>Execution time: 41.26ms</span></p>
</div>

Returns `true`, since `NULL` is an element of the input array:

<div className="query-window">
  ```
  SELECT ARRAY_CONTAINS(['sabrina21', 'rileyjon', 'ywilson', NULL], NULL);
  ```

  | array\_contains <span>boolean</span> |
  | :----------------------------------- |
  | True                                 |

  <p><span>Rows: 1</span><span>Execution time: 10.20ms</span></p>
</div>
