lo_lseek

Function

Change the current read or write position of a large object descriptor.

Prototype

int lo_lseek(PGconn* conn, int fd, int offset, int whence);

Parameter

Table 1 lo_lseek parameters

Keyword

Parameter Description

conn

A database connection

fd

File descriptor

offset

Move the current position pointer of the file descriptor to the new position specified by offset

whence

Anchor from the beginning of the object, from the current position, or from the end of the object

Return Value

int The return value is the new location pointer, or -1 on error.

lo_lseek64

Function

Change the current read or write position of a large object descriptor that may exceed 2GB in size.

Prototype

long int lo_lseek64(PGconn *conn, int fd, long int offset, int whence);

Parameter

Table 1 lo_lseek64 parameter

Keyword

Parameter Description

conn

A database connection

fd

File descriptor

offset

Move the current position pointer of the file descriptor to the new position specified by offset

whence

Anchor from the beginning of the object, from the current position, or from the end of the object

Return Value

int The return value is the new location pointer, or -1 on error.

Example

For details, see Example.

Feedback
编组 3备份
    openGauss 2024-05-19 00:42:09
    cancel