# TO_BOOLEAN

Converts an input value to a boolean value. A string value of `true` is case-insensitively converted to the Boolean `true`. Any other string, including the empty string, returns `false`. The numerical value `0` is converted to `false`, while any other number is converted to `true`.

## Syntax

`TO_BOOLEAN(field)`

### Parameters

#### field

Input value to be converted. The input can be a single- or multi-valued column or an expression.

## Examples

Converts each string in the list to its boolean equivalent, where only case-insensitive "true" becomes true and all other values become false.

```esql
ROW str = ["true", "TRuE", "false", "", "yes", "1"]
| EVAL bool = TO_BOOLEAN(str)
```