Method
PgsqlConnectioncopy_out
Declaration
DexFuture*
pgsql_connection_copy_out (
PgsqlConnection* self,
const char* sql,
GOutputStream* output_stream
)
Description
Executes a COPY TO STDOUT operation on the connection.
This function sends the provided SQL statement, which must be a valid
COPY ... TO STDOUT statement (including COPY (SELECT ...) TO STDOUT
variants). It then reads data from the server and writes it to
output_stream until the COPY operation completes.
Parameters
sql-
Type:
const char*The COPY TO STDOUT SQL statement.
The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. output_stream-
Type:
GOutputStreamA
GOutputStreamto write data to.The data is owned by the caller of the method.