The ifx_lo_release() function

The ifx_lo_release() function tells the database server to release the resources associated with a temporary smart large object.

Syntax

mint ifx_lo_release(LO_ptr)
   ifx_lo_t *LO_ptr;
LO_ptr
The LO-pointer structure for the smart large object for which you want to release resources.

Usage

The ifx_lo_release() function is useful for telling the database server when it is safe to release resources associated with temporary smart large objects. A temporary smart large object is one that has one or more LO handles, none of which have been inserted into a table. Temporary smart large objects can occur in the following ways:
  • You create a smart large object with ifx_lo_create() but do not insert its LO handle into a column of the database.
  • You invoke a user-defined routine that creates a smart large object in a query but never assigns its LO handle to a column of the database.
For example, the following query creates one smart large object for each row in the table1 table and sends each one to the client application:
SELECT filetoblob(...) FROM table1;

The client application can use the ifx_lo_release() function to indicate to the database server when it finishes processing each of these smart large objects. After you call this function on a temporary smart large object, the database server can release the resources at any time. Further use of the LO handle and any associated LO file descriptors is not guaranteed to work.

Use of this function on smart large objects that are not temporary does not cause any incorrect behavior. However, the call is expensive and is not needed for permanent smart large objects.

Return codes

0
The function was successful.
< 0
The function was not successful.