PostgreSQL Source Code  git master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
command.h
Go to the documentation of this file.
1 /*
2  * psql - the PostgreSQL interactive terminal
3  *
4  * Copyright (c) 2000-2017, PostgreSQL Global Development Group
5  *
6  * src/bin/psql/command.h
7  */
8 #ifndef COMMAND_H
9 #define COMMAND_H
10 
11 #include "fe_utils/print.h"
12 #include "fe_utils/psqlscan.h"
13 
14 
15 typedef enum _backslashResult
16 {
17  PSQL_CMD_UNKNOWN = 0, /* not done parsing yet (internal only) */
18  PSQL_CMD_SEND, /* query complete; send off */
19  PSQL_CMD_SKIP_LINE, /* keep building query */
20  PSQL_CMD_TERMINATE, /* quit program */
21  PSQL_CMD_NEWEDIT, /* query buffer was changed (e.g., via \e) */
22  PSQL_CMD_ERROR /* the execution of the backslash command
23  * resulted in an error */
25 
26 
28  PQExpBuffer query_buf);
29 
30 extern int process_file(char *filename, bool use_relative_path);
31 
32 extern bool do_pset(const char *param,
33  const char *value,
34  printQueryOpt *popt,
35  bool quiet);
36 
37 extern void connection_warnings(bool in_startup);
38 
39 extern void SyncVariables(void);
40 
41 extern void UnsyncVariables(void);
42 
43 #endif /* COMMAND_H */
static struct @78 value
void connection_warnings(bool in_startup)
Definition: command.c:2048
backslashResult HandleSlashCmds(PsqlScanState scan_state, PQExpBuffer query_buf)
Definition: command.c:108
_backslashResult
Definition: command.h:15
void SyncVariables(void)
Definition: command.c:2155
enum _backslashResult backslashResult
void UnsyncVariables(void)
Definition: command.c:2179
bool do_pset(const char *param, const char *value, printQueryOpt *popt, bool quiet)
Definition: command.c:2562
static char * filename
Definition: pg_dumpall.c:87
int process_file(char *filename, bool use_relative_path)
Definition: command.c:2428