aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/mb/variable.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/utils/mb/variable.c')
-rw-r--r--src/backend/utils/mb/variable.c82
1 files changed, 0 insertions, 82 deletions
diff --git a/src/backend/utils/mb/variable.c b/src/backend/utils/mb/variable.c
deleted file mode 100644
index 65768ef77ac..00000000000
--- a/src/backend/utils/mb/variable.c
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * This file contains some public functions
- * related to show/set/reset variable commands.
- * Tatsuo Ishii
- * $Id: variable.c,v 1.7 2000/04/20 22:40:18 tgl Exp $
- */
-
-#include "postgres.h"
-#include "miscadmin.h"
-#include "mb/pg_wchar.h"
-
-bool
-parse_client_encoding(char *value)
-{
- int encoding;
-
- encoding = pg_valid_client_encoding(value);
- if (encoding < 0)
- {
- if (value)
- elog(ERROR, "Client encoding %s is not supported", value);
- else
- elog(ERROR, "No client encoding is specified");
- }
- else
- {
- if (pg_set_client_encoding(encoding))
- {
- elog(ERROR, "Conversion between %s and %s is not supported",
- value, pg_encoding_to_char(GetDatabaseEncoding()));
- }
- }
- return TRUE;
-}
-
-bool
-show_client_encoding()
-{
- elog(NOTICE, "Current client encoding is %s",
- pg_encoding_to_char(pg_get_client_encoding()));
- return TRUE;
-}
-
-bool
-reset_client_encoding()
-{
- int encoding;
- char *env = getenv("PGCLIENTENCODING");
-
- if (env)
- {
- encoding = pg_char_to_encoding(env);
- if (encoding < 0)
- encoding = GetDatabaseEncoding();
- }
- else
- encoding = GetDatabaseEncoding();
- pg_set_client_encoding(encoding);
- return TRUE;
-}
-
-bool
-parse_server_encoding(char *value)
-{
- elog(NOTICE, "SET SERVER_ENCODING is not supported");
- return TRUE;
-}
-
-bool
-show_server_encoding()
-{
- elog(NOTICE, "Current server encoding is %s",
- pg_encoding_to_char(GetDatabaseEncoding()));
- return TRUE;
-}
-
-bool
-reset_server_encoding()
-{
- elog(NOTICE, "RESET SERVER_ENCODING is not supported");
- return TRUE;
-}