* psql - the openGauss interactive terminal
*
* Copyright (c) 2000-2012, PostgreSQL Global Development Group
*
* src/bin/psql/command.h
*/
#ifndef COMMAND_H
#define COMMAND_H
#include "print.h"
#include "psqlscan.h"
typedef enum _backslashResult {
PSQL_CMD_UNKNOWN = 0,
PSQL_CMD_SEND,
PSQL_CMD_SKIP_LINE,
PSQL_CMD_TERMINATE,
PSQL_CMD_NEWEDIT,
PSQL_CMD_ERROR
* resulted in an error */
} backslashResult;
extern backslashResult HandleSlashCmds(PsqlScanState scan_state, PQExpBuffer query_buf);
extern int process_file(char* filename, bool single_txn, bool use_relative_path);
extern bool do_pset(const char* param, const char* value, printQueryOpt* popt, bool quiet);
extern void connection_warnings(bool in_startup);
extern void client_server_version_check(PGconn* conn);
extern void SyncVariables(void);
extern void UnsyncVariables(void);
#define MAX_PASSWORD_LENGTH 999
#endif