BOOLEAN data type

Informix®

Informix supports the BOOLEAN data type, which can store 't' or 'f' values.

Genero BDL implements the BOOLEAN data type in a different way: A BOOLEAN variable stores integer values 1 or 0 (for TRUE or FALSE). This type is designed to hold the result of a boolean expression.

IBM® DB2®

Starting with version 11.1.1.1, IBM DB2 supports the BOOLEAN SQL type.

Possible values are the TRUE/FALSE constants, '1'/'0' string literals and 1/0 numbers.

Solution

The database interface converts the BOOLEAN SQL type to CHAR(1) and stores '1' or '0' values in the column.

With versions before DB2 11.1, the database interface converts the BOOLEAN SQL type to CHAR(1) and stores '1' or '0' values in the column.

Starting with DB2 11.1, the database uses BOOLEAN keyword as is and the TRUE/FALSE keywords can be used.

The BOOLEAN type translation can be controlled with the following FGLPROFILE entry:
dbi.database.dsname.ifxemul.datatype.boolean = { true | false }
For more details see IBM Informix emulation parameters in FGLPROFILE.