1/*--------------------------------------------------------------------------
3 * test_copy_callbacks.c
4 * Code for testing COPY callbacks.
6 * Portions Copyright (c) 1996-2025, PostgreSQL Global Development Group
7 * Portions Copyright (c) 1994, Regents of the University of California
10 * src/test/modules/test_copy_callbacks/test_copy_callbacks.c
12 * -------------------------------------------------------------------------
28 (
errmsg(
"COPY TO callback called with data \"%s\" and length %d",
uint64 DoCopyTo(CopyToState cstate)
CopyToState BeginCopyTo(ParseState *pstate, Relation rel, RawStmt *raw_query, Oid queryRelId, const char *filename, bool is_program, copy_data_dest_cb data_dest_cb, List *attnamelist, List *options)
void EndCopyTo(CopyToState cstate)
int errmsg(const char *fmt,...)
#define ereport(elevel,...)
#define RelationGetRelid(relation)
void table_close(Relation relation, LOCKMODE lockmode)
Relation table_open(Oid relationId, LOCKMODE lockmode)
Datum test_copy_to_callback(PG_FUNCTION_ARGS)
static void to_cb(void *data, int len)
PG_FUNCTION_INFO_V1(test_copy_to_callback)