The ifx_lo_truncate() function

The ifx_lo_truncate() function truncates a smart large object at the specified position.

Syntax

ifx_lo_truncate(lofd, offset)

Arguments

The function accepts the following arguments.
Argument Type Use Description
lofd SQL_INTEGER Input Smart-large-object file descriptor
offset SQL_BIGINT Input End of the smart large object. If this value exceeds the end of the smart large object, the function extends the smart large object. If this value is less than the end of the smart large object, the database server reclaims all storage from the offset position to the end of the smart large object.

Instead of using the default Informix® ODBC Driver C data type of SQL_C_CHAR for offset, use SQL_C_LONG or SQL_C_SHORT.

Usage

The ifx_lo_truncate() function sets the end of a smart large object to the location that the offset argument specifies.