PostgreSQL Source Code  git master
libpq-fe.h
Go to the documentation of this file.
1 /*-------------------------------------------------------------------------
2  *
3  * libpq-fe.h
4  * This file contains definitions for structures and
5  * externs for functions used by frontend postgres applications.
6  *
7  * Portions Copyright (c) 1996-2023, PostgreSQL Global Development Group
8  * Portions Copyright (c) 1994, Regents of the University of California
9  *
10  * src/interfaces/libpq/libpq-fe.h
11  *
12  *-------------------------------------------------------------------------
13  */
14 
15 #ifndef LIBPQ_FE_H
16 #define LIBPQ_FE_H
17 
18 #ifdef __cplusplus
19 extern "C"
20 {
21 #endif
22 
23 #include <stdio.h>
24 
25 /*
26  * postgres_ext.h defines the backend's externally visible types,
27  * such as Oid.
28  */
29 #include "postgres_ext.h"
30 
31 /*
32  * These symbols may be used in compile-time #ifdef tests for the availability
33  * of newer libpq features.
34  */
35 /* Indicates presence of PQenterPipelineMode and friends */
36 #define LIBPQ_HAS_PIPELINING 1
37 /* Indicates presence of PQsetTraceFlags; also new PQtrace output format */
38 #define LIBPQ_HAS_TRACE_FLAGS 1
39 /* Indicates that PQsslAttribute(NULL, "library") is useful */
40 #define LIBPQ_HAS_SSL_LIBRARY_DETECTION 1
41 
42 /*
43  * Option flags for PQcopyResult
44  */
45 #define PG_COPYRES_ATTRS 0x01
46 #define PG_COPYRES_TUPLES 0x02 /* Implies PG_COPYRES_ATTRS */
47 #define PG_COPYRES_EVENTS 0x04
48 #define PG_COPYRES_NOTICEHOOKS 0x08
49 
50 /* Application-visible enum types */
51 
52 /*
53  * Although it is okay to add to these lists, values which become unused
54  * should never be removed, nor should constants be redefined - that would
55  * break compatibility with existing code.
56  */
57 
58 typedef enum
59 {
62  /* Non-blocking mode only below here */
63 
64  /*
65  * The existence of these should never be relied upon - they should only
66  * be used for user feedback or similar purposes.
67  */
68  CONNECTION_STARTED, /* Waiting for connection to be made. */
69  CONNECTION_MADE, /* Connection OK; waiting to send. */
70  CONNECTION_AWAITING_RESPONSE, /* Waiting for a response from the
71  * postmaster. */
72  CONNECTION_AUTH_OK, /* Received authentication; waiting for
73  * backend startup. */
74  CONNECTION_SETENV, /* This state is no longer used. */
75  CONNECTION_SSL_STARTUP, /* Negotiating SSL. */
76  CONNECTION_NEEDED, /* Internal state: connect() needed */
77  CONNECTION_CHECK_WRITABLE, /* Checking if session is read-write. */
78  CONNECTION_CONSUME, /* Consuming any extra messages. */
79  CONNECTION_GSS_STARTUP, /* Negotiating GSSAPI. */
80  CONNECTION_CHECK_TARGET, /* Checking target server properties. */
81  CONNECTION_CHECK_STANDBY /* Checking if server is in standby mode. */
83 
84 typedef enum
85 {
87  PGRES_POLLING_READING, /* These two indicate that one may */
88  PGRES_POLLING_WRITING, /* use select before polling again. */
90  PGRES_POLLING_ACTIVE /* unused; keep for awhile for backwards
91  * compatibility */
93 
94 typedef enum
95 {
96  PGRES_EMPTY_QUERY = 0, /* empty query string was executed */
97  PGRES_COMMAND_OK, /* a query command that doesn't return
98  * anything was executed properly by the
99  * backend */
100  PGRES_TUPLES_OK, /* a query command that returns tuples was
101  * executed properly by the backend, PGresult
102  * contains the result tuples */
103  PGRES_COPY_OUT, /* Copy Out data transfer in progress */
104  PGRES_COPY_IN, /* Copy In data transfer in progress */
105  PGRES_BAD_RESPONSE, /* an unexpected response was recv'd from the
106  * backend */
107  PGRES_NONFATAL_ERROR, /* notice or warning message */
108  PGRES_FATAL_ERROR, /* query failed */
109  PGRES_COPY_BOTH, /* Copy In/Out data transfer in progress */
110  PGRES_SINGLE_TUPLE, /* single tuple from larger resultset */
111  PGRES_PIPELINE_SYNC, /* pipeline synchronization point */
112  PGRES_PIPELINE_ABORTED /* Command didn't run because of an abort
113  * earlier in a pipeline */
115 
116 typedef enum
117 {
118  PQTRANS_IDLE, /* connection idle */
119  PQTRANS_ACTIVE, /* command in progress */
120  PQTRANS_INTRANS, /* idle, within transaction block */
121  PQTRANS_INERROR, /* idle, within failed transaction */
122  PQTRANS_UNKNOWN /* cannot determine status */
124 
125 typedef enum
126 {
127  PQERRORS_TERSE, /* single-line error messages */
128  PQERRORS_DEFAULT, /* recommended style */
129  PQERRORS_VERBOSE, /* all the facts, ma'am */
130  PQERRORS_SQLSTATE /* only error severity and SQLSTATE code */
132 
133 typedef enum
134 {
135  PQSHOW_CONTEXT_NEVER, /* never show CONTEXT field */
136  PQSHOW_CONTEXT_ERRORS, /* show CONTEXT for errors only (default) */
137  PQSHOW_CONTEXT_ALWAYS /* always show CONTEXT field */
139 
140 /*
141  * PGPing - The ordering of this enum should not be altered because the
142  * values are exposed externally via pg_isready.
143  */
144 
145 typedef enum
146 {
147  PQPING_OK, /* server is accepting connections */
148  PQPING_REJECT, /* server is alive but rejecting connections */
149  PQPING_NO_RESPONSE, /* could not establish connection */
150  PQPING_NO_ATTEMPT /* connection not attempted (bad params) */
152 
153 /*
154  * PGpipelineStatus - Current status of pipeline mode
155  */
156 typedef enum
157 {
162 
163 /* PGconn encapsulates a connection to the backend.
164  * The contents of this struct are not supposed to be known to applications.
165  */
166 typedef struct pg_conn PGconn;
167 
168 /* PGresult encapsulates the result of a query (or more precisely, of a single
169  * SQL command --- a query string given to PQsendQuery can contain multiple
170  * commands and thus return multiple PGresult objects).
171  * The contents of this struct are not supposed to be known to applications.
172  */
173 typedef struct pg_result PGresult;
174 
175 /* PGcancel encapsulates the information needed to cancel a running
176  * query on an existing connection.
177  * The contents of this struct are not supposed to be known to applications.
178  */
179 typedef struct pg_cancel PGcancel;
180 
181 /* PGnotify represents the occurrence of a NOTIFY message.
182  * Ideally this would be an opaque typedef, but it's so simple that it's
183  * unlikely to change.
184  * NOTE: in Postgres 6.4 and later, the be_pid is the notifying backend's,
185  * whereas in earlier versions it was always your own backend's PID.
186  */
187 typedef struct pgNotify
188 {
189  char *relname; /* notification condition name */
190  int be_pid; /* process ID of notifying server process */
191  char *extra; /* notification parameter */
192  /* Fields below here are private to libpq; apps should not use 'em */
193  struct pgNotify *next; /* list link */
195 
196 /* Function types for notice-handling callbacks */
197 typedef void (*PQnoticeReceiver) (void *arg, const PGresult *res);
198 typedef void (*PQnoticeProcessor) (void *arg, const char *message);
199 
200 /* Print options for PQprint() */
201 typedef char pqbool;
202 
203 typedef struct _PQprintOpt
204 {
205  pqbool header; /* print output field headings and row count */
206  pqbool align; /* fill align the fields */
207  pqbool standard; /* old brain dead format */
208  pqbool html3; /* output html tables */
209  pqbool expanded; /* expand tables */
210  pqbool pager; /* use pager for output if needed */
211  char *fieldSep; /* field separator */
212  char *tableOpt; /* insert to HTML <table ...> */
213  char *caption; /* HTML <caption> */
214  char **fieldName; /* null terminated array of replacement field
215  * names */
217 
218 /* ----------------
219  * Structure for the conninfo parameter definitions returned by PQconndefaults
220  * or PQconninfoParse.
221  *
222  * All fields except "val" point at static strings which must not be altered.
223  * "val" is either NULL or a malloc'd current-value string. PQconninfoFree()
224  * will release both the val strings and the PQconninfoOption array itself.
225  * ----------------
226  */
227 typedef struct _PQconninfoOption
228 {
229  char *keyword; /* The keyword of the option */
230  char *envvar; /* Fallback environment variable name */
231  char *compiled; /* Fallback compiled in default value */
232  char *val; /* Option's current value, or NULL */
233  char *label; /* Label for field in connect dialog */
234  char *dispchar; /* Indicates how to display this field in a
235  * connect dialog. Values are: "" Display
236  * entered value as is "*" Password field -
237  * hide value "D" Debug option - don't show
238  * by default */
239  int dispsize; /* Field size in characters for dialog */
241 
242 /* ----------------
243  * PQArgBlock -- structure for PQfn() arguments
244  * ----------------
245  */
246 typedef struct
247 {
248  int len;
249  int isint;
250  union
251  {
252  int *ptr; /* can't use void (dec compiler barfs) */
253  int integer;
254  } u;
255 } PQArgBlock;
256 
257 /* ----------------
258  * PGresAttDesc -- Data about a single attribute (column) of a query result
259  * ----------------
260  */
261 typedef struct pgresAttDesc
262 {
263  char *name; /* column name */
264  Oid tableid; /* source table, if known */
265  int columnid; /* source column, if known */
266  int format; /* format code for value (text/binary) */
267  Oid typid; /* type id */
268  int typlen; /* type size */
269  int atttypmod; /* type-specific modifier info */
271 
272 /* ----------------
273  * Exported functions of libpq
274  * ----------------
275  */
276 
277 /* === in fe-connect.c === */
278 
279 /* make a new client connection to the backend */
280 /* Asynchronous (non-blocking) */
281 extern PGconn *PQconnectStart(const char *conninfo);
282 extern PGconn *PQconnectStartParams(const char *const *keywords,
283  const char *const *values, int expand_dbname);
285 
286 /* Synchronous (blocking) */
287 extern PGconn *PQconnectdb(const char *conninfo);
288 extern PGconn *PQconnectdbParams(const char *const *keywords,
289  const char *const *values, int expand_dbname);
290 extern PGconn *PQsetdbLogin(const char *pghost, const char *pgport,
291  const char *pgoptions, const char *pgtty,
292  const char *dbName,
293  const char *login, const char *pwd);
294 
295 #define PQsetdb(M_PGHOST,M_PGPORT,M_PGOPT,M_PGTTY,M_DBNAME) \
296  PQsetdbLogin(M_PGHOST, M_PGPORT, M_PGOPT, M_PGTTY, M_DBNAME, NULL, NULL)
297 
298 /* close the current connection and free the PGconn data structure */
299 extern void PQfinish(PGconn *conn);
300 
301 /* get info about connection options known to PQconnectdb */
302 extern PQconninfoOption *PQconndefaults(void);
303 
304 /* parse connection options in same way as PQconnectdb */
305 extern PQconninfoOption *PQconninfoParse(const char *conninfo, char **errmsg);
306 
307 /* return the connection options used by a live connection */
309 
310 /* free the data structure returned by PQconndefaults() or PQconninfoParse() */
311 extern void PQconninfoFree(PQconninfoOption *connOptions);
312 
313 /*
314  * close the current connection and reestablish a new one with the same
315  * parameters
316  */
317 /* Asynchronous (non-blocking) */
318 extern int PQresetStart(PGconn *conn);
320 
321 /* Synchronous (blocking) */
322 extern void PQreset(PGconn *conn);
323 
324 /* request a cancel structure */
325 extern PGcancel *PQgetCancel(PGconn *conn);
326 
327 /* free a cancel structure */
328 extern void PQfreeCancel(PGcancel *cancel);
329 
330 /* issue a cancel request */
331 extern int PQcancel(PGcancel *cancel, char *errbuf, int errbufsize);
332 
333 /* backwards compatible version of PQcancel; not thread-safe */
334 extern int PQrequestCancel(PGconn *conn);
335 
336 /* Accessor functions for PGconn objects */
337 extern char *PQdb(const PGconn *conn);
338 extern char *PQuser(const PGconn *conn);
339 extern char *PQpass(const PGconn *conn);
340 extern char *PQhost(const PGconn *conn);
341 extern char *PQhostaddr(const PGconn *conn);
342 extern char *PQport(const PGconn *conn);
343 extern char *PQtty(const PGconn *conn);
344 extern char *PQoptions(const PGconn *conn);
345 extern ConnStatusType PQstatus(const PGconn *conn);
347 extern const char *PQparameterStatus(const PGconn *conn,
348  const char *paramName);
349 extern int PQprotocolVersion(const PGconn *conn);
350 extern int PQserverVersion(const PGconn *conn);
351 extern char *PQerrorMessage(const PGconn *conn);
352 extern int PQsocket(const PGconn *conn);
353 extern int PQbackendPID(const PGconn *conn);
355 extern int PQconnectionNeedsPassword(const PGconn *conn);
356 extern int PQconnectionUsedPassword(const PGconn *conn);
357 extern int PQconnectionUsedGSSAPI(const PGconn *conn);
358 extern int PQclientEncoding(const PGconn *conn);
359 extern int PQsetClientEncoding(PGconn *conn, const char *encoding);
360 
361 /* SSL information functions */
362 extern int PQsslInUse(PGconn *conn);
363 extern void *PQsslStruct(PGconn *conn, const char *struct_name);
364 extern const char *PQsslAttribute(PGconn *conn, const char *attribute_name);
365 extern const char *const *PQsslAttributeNames(PGconn *conn);
366 
367 /* Get the OpenSSL structure associated with a connection. Returns NULL for
368  * unencrypted connections or if any other TLS library is in use. */
369 extern void *PQgetssl(PGconn *conn);
370 
371 /* Tell libpq whether it needs to initialize OpenSSL */
372 extern void PQinitSSL(int do_init);
373 
374 /* More detailed way to tell libpq whether it needs to initialize OpenSSL */
375 extern void PQinitOpenSSL(int do_ssl, int do_crypto);
376 
377 /* Return true if GSSAPI encryption is in use */
378 extern int PQgssEncInUse(PGconn *conn);
379 
380 /* Returns GSSAPI context if GSSAPI is in use */
381 extern void *PQgetgssctx(PGconn *conn);
382 
383 /* Set verbosity for PQerrorMessage and PQresultErrorMessage */
385 
386 /* Set CONTEXT visibility for PQerrorMessage and PQresultErrorMessage */
388  PGContextVisibility show_context);
389 
390 /* Override default notice handling routines */
392  PQnoticeReceiver proc,
393  void *arg);
395  PQnoticeProcessor proc,
396  void *arg);
397 
398 /*
399  * Used to set callback that prevents concurrent access to
400  * non-thread safe functions that libpq needs.
401  * The default implementation uses a libpq internal mutex.
402  * Only required for multithreaded apps that use kerberos
403  * both within their app and for postgresql connections.
404  */
405 typedef void (*pgthreadlock_t) (int acquire);
406 
408 
409 /* === in fe-trace.c === */
410 extern void PQtrace(PGconn *conn, FILE *debug_port);
411 extern void PQuntrace(PGconn *conn);
412 
413 /* flags controlling trace output: */
414 /* omit timestamps from each line */
415 #define PQTRACE_SUPPRESS_TIMESTAMPS (1<<0)
416 /* redact portions of some messages, for testing frameworks */
417 #define PQTRACE_REGRESS_MODE (1<<1)
418 extern void PQsetTraceFlags(PGconn *conn, int flags);
419 
420 /* === in fe-exec.c === */
421 
422 /* Simple synchronous query */
423 extern PGresult *PQexec(PGconn *conn, const char *query);
425  const char *command,
426  int nParams,
427  const Oid *paramTypes,
428  const char *const *paramValues,
429  const int *paramLengths,
430  const int *paramFormats,
431  int resultFormat);
432 extern PGresult *PQprepare(PGconn *conn, const char *stmtName,
433  const char *query, int nParams,
434  const Oid *paramTypes);
436  const char *stmtName,
437  int nParams,
438  const char *const *paramValues,
439  const int *paramLengths,
440  const int *paramFormats,
441  int resultFormat);
442 
443 /* Interface for multiple-result or asynchronous queries */
444 #define PQ_QUERY_PARAM_MAX_LIMIT 65535
445 
446 extern int PQsendQuery(PGconn *conn, const char *query);
447 extern int PQsendQueryParams(PGconn *conn,
448  const char *command,
449  int nParams,
450  const Oid *paramTypes,
451  const char *const *paramValues,
452  const int *paramLengths,
453  const int *paramFormats,
454  int resultFormat);
455 extern int PQsendPrepare(PGconn *conn, const char *stmtName,
456  const char *query, int nParams,
457  const Oid *paramTypes);
458 extern int PQsendQueryPrepared(PGconn *conn,
459  const char *stmtName,
460  int nParams,
461  const char *const *paramValues,
462  const int *paramLengths,
463  const int *paramFormats,
464  int resultFormat);
465 extern int PQsetSingleRowMode(PGconn *conn);
466 extern PGresult *PQgetResult(PGconn *conn);
467 
468 /* Routines for managing an asynchronous query */
469 extern int PQisBusy(PGconn *conn);
470 extern int PQconsumeInput(PGconn *conn);
471 
472 /* Routines for pipeline mode management */
473 extern int PQenterPipelineMode(PGconn *conn);
474 extern int PQexitPipelineMode(PGconn *conn);
475 extern int PQpipelineSync(PGconn *conn);
476 extern int PQsendFlushRequest(PGconn *conn);
477 
478 /* LISTEN/NOTIFY support */
479 extern PGnotify *PQnotifies(PGconn *conn);
480 
481 /* Routines for copy in/out */
482 extern int PQputCopyData(PGconn *conn, const char *buffer, int nbytes);
483 extern int PQputCopyEnd(PGconn *conn, const char *errormsg);
484 extern int PQgetCopyData(PGconn *conn, char **buffer, int async);
485 
486 /* Deprecated routines for copy in/out */
487 extern int PQgetline(PGconn *conn, char *buffer, int length);
488 extern int PQputline(PGconn *conn, const char *string);
489 extern int PQgetlineAsync(PGconn *conn, char *buffer, int bufsize);
490 extern int PQputnbytes(PGconn *conn, const char *buffer, int nbytes);
491 extern int PQendcopy(PGconn *conn);
492 
493 /* Set blocking/nonblocking connection to the backend */
494 extern int PQsetnonblocking(PGconn *conn, int arg);
495 extern int PQisnonblocking(const PGconn *conn);
496 extern int PQisthreadsafe(void);
497 extern PGPing PQping(const char *conninfo);
498 extern PGPing PQpingParams(const char *const *keywords,
499  const char *const *values, int expand_dbname);
500 
501 /* Force the write buffer to be written (or at least try) */
502 extern int PQflush(PGconn *conn);
503 
504 /*
505  * "Fast path" interface --- not really recommended for application
506  * use
507  */
508 extern PGresult *PQfn(PGconn *conn,
509  int fnid,
510  int *result_buf,
511  int *result_len,
512  int result_is_int,
513  const PQArgBlock *args,
514  int nargs);
515 
516 /* Accessor functions for PGresult objects */
518 extern char *PQresStatus(ExecStatusType status);
519 extern char *PQresultErrorMessage(const PGresult *res);
520 extern char *PQresultVerboseErrorMessage(const PGresult *res,
521  PGVerbosity verbosity,
522  PGContextVisibility show_context);
523 extern char *PQresultErrorField(const PGresult *res, int fieldcode);
524 extern int PQntuples(const PGresult *res);
525 extern int PQnfields(const PGresult *res);
526 extern int PQbinaryTuples(const PGresult *res);
527 extern char *PQfname(const PGresult *res, int field_num);
528 extern int PQfnumber(const PGresult *res, const char *field_name);
529 extern Oid PQftable(const PGresult *res, int field_num);
530 extern int PQftablecol(const PGresult *res, int field_num);
531 extern int PQfformat(const PGresult *res, int field_num);
532 extern Oid PQftype(const PGresult *res, int field_num);
533 extern int PQfsize(const PGresult *res, int field_num);
534 extern int PQfmod(const PGresult *res, int field_num);
535 extern char *PQcmdStatus(PGresult *res);
536 extern char *PQoidStatus(const PGresult *res); /* old and ugly */
537 extern Oid PQoidValue(const PGresult *res); /* new and improved */
538 extern char *PQcmdTuples(PGresult *res);
539 extern char *PQgetvalue(const PGresult *res, int tup_num, int field_num);
540 extern int PQgetlength(const PGresult *res, int tup_num, int field_num);
541 extern int PQgetisnull(const PGresult *res, int tup_num, int field_num);
542 extern int PQnparams(const PGresult *res);
543 extern Oid PQparamtype(const PGresult *res, int param_num);
544 
545 /* Describe prepared statements and portals */
546 extern PGresult *PQdescribePrepared(PGconn *conn, const char *stmt);
547 extern PGresult *PQdescribePortal(PGconn *conn, const char *portal);
548 extern int PQsendDescribePrepared(PGconn *conn, const char *stmt);
549 extern int PQsendDescribePortal(PGconn *conn, const char *portal);
550 
551 /* Delete a PGresult */
552 extern void PQclear(PGresult *res);
553 
554 /* For freeing other alloc'd results, such as PGnotify structs */
555 extern void PQfreemem(void *ptr);
556 
557 /* Exists for backward compatibility. bjm 2003-03-24 */
558 #define PQfreeNotify(ptr) PQfreemem(ptr)
559 
560 /* Error when no password was given. */
561 /* Note: depending on this is deprecated; use PQconnectionNeedsPassword(). */
562 #define PQnoPasswordSupplied "fe_sendauth: no password supplied\n"
563 
564 /* Create and manipulate PGresults */
566 extern PGresult *PQcopyResult(const PGresult *src, int flags);
567 extern int PQsetResultAttrs(PGresult *res, int numAttributes, PGresAttDesc *attDescs);
568 extern void *PQresultAlloc(PGresult *res, size_t nBytes);
569 extern size_t PQresultMemorySize(const PGresult *res);
570 extern int PQsetvalue(PGresult *res, int tup_num, int field_num, char *value, int len);
571 
572 /* Quoting strings before inclusion in queries. */
573 extern size_t PQescapeStringConn(PGconn *conn,
574  char *to, const char *from, size_t length,
575  int *error);
576 extern char *PQescapeLiteral(PGconn *conn, const char *str, size_t len);
577 extern char *PQescapeIdentifier(PGconn *conn, const char *str, size_t len);
578 extern unsigned char *PQescapeByteaConn(PGconn *conn,
579  const unsigned char *from, size_t from_length,
580  size_t *to_length);
581 extern unsigned char *PQunescapeBytea(const unsigned char *strtext,
582  size_t *retbuflen);
583 
584 /* These forms are deprecated! */
585 extern size_t PQescapeString(char *to, const char *from, size_t length);
586 extern unsigned char *PQescapeBytea(const unsigned char *from, size_t from_length,
587  size_t *to_length);
588 
589 
590 
591 /* === in fe-print.c === */
592 
593 extern void PQprint(FILE *fout, /* output stream */
594  const PGresult *res,
595  const PQprintOpt *po); /* option structure */
596 
597 /*
598  * really old printing routines
599  */
600 extern void PQdisplayTuples(const PGresult *res,
601  FILE *fp, /* where to send the output */
602  int fillAlign, /* pad the fields with spaces */
603  const char *fieldSep, /* field separator */
604  int printHeader, /* display headers? */
605  int quiet);
606 
607 extern void PQprintTuples(const PGresult *res,
608  FILE *fout, /* output stream */
609  int PrintAttNames, /* print attribute names */
610  int TerseOutput, /* delimiter bars */
611  int colWidth); /* width of column, if 0, use
612  * variable width */
613 
614 
615 /* === in fe-lobj.c === */
616 
617 /* Large-object access routines */
618 extern int lo_open(PGconn *conn, Oid lobjId, int mode);
619 extern int lo_close(PGconn *conn, int fd);
620 extern int lo_read(PGconn *conn, int fd, char *buf, size_t len);
621 extern int lo_write(PGconn *conn, int fd, const char *buf, size_t len);
622 extern int lo_lseek(PGconn *conn, int fd, int offset, int whence);
623 extern pg_int64 lo_lseek64(PGconn *conn, int fd, pg_int64 offset, int whence);
624 extern Oid lo_creat(PGconn *conn, int mode);
625 extern Oid lo_create(PGconn *conn, Oid lobjId);
626 extern int lo_tell(PGconn *conn, int fd);
627 extern pg_int64 lo_tell64(PGconn *conn, int fd);
628 extern int lo_truncate(PGconn *conn, int fd, size_t len);
629 extern int lo_truncate64(PGconn *conn, int fd, pg_int64 len);
630 extern int lo_unlink(PGconn *conn, Oid lobjId);
631 extern Oid lo_import(PGconn *conn, const char *filename);
632 extern Oid lo_import_with_oid(PGconn *conn, const char *filename, Oid lobjId);
633 extern int lo_export(PGconn *conn, Oid lobjId, const char *filename);
634 
635 /* === in fe-misc.c === */
636 
637 /* Get the version of the libpq library in use */
638 extern int PQlibVersion(void);
639 
640 /* Determine length of multibyte encoded char at *s */
641 extern int PQmblen(const char *s, int encoding);
642 
643 /* Same, but not more than the distance to the end of string s */
644 extern int PQmblenBounded(const char *s, int encoding);
645 
646 /* Determine display length of multibyte encoded char at *s */
647 extern int PQdsplen(const char *s, int encoding);
648 
649 /* Get encoding id from environment variable PGCLIENTENCODING */
650 extern int PQenv2encoding(void);
651 
652 /* === in fe-auth.c === */
653 
654 extern char *PQencryptPassword(const char *passwd, const char *user);
655 extern char *PQencryptPasswordConn(PGconn *conn, const char *passwd, const char *user, const char *algorithm);
656 
657 /* === in encnames.c === */
658 
659 extern int pg_char_to_encoding(const char *name);
660 extern const char *pg_encoding_to_char(int encoding);
661 extern int pg_valid_server_encoding_id(int encoding);
662 
663 /* === in fe-secure-openssl.c === */
664 
665 /* Support for overriding sslpassword handling with a callback */
666 typedef int (*PQsslKeyPassHook_OpenSSL_type) (char *buf, int size, PGconn *conn);
669 extern int PQdefaultSSLKeyPassHook_OpenSSL(char *buf, int size, PGconn *conn);
670 
671 #ifdef __cplusplus
672 }
673 #endif
674 
675 #endif /* LIBPQ_FE_H */
static Datum values[MAXATTR]
Definition: bootstrap.c:156
int errmsg(const char *fmt,...)
Definition: elog.c:1069
const char * name
Definition: encode.c:571
#define stmt
Definition: indent_codes.h:59
#define bufsize
Definition: indent_globs.h:36
static struct @147 value
ConnStatusType
Definition: libpq-fe.h:59
@ CONNECTION_CONSUME
Definition: libpq-fe.h:78
@ CONNECTION_CHECK_STANDBY
Definition: libpq-fe.h:81
@ CONNECTION_STARTED
Definition: libpq-fe.h:68
@ CONNECTION_AWAITING_RESPONSE
Definition: libpq-fe.h:70
@ CONNECTION_MADE
Definition: libpq-fe.h:69
@ CONNECTION_CHECK_WRITABLE
Definition: libpq-fe.h:77
@ CONNECTION_BAD
Definition: libpq-fe.h:61
@ CONNECTION_OK
Definition: libpq-fe.h:60
@ CONNECTION_GSS_STARTUP
Definition: libpq-fe.h:79
@ CONNECTION_SSL_STARTUP
Definition: libpq-fe.h:75
@ CONNECTION_AUTH_OK
Definition: libpq-fe.h:72
@ CONNECTION_CHECK_TARGET
Definition: libpq-fe.h:80
@ CONNECTION_NEEDED
Definition: libpq-fe.h:76
@ CONNECTION_SETENV
Definition: libpq-fe.h:74
const char * PQparameterStatus(const PGconn *conn, const char *paramName)
Definition: fe-connect.c:7210
int PQserverVersion(const PGconn *conn)
Definition: fe-connect.c:7235
int PQprotocolVersion(const PGconn *conn)
Definition: fe-connect.c:7225
char pqbool
Definition: libpq-fe.h:201
PQconninfoOption * PQconninfoParse(const char *conninfo, char **errmsg)
Definition: fe-connect.c:5826
unsigned char * PQescapeBytea(const unsigned char *from, size_t from_length, size_t *to_length)
Definition: fe-exec.c:4306
PGresult * PQfn(PGconn *conn, int fnid, int *result_buf, int *result_len, int result_is_int, const PQArgBlock *args, int nargs)
Definition: fe-exec.c:2865
int PQresetStart(PGconn *conn)
Definition: fe-connect.c:4646
int PQsendQueryParams(PGconn *conn, const char *command, int nParams, const Oid *paramTypes, const char *const *paramValues, const int *paramLengths, const int *paramFormats, int resultFormat)
Definition: fe-exec.c:1498
int PQgetlength(const PGresult *res, int tup_num, int field_num)
Definition: fe-exec.c:3720
PGcancel * PQgetCancel(PGconn *conn)
Definition: fe-connect.c:4704
int PQsetSingleRowMode(PGconn *conn)
Definition: fe-exec.c:1929
int PQbinaryTuples(const PGresult *res)
Definition: fe-exec.c:3330
int PQflush(PGconn *conn)
Definition: fe-exec.c:3837
void PQfreemem(void *ptr)
Definition: fe-exec.c:3869
PGconn * PQconnectStartParams(const char *const *keywords, const char *const *values, int expand_dbname)
Definition: fe-connect.c:780
void PQdisplayTuples(const PGresult *res, FILE *fp, int fillAlign, const char *fieldSep, int printHeader, int quiet)
Definition: fe-print.c:585
PGnotify * PQnotifies(PGconn *conn)
Definition: fe-exec.c:2551
PGresult * PQprepare(PGconn *conn, const char *stmtName, const char *query, int nParams, const Oid *paramTypes)
Definition: fe-exec.c:2272
int PQgetline(PGconn *conn, char *buffer, int length)
Definition: fe-exec.c:2739
unsigned char * PQunescapeBytea(const unsigned char *strtext, size_t *retbuflen)
Definition: fe-exec.c:4331
ExecStatusType
Definition: libpq-fe.h:95
@ PGRES_COPY_IN
Definition: libpq-fe.h:104
@ PGRES_COPY_BOTH
Definition: libpq-fe.h:109
@ PGRES_COMMAND_OK
Definition: libpq-fe.h:97
@ PGRES_FATAL_ERROR
Definition: libpq-fe.h:108
@ PGRES_SINGLE_TUPLE
Definition: libpq-fe.h:110
@ PGRES_COPY_OUT
Definition: libpq-fe.h:103
@ PGRES_EMPTY_QUERY
Definition: libpq-fe.h:96
@ PGRES_PIPELINE_SYNC
Definition: libpq-fe.h:111
@ PGRES_BAD_RESPONSE
Definition: libpq-fe.h:105
@ PGRES_PIPELINE_ABORTED
Definition: libpq-fe.h:112
@ PGRES_NONFATAL_ERROR
Definition: libpq-fe.h:107
@ PGRES_TUPLES_OK
Definition: libpq-fe.h:100
void PQinitSSL(int do_init)
Definition: fe-secure.c:137
Oid PQftype(const PGresult *res, int field_num)
Definition: fe-exec.c:3552
void(* pgthreadlock_t)(int acquire)
Definition: libpq-fe.h:405
int lo_tell(PGconn *conn, int fd)
Definition: fe-lobj.c:515
int PQexitPipelineMode(PGconn *conn)
Definition: fe-exec.c:2958
char * PQhost(const PGconn *conn)
Definition: fe-connect.c:7124
PGPing
Definition: libpq-fe.h:146
@ PQPING_OK
Definition: libpq-fe.h:147
@ PQPING_REJECT
Definition: libpq-fe.h:148
@ PQPING_NO_RESPONSE
Definition: libpq-fe.h:149
@ PQPING_NO_ATTEMPT
Definition: libpq-fe.h:150
int PQsetResultAttrs(PGresult *res, int numAttributes, PGresAttDesc *attDescs)
Definition: fe-exec.c:246
PGContextVisibility
Definition: libpq-fe.h:134
@ PQSHOW_CONTEXT_NEVER
Definition: libpq-fe.h:135
@ PQSHOW_CONTEXT_ALWAYS
Definition: libpq-fe.h:137
@ PQSHOW_CONTEXT_ERRORS
Definition: libpq-fe.h:136
int lo_close(PGconn *conn, int fd)
Definition: fe-lobj.c:96
struct _PQconninfoOption PQconninfoOption
pg_int64 lo_tell64(PGconn *conn, int fd)
Definition: fe-lobj.c:548
int PQenv2encoding(void)
Definition: fe-misc.c:1206
PGconn * PQconnectStart(const char *conninfo)
Definition: fe-connect.c:861
PQsslKeyPassHook_OpenSSL_type PQgetSSLKeyPassHook_OpenSSL(void)
PGconn * PQconnectdbParams(const char *const *keywords, const char *const *values, int expand_dbname)
Definition: fe-connect.c:678
char * PQdb(const PGconn *conn)
Definition: fe-connect.c:7091
char * PQescapeIdentifier(PGconn *conn, const char *str, size_t len)
Definition: fe-exec.c:4147
void PQreset(PGconn *conn)
Definition: fe-connect.c:4613
int PQenterPipelineMode(PGconn *conn)
Definition: fe-exec.c:2927
size_t PQescapeStringConn(PGconn *conn, char *to, const char *from, size_t length, int *error)
Definition: fe-exec.c:3982
void PQtrace(PGconn *conn, FILE *debug_port)
Definition: fe-trace.c:35
PGTransactionStatusType PQtransactionStatus(const PGconn *conn)
Definition: fe-connect.c:7200
PGTransactionStatusType
Definition: libpq-fe.h:117
@ PQTRANS_INTRANS
Definition: libpq-fe.h:120
@ PQTRANS_IDLE
Definition: libpq-fe.h:118
@ PQTRANS_ACTIVE
Definition: libpq-fe.h:119
@ PQTRANS_UNKNOWN
Definition: libpq-fe.h:122
@ PQTRANS_INERROR
Definition: libpq-fe.h:121
PGresult * PQexecParams(PGconn *conn, const char *command, int nParams, const Oid *paramTypes, const char *const *paramValues, const int *paramLengths, const int *paramFormats, int resultFormat)
Definition: fe-exec.c:2242
ExecStatusType PQresultStatus(const PGresult *res)
Definition: fe-exec.c:3244
Oid PQparamtype(const PGresult *res, int param_num)
Definition: fe-exec.c:3759
PGresult * PQdescribePrepared(PGconn *conn, const char *stmt)
Definition: fe-exec.c:2421
int PQnparams(const PGresult *res)
Definition: fe-exec.c:3748
int PQdefaultSSLKeyPassHook_OpenSSL(char *buf, int size, PGconn *conn)
char * PQencryptPassword(const char *passwd, const char *user)
Definition: fe-auth.c:1244
int pg_char_to_encoding(const char *name)
Definition: encnames.c:550
void PQprintTuples(const PGresult *res, FILE *fout, int PrintAttNames, int TerseOutput, int colWidth)
Definition: fe-print.c:682
void PQclear(PGresult *res)
Definition: fe-exec.c:718
char * PQcmdTuples(PGresult *res)
Definition: fe-exec.c:3655
char * PQresultErrorMessage(const PGresult *res)
Definition: fe-exec.c:3260
PQconninfoOption * PQconndefaults(void)
Definition: fe-connect.c:1780
struct _PQprintOpt PQprintOpt
int PQconnectionUsedPassword(const PGconn *conn)
Definition: fe-connect.c:7311
int PQfformat(const PGresult *res, int field_num)
Definition: fe-exec.c:3541
void(* PQnoticeReceiver)(void *arg, const PGresult *res)
Definition: libpq-fe.h:197
int PQlibVersion(void)
Definition: fe-misc.c:64
char * PQtty(const PGconn *conn)
Definition: fe-connect.c:7176
void(* PQnoticeProcessor)(void *arg, const char *message)
Definition: libpq-fe.h:198
char * PQhostaddr(const PGconn *conn)
Definition: fe-connect.c:7147
int PQendcopy(PGconn *conn)
Definition: fe-exec.c:2834
int PQgssEncInUse(PGconn *conn)
PostgresPollingStatusType PQconnectPoll(PGconn *conn)
Definition: fe-connect.c:2543
int PQputCopyEnd(PGconn *conn, const char *errormsg)
Definition: fe-exec.c:2634
void PQconninfoFree(PQconninfoOption *connOptions)
Definition: fe-connect.c:7078
Oid lo_creat(PGconn *conn, int mode)
Definition: fe-lobj.c:438
int(* PQsslKeyPassHook_OpenSSL_type)(char *buf, int size, PGconn *conn)
Definition: libpq-fe.h:666
int lo_read(PGconn *conn, int fd, char *buf, size_t len)
Definition: fe-lobj.c:245
int lo_lseek(PGconn *conn, int fd, int offset, int whence)
Definition: fe-lobj.c:344
int PQntuples(const PGresult *res)
Definition: fe-exec.c:3314
int PQputnbytes(PGconn *conn, const char *buffer, int nbytes)
Definition: fe-exec.c:2813
void PQprint(FILE *fout, const PGresult *res, const PQprintOpt *po)
Definition: fe-print.c:68
pg_int64 lo_lseek64(PGconn *conn, int fd, pg_int64 offset, int whence)
Definition: fe-lobj.c:385
int pg_valid_server_encoding_id(int encoding)
Definition: encnames.c:514
int PQmblen(const char *s, int encoding)
Definition: fe-misc.c:1177
int PQputline(PGconn *conn, const char *string)
Definition: fe-exec.c:2803
int PQgetlineAsync(PGconn *conn, char *buffer, int bufsize)
Definition: fe-exec.c:2786
int lo_open(PGconn *conn, Oid lobjId, int mode)
Definition: fe-lobj.c:57
PostgresPollingStatusType
Definition: libpq-fe.h:85
@ PGRES_POLLING_ACTIVE
Definition: libpq-fe.h:90
@ PGRES_POLLING_OK
Definition: libpq-fe.h:89
@ PGRES_POLLING_READING
Definition: libpq-fe.h:87
@ PGRES_POLLING_WRITING
Definition: libpq-fe.h:88
@ PGRES_POLLING_FAILED
Definition: libpq-fe.h:86
int PQputCopyData(PGconn *conn, const char *buffer, int nbytes)
Definition: fe-exec.c:2579
PGresult * PQexecPrepared(PGconn *conn, const char *stmtName, int nParams, const char *const *paramValues, const int *paramLengths, const int *paramFormats, int resultFormat)
Definition: fe-exec.c:2289
PQconninfoOption * PQconninfo(PGconn *conn)
Definition: fe-connect.c:7034
int lo_write(PGconn *conn, int fd, const char *buf, size_t len)
Definition: fe-lobj.c:295
int PQisthreadsafe(void)
Definition: fe-exec.c:3825
char * PQfname(const PGresult *res, int field_num)
Definition: fe-exec.c:3400
int PQconnectionNeedsPassword(const PGconn *conn)
Definition: fe-connect.c:7296
void PQinitOpenSSL(int do_ssl, int do_crypto)
Definition: fe-secure.c:149
char * PQescapeLiteral(PGconn *conn, const char *str, size_t len)
Definition: fe-exec.c:4141
int lo_truncate(PGconn *conn, int fd, size_t len)
Definition: fe-lobj.c:131
PGresult * PQdescribePortal(PGconn *conn, const char *portal)
Definition: fe-exec.c:2440
int PQsendDescribePrepared(PGconn *conn, const char *stmt)
Definition: fe-exec.c:2457
PGresult * PQmakeEmptyPGresult(PGconn *conn, ExecStatusType status)
Definition: fe-exec.c:157
Oid lo_create(PGconn *conn, Oid lobjId)
Definition: fe-lobj.c:474
PGresult * PQexec(PGconn *conn, const char *query)
Definition: fe-exec.c:2228
unsigned char * PQescapeByteaConn(PGconn *conn, const unsigned char *from, size_t from_length, size_t *to_length)
Definition: fe-exec.c:4290
PostgresPollingStatusType PQresetPoll(PGconn *conn)
Definition: fe-connect.c:4665
int PQsslInUse(PGconn *conn)
Definition: fe-secure.c:125
int PQconnectionUsedGSSAPI(const PGconn *conn)
Definition: fe-connect.c:7322
size_t PQescapeString(char *to, const char *from, size_t length)
Definition: fe-exec.c:4004
int PQconsumeInput(PGconn *conn)
Definition: fe-exec.c:1957
char * PQerrorMessage(const PGconn *conn)
Definition: fe-connect.c:7245
int PQcancel(PGcancel *cancel, char *errbuf, int errbufsize)
Definition: fe-connect.c:4818
char * PQgetvalue(const PGresult *res, int tup_num, int field_num)
Definition: fe-exec.c:3709
struct pgNotify PGnotify
ConnStatusType PQstatus(const PGconn *conn)
Definition: fe-connect.c:7192
Oid PQftable(const PGresult *res, int field_num)
Definition: fe-exec.c:3519
int PQfnumber(const PGresult *res, const char *field_name)
Definition: fe-exec.c:3422
char * PQcmdStatus(PGresult *res)
Definition: fe-exec.c:3585
int PQsetnonblocking(PGconn *conn, int arg)
Definition: fe-exec.c:3777
int PQclientEncoding(const PGconn *conn)
Definition: fe-connect.c:7333
const char *const * PQsslAttributeNames(PGconn *conn)
PGconn * PQsetdbLogin(const char *pghost, const char *pgport, const char *pgoptions, const char *pgtty, const char *dbName, const char *login, const char *pwd)
Definition: fe-connect.c:1818
void PQfinish(PGconn *conn)
Definition: fe-connect.c:4599
PGPing PQping(const char *conninfo)
Definition: fe-connect.c:749
int PQsendPrepare(PGconn *conn, const char *stmtName, const char *query, int nParams, const Oid *paramTypes)
Definition: fe-exec.c:1542
PGconn * PQconnectdb(const char *conninfo)
Definition: fe-connect.c:733
int PQfmod(const PGresult *res, int field_num)
Definition: fe-exec.c:3574
PGContextVisibility PQsetErrorContextVisibility(PGconn *conn, PGContextVisibility show_context)
Definition: fe-connect.c:7395
PGpipelineStatus
Definition: libpq-fe.h:157
@ PQ_PIPELINE_OFF
Definition: libpq-fe.h:158
@ PQ_PIPELINE_ABORTED
Definition: libpq-fe.h:160
@ PQ_PIPELINE_ON
Definition: libpq-fe.h:159
int PQdsplen(const char *s, int encoding)
Definition: fe-misc.c:1197
int PQgetisnull(const PGresult *res, int tup_num, int field_num)
Definition: fe-exec.c:3734
char * PQuser(const PGconn *conn)
Definition: fe-connect.c:7099
int PQftablecol(const PGresult *res, int field_num)
Definition: fe-exec.c:3530
void * PQgetssl(PGconn *conn)
int PQsetvalue(PGresult *res, int tup_num, int field_num, char *value, int len)
Definition: fe-exec.c:449
void * PQsslStruct(PGconn *conn, const char *struct_name)
char * PQpass(const PGconn *conn)
Definition: fe-connect.c:7107
int PQsendQuery(PGconn *conn, const char *query)
Definition: fe-exec.c:1422
int PQpipelineSync(PGconn *conn)
Definition: fe-exec.c:3145
char * PQresStatus(ExecStatusType status)
Definition: fe-exec.c:3252
PQnoticeReceiver PQsetNoticeReceiver(PGconn *conn, PQnoticeReceiver proc, void *arg)
Definition: fe-connect.c:7407
int PQsendDescribePortal(PGconn *conn, const char *portal)
Definition: fe-exec.c:2470
void PQsetTraceFlags(PGconn *conn, int flags)
Definition: fe-trace.c:64
size_t PQresultMemorySize(const PGresult *res)
Definition: fe-exec.c:660
int PQbackendPID(const PGconn *conn)
Definition: fe-connect.c:7279
int PQisBusy(PGconn *conn)
Definition: fe-exec.c:2004
int PQsendQueryPrepared(PGconn *conn, const char *stmtName, int nParams, const char *const *paramValues, const int *paramLengths, const int *paramFormats, int resultFormat)
Definition: fe-exec.c:1639
PGVerbosity
Definition: libpq-fe.h:126
@ PQERRORS_VERBOSE
Definition: libpq-fe.h:129
@ PQERRORS_DEFAULT
Definition: libpq-fe.h:128
@ PQERRORS_TERSE
Definition: libpq-fe.h:127
@ PQERRORS_SQLSTATE
Definition: libpq-fe.h:130
void * PQgetgssctx(PGconn *conn)
int PQsendFlushRequest(PGconn *conn)
Definition: fe-exec.c:3212
int PQrequestCancel(PGconn *conn)
Definition: fe-connect.c:5017
char * PQencryptPasswordConn(PGconn *conn, const char *passwd, const char *user, const char *algorithm)
Definition: fe-auth.c:1287
void PQfreeCancel(PGcancel *cancel)
Definition: fe-connect.c:4772
char * PQoidStatus(const PGresult *res)
Definition: fe-exec.c:3598
char * PQresultErrorField(const PGresult *res, int fieldcode)
Definition: fe-exec.c:3299
char * PQport(const PGconn *conn)
Definition: fe-connect.c:7160
PGpipelineStatus PQpipelineStatus(const PGconn *conn)
Definition: fe-connect.c:7287
int lo_unlink(PGconn *conn, Oid lobjId)
Definition: fe-lobj.c:589
int PQisnonblocking(const PGconn *conn)
Definition: fe-exec.c:3816
void PQuntrace(PGconn *conn)
Definition: fe-trace.c:49
PGresult * PQcopyResult(const PGresult *src, int flags)
Definition: fe-exec.c:315
PGVerbosity PQsetErrorVerbosity(PGconn *conn, PGVerbosity verbosity)
Definition: fe-connect.c:7383
PQnoticeProcessor PQsetNoticeProcessor(PGconn *conn, PQnoticeProcessor proc, void *arg)
Definition: fe-connect.c:7424
void * PQresultAlloc(PGresult *res, size_t nBytes)
Definition: fe-exec.c:540
Oid lo_import(PGconn *conn, const char *filename)
Definition: fe-lobj.c:626
Oid PQoidValue(const PGresult *res)
Definition: fe-exec.c:3626
int PQmblenBounded(const char *s, int encoding)
Definition: fe-misc.c:1187
const char * PQsslAttribute(PGconn *conn, const char *attribute_name)
const char * pg_encoding_to_char(int encoding)
Definition: encnames.c:588
int lo_export(PGconn *conn, Oid lobjId, const char *filename)
Definition: fe-lobj.c:748
char * PQresultVerboseErrorMessage(const PGresult *res, PGVerbosity verbosity, PGContextVisibility show_context)
Definition: fe-exec.c:3268
int PQnfields(const PGresult *res)
Definition: fe-exec.c:3322
Oid lo_import_with_oid(PGconn *conn, const char *filename, Oid lobjId)
Definition: fe-lobj.c:641
void PQsetSSLKeyPassHook_OpenSSL(PQsslKeyPassHook_OpenSSL_type hook)
PGPing PQpingParams(const char *const *keywords, const char *const *values, int expand_dbname)
Definition: fe-connect.c:696
int PQsocket(const PGconn *conn)
Definition: fe-connect.c:7271
char * PQoptions(const PGconn *conn)
Definition: fe-connect.c:7184
PGresult * PQgetResult(PGconn *conn)
Definition: fe-exec.c:2035
int PQfsize(const PGresult *res, int field_num)
Definition: fe-exec.c:3563
int lo_truncate64(PGconn *conn, int fd, pg_int64 len)
Definition: fe-lobj.c:195
int PQsetClientEncoding(PGconn *conn, const char *encoding)
Definition: fe-connect.c:7341
struct pgresAttDesc PGresAttDesc
pgthreadlock_t PQregisterThreadLock(pgthreadlock_t newhandler)
Definition: fe-connect.c:7820
int PQgetCopyData(PGconn *conn, char **buffer, int async)
Definition: fe-exec.c:2701
void * arg
static PgChecksumMode mode
Definition: pg_checksums.c:65
const void size_t len
static void do_init(void)
Definition: pg_ctl.c:895
int32 encoding
Definition: pg_database.h:41
static char * filename
Definition: pg_dumpall.c:119
static char * user
Definition: pg_regress.c:112
static char * buf
Definition: pg_test_fsync.c:67
const char * pghost
Definition: pgbench.c:304
const char * pgport
Definition: pgbench.c:305
const char * dbName
Definition: pgbench.c:307
PG_INT64_TYPE pg_int64
Definition: postgres_ext.h:47
unsigned int Oid
Definition: postgres_ext.h:31
static int fd(const char *x, int i)
Definition: preproc-init.c:105
static void error(void)
Definition: sql-dyntest.c:147
PGconn * conn
Definition: streamutil.c:54
int isint
Definition: libpq-fe.h:249
int * ptr
Definition: libpq-fe.h:252
int integer
Definition: libpq-fe.h:253
pqbool align
Definition: libpq-fe.h:206
pqbool pager
Definition: libpq-fe.h:210
pqbool standard
Definition: libpq-fe.h:207
pqbool html3
Definition: libpq-fe.h:208
char * caption
Definition: libpq-fe.h:213
pqbool header
Definition: libpq-fe.h:205
pqbool expanded
Definition: libpq-fe.h:209
char * fieldSep
Definition: libpq-fe.h:211
char ** fieldName
Definition: libpq-fe.h:214
char * tableOpt
Definition: libpq-fe.h:212
struct pgNotify * next
Definition: libpq-fe.h:193
int be_pid
Definition: libpq-fe.h:190
char * relname
Definition: libpq-fe.h:189
char * extra
Definition: libpq-fe.h:191
char * name
Definition: libpq-fe.h:263
int columnid
Definition: libpq-fe.h:265
int atttypmod
Definition: libpq-fe.h:269