Home | Previous Page | Next Page   Client Functions > Functions for Smart Large Objects >

ifx_lo_write()

The ifx_lo_write() function writes data to an open smart large object.

Syntax

ifx_lo_write(lofd, buf) 

Arguments

The function accepts the following arguments.

Argument Type Use Description
lofd SQL_INTEGER Input Smart-large-object file descriptor
buf SQL_CHAR Input Buffer that contains the data that the function writes to the smart large object. The size of the buffer cannot exceed 2 gigabytes.

Usage

The ifx_lo_write() function writes data to an open smart large object. The write begins at the current seek position for lofd. You can call ifx_lo_tell() to obtain the current seek position.

The ifx_lo_write() function writes cbValueMax bytes of data. cbValueMax is an input argument for SQLBindParameter() and SQLBindCol(). Neither the size of buf nor cbValueMax can exceed 2 gigabytes. To write to a smart large object that is larger than 2 gigabytes, write to it in 2-gigabyte chunks. The ifx_lo_write() function gets the data from the user-defined buffer to which buf points.

If SQLExecDirect() or SQLExecute() returns SQL_SUCCESS_WITH_INFO, then the database server wrote less than cbValueMax bytes of data to the smart large object and pcbValue, which is an argument for each of these functions, contains the number of bytes that the function wrote. This condition can occur when the sbspace runs out of space.

Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]