boolean type
boolean
data expresses a binary value of either TRUE
or FALSE
.
Detail | Info |
---|---|
Quick Syntax | TRUE or FALSE |
Size | 1 byte |
Aliases | bool |
Catalog name | pg_catalog.bool |
OID | 16 |
Syntax
Details
Valid casts
From boolean
You can cast from boolean
to:
To boolean
You can cast the following types to boolean
:
Examples
SELECT TRUE AS t_val;
t_val
-------
t
SELECT FALSE AS f_val;
f_val
-------
f