# IF\_ELSE

If there is a **true** Boolean value in the **condition** parameter, then return the second argument; in all other cases, return the third argument

## Syntax

```
IF_ELSE(condition, true_value, false_value)
```

## Arguments

| Name | Type | Description | Default Value |
| --- | --- | --- | --- |
| condition | Boolean | If this is true, return the second argument, otherwise return the third argument. |  |
| true\_value | any | The value to return when the condition is true |  |
| false\_value | any | The value to return when the condition is not true |  |

## Examples

| condition | true\_value | false\_value | Output |
| --- | --- | --- | --- |
| true | 'foo' | 'bar' | `foo` |
| false | 'foo' | 'bar' | `bar` |
| null::Boolean | 'foo' | 'bar' | `bar` |