57 for (
unsigned int i = 0; NULL != es[i].
sql; i++)
62 "Running statement `%s' on %p\n",
68 "Running statement `%s' on %p finished (%s)\n",
71 PQresStatus (PQresultStatus (
result)));
73 (PGRES_COMMAND_OK != PQresultStatus (
result)))
77 "Failed to execute `%s': %s/%s/%s/%s/%s",
79 PQresultErrorField (
result,
80 PG_DIAG_MESSAGE_PRIMARY),
81 PQresultErrorField (
result,
82 PG_DIAG_MESSAGE_DETAIL),
83 PQresultErrorMessage (
result),
84 PQresStatus (PQresultStatus (
result)),
85 PQerrorMessage (
db->conn));
static int result
Global testing status.
static struct GNUNET_FS_DirectoryBuilder * db
#define GNUNET_log(kind,...)
#define GNUNET_log_from(kind, comp,...)
GNUNET_GenericReturnValue
Named constants for return values.
@ GNUNET_ERROR_TYPE_ERROR
@ GNUNET_ERROR_TYPE_DEBUG
shared internal data structures of libgnunetpq
struct GNUNET_PQ_ExecuteStatement GNUNET_PQ_make_execute(const char *sql)
Create a struct GNUNET_PQ_ExecuteStatement where errors are fatal.
enum GNUNET_GenericReturnValue GNUNET_PQ_exec_statements(struct GNUNET_PQ_Context *db, const struct GNUNET_PQ_ExecuteStatement *es)
Request execution of an array of statements es from Postgres.
struct GNUNET_PQ_ExecuteStatement GNUNET_PQ_make_try_execute(const char *sql)
Create a struct GNUNET_PQ_ExecuteStatement where errors should be tolerated.
Handle to Postgres database.
Information needed to run a list of SQL statements using GNUNET_PQ_exec_statements().
const char * sql
Actual SQL statement.
int ignore_errors
Should we ignore errors?