LONG BINARY columns in queries

In WHERE clauses of the SELECT statement, LONG BINARY columns can only be used in IS NULL and IS NOT NULL expressions, in addition to the BYTE_LENGTH64, BYTE_SUBSTR64, BYTE_SUBSTR, BIT_LENGTH, OCTET_LENGTH, CHARINDEX, and LOCATE functions.

LONG BINARY columns cannot be used in the SELECT statement clauses ORDER BY, GROUP BY, and HAVING or with the DISTINCT keyword.

LIKE predicates are not supported on LONG BINARY (BLOB) columns. If you attempt to search for a pattern in a LONG BINARY column using a LIKE predicate, the error “Invalid data type comparison in predicate” is returned.

See “Function support of LONG BINARY data type” for more information on LONG BINARY data and functions.