The ifx_lo_seek() function

The ifx_lo_seek() function sets the file position for the next read or write operation on the open smart large object.

Syntax

mint ifx_lo_seek(LO_fd, offset, whence, seek_pos)
   mint LO_fd;
   ifx_int8_t *offset;
   mint whence;
   ifx_int8_t *seek_pos;
LO_fd
The LO file descriptor for the smart large object whose seek position you want to change.
offset
A pointer to the 8-byte integer offset from the starting seek position.
whence
A mint value that identifies the starting seek position.
seek_pos
A pointer to the resultant 8-byte integer offset, relative to the start of the file, that corresponds to the position for the next read/write operation.

Usage

The function uses the whence and offset arguments to determine the seek position, as follows:
  • The whence value identifies the position from which to start the seek.
    Valid values include the following constants, which the locator.h header file defines.
    Whence constant
    Starting seek position
    LO_SEEK_SET
    The start of the smart large object
    LO_SEEK_CUR
    The current seek position in the smart large object
    LO_SEEK_END
    The end of the smart large object
    • The offset argument identifies the offset, in bytes, from the starting seek position (that the whence argument specifies) at which to begin the seek position.

The ifx_lo_tell() function returns the current seek position for an open smart large object.

Return codes

0
The function was successful.
<0
The function was not successful and the return value indicates the cause of the failure.