From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | setting per-database/role parameters checks them against wrong context |
Date: | 2012-09-28 03:29:44 |
Message-ID: | 1348802984.3584.22.camel@vanquo.pezone.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Example:
create temporary table foo (a int);
insert into foo values (1);
alter role peter set temp_buffers = 120;
ERROR: 22023: invalid value for parameter "temp_buffers": 120
DETAIL: "temp_buffers" cannot be changed after any temporary tables
have been accessed in the session.
Another example:
set log_statement_stats = on;
alter role peter set log_parser_stats = on;
ERROR: 22023: invalid value for parameter "log_parser_stats": 1
DETAIL: Cannot enable parameter when "log_statement_stats" is true.
Another example is that in <=9.1, ALTER DATABASE ... SET search_path
would check the existence of the schema in the current database, but
that was done away with in 9.2.
The first example could probably be fixed if check_temp_buffers() paid
attention to the GucSource, but in the second case and in general there
doesn't seem to be a way to distinguish "assigning per-database setting"
and "enacting per-database setting" as a source.
Ideas?
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2012-09-28 04:47:21 | Re: ToDo: allow to get a number of processed rows by COPY statement [Review of Patch] |
Previous Message | Brian Weaver | 2012-09-28 02:00:09 | Re: Patch: incorrect array offset in backend replication tar header |