You've already forked pgbackrest
mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-07-05 00:28:52 +02:00
Add Db object to encapsulate PostgreSQL queries and commands.
Migrate functionality from the Perl Db module to C. For now this is just enough to implement the WAL switch check. Add the dbGet() helper function to get Db objects easily. Create macros in harnessPq to make writing pq scripts easier by grouping commonly used functions together. Reviewed by Cynthia Shang.
This commit is contained in:
@ -8,6 +8,10 @@ casts to queries to output one of these types.
|
||||
#ifndef POSTGRES_QUERY_H
|
||||
#define POSTGRES_QUERY_H
|
||||
|
||||
#include "common/type/string.h"
|
||||
#include "common/type/variantList.h"
|
||||
#include "common/time.h"
|
||||
|
||||
/***********************************************************************************************************************************
|
||||
Object type
|
||||
***********************************************************************************************************************************/
|
||||
@ -29,6 +33,8 @@ PgClient *pgClientOpen(PgClient *this);
|
||||
VariantList *pgClientQuery(PgClient *this, const String *query);
|
||||
void pgClientClose(PgClient *this);
|
||||
|
||||
PgClient *pgClientMove(PgClient *this, MemContext *parentNew);
|
||||
|
||||
/***********************************************************************************************************************************
|
||||
Destructor
|
||||
***********************************************************************************************************************************/
|
||||
|
Reference in New Issue
Block a user