1
0
mirror of https://github.com/postgres/postgres.git synced 2025-12-12 02:37:31 +03:00

Repair problem identified by Olivier Prenant: ALTER DATABASE SET search_path

should not be too eager to reject paths involving unknown schemas, since
it can't really tell whether the schemas exist in the target database.
(Also, when reading pg_dumpall output, it could be that the schemas
don't exist yet, but eventually will.)  ALTER USER SET has a similar issue.
So, reduce the normal ERROR to a NOTICE when checking search_path values
for these commands.  Supporting this requires changing the API for GUC
assign_hook functions, which causes the patch to touch a lot of places,
but the changes are conceptually trivial.
This commit is contained in:
Tom Lane
2004-01-19 19:04:40 +00:00
parent 239760209b
commit 9bd681a522
17 changed files with 183 additions and 144 deletions

View File

@@ -2,7 +2,7 @@
*
* PostgreSQL locale utilities
*
* $PostgreSQL: pgsql/src/include/utils/pg_locale.h,v 1.16 2003/11/29 22:41:16 pgsql Exp $
* $PostgreSQL: pgsql/src/include/utils/pg_locale.h,v 1.17 2004/01/19 19:04:40 tgl Exp $
*
* Copyright (c) 2002-2003, PostgreSQL Global Development Group
*
@@ -14,19 +14,22 @@
#include <locale.h>
#include "utils/guc.h"
extern char *locale_messages;
extern char *locale_monetary;
extern char *locale_numeric;
extern char *locale_time;
extern const char *locale_messages_assign(const char *value,
bool doit, bool interactive);
bool doit, GucSource source);
extern const char *locale_monetary_assign(const char *value,
bool doit, bool interactive);
bool doit, GucSource source);
extern const char *locale_numeric_assign(const char *value,
bool doit, bool interactive);
bool doit, GucSource source);
extern const char *locale_time_assign(const char *value,
bool doit, bool interactive);
bool doit, GucSource source);
extern bool lc_collate_is_c(void);