Thread: BUG #16940: ERROR: unrecognized parameter
The following bug has been logged on the website: Bug reference: 16940 Logged by: Zhu Ethan Email address: crimezjp@foxmail.com PostgreSQL version: 13.2 Operating system: Ubuntu 20.04 Description: postgres=# CREATE TEMP TABLE IF NOT EXISTS t0(c0 REAL PRIMARY KEY DEFAULT (0.7718745), c1 boolean , c2 FLOAT DEFAULT (0.4103656432464894)) PARTITION BY RANGE((t0.c0)) WITH (autovacuum_vacuum_cost_delay=84, autovacuum_freeze_table_age=797746365, autovacuum_enabled=0, parallel_workers=736, autovacuum_vacuum_cost_limit=1031, fillfactor=89, autovacuum_freeze_min_age=296312345, autovacuum_analyze_threshold=542044648, autovacuum_freeze_max_age=1616982866) ON COMMIT DROP ; ERROR: 22023: unrecognized parameter "autovacuum_vacuum_cost_delay" LOCATION: parseRelOptionsInternal, reloptions.c:1445 postgres=# CREATE TEMPORARY TABLE IF NOT EXISTS t0(c0 boolean DEFAULT ((to_hex('0.9439359616884709')) IN (family('255.150.15.43')))) PARTITION BY HASH((t0.c0)oidvector_ops) WITH (autovacuum_freeze_min_age=404730583, fillfactor=91, autovacuum_vacuum_scale_factor=1.0E-5, autovacuum_vacuum_cost_delay=64, autovacuum_freeze_max_age=434090753, autovacuum_analyze_threshold=1645614243, parallel_workers=74, autovacuum_enabled=1, autovacuum_analyze_scale_factor=0.2) ON COMMIT DROP ; ERROR: 22023: unrecognized parameter "autovacuum_freeze_min_age" LOCATION: parseRelOptionsInternal, reloptions.c:1445
Hi,
Le mar. 23 mars 2021 à 14:31, PG Bug reporting form <noreply@postgresql.org> a écrit :
The following bug has been logged on the website:
Bug reference: 16940
Logged by: Zhu Ethan
Email address: crimezjp@foxmail.com
PostgreSQL version: 13.2
Operating system: Ubuntu 20.04
Description:
postgres=# CREATE TEMP TABLE IF NOT EXISTS t0(c0 REAL PRIMARY KEY DEFAULT
(0.7718745), c1 boolean , c2 FLOAT DEFAULT (0.4103656432464894)) PARTITION
BY RANGE((t0.c0)) WITH (autovacuum_vacuum_cost_delay=84,
autovacuum_freeze_table_age=797746365, autovacuum_enabled=0,
parallel_workers=736, autovacuum_vacuum_cost_limit=1031, fillfactor=89,
autovacuum_freeze_min_age=296312345, autovacuum_analyze_threshold=542044648,
autovacuum_freeze_max_age=1616982866) ON COMMIT DROP ;
ERROR: 22023: unrecognized parameter "autovacuum_vacuum_cost_delay"
LOCATION: parseRelOptionsInternal, reloptions.c:1445
postgres=# CREATE TEMPORARY TABLE IF NOT EXISTS t0(c0 boolean DEFAULT
((to_hex('0.9439359616884709')) IN (family('255.150.15.43')))) PARTITION BY
HASH((t0.c0)oidvector_ops) WITH (autovacuum_freeze_min_age=404730583,
fillfactor=91, autovacuum_vacuum_scale_factor=1.0E-5,
autovacuum_vacuum_cost_delay=64, autovacuum_freeze_max_age=434090753,
autovacuum_analyze_threshold=1645614243, parallel_workers=74,
autovacuum_enabled=1, autovacuum_analyze_scale_factor=0.2) ON COMMIT DROP
;
ERROR: 22023: unrecognized parameter "autovacuum_freeze_min_age"
LOCATION: parseRelOptionsInternal, reloptions.c:1445
Not a bug. autovacuum_vacuum_cost_delay and autovacuum_freeze_min_age are not table storage parameters.
--
Guillaume.
Le mar. 23 mars 2021 à 15:38, Guillaume Lelarge <guillaume@lelarge.info> a écrit :
Hi,Le mar. 23 mars 2021 à 14:31, PG Bug reporting form <noreply@postgresql.org> a écrit :The following bug has been logged on the website:
Bug reference: 16940
Logged by: Zhu Ethan
Email address: crimezjp@foxmail.com
PostgreSQL version: 13.2
Operating system: Ubuntu 20.04
Description:
postgres=# CREATE TEMP TABLE IF NOT EXISTS t0(c0 REAL PRIMARY KEY DEFAULT
(0.7718745), c1 boolean , c2 FLOAT DEFAULT (0.4103656432464894)) PARTITION
BY RANGE((t0.c0)) WITH (autovacuum_vacuum_cost_delay=84,
autovacuum_freeze_table_age=797746365, autovacuum_enabled=0,
parallel_workers=736, autovacuum_vacuum_cost_limit=1031, fillfactor=89,
autovacuum_freeze_min_age=296312345, autovacuum_analyze_threshold=542044648,
autovacuum_freeze_max_age=1616982866) ON COMMIT DROP ;
ERROR: 22023: unrecognized parameter "autovacuum_vacuum_cost_delay"
LOCATION: parseRelOptionsInternal, reloptions.c:1445
postgres=# CREATE TEMPORARY TABLE IF NOT EXISTS t0(c0 boolean DEFAULT
((to_hex('0.9439359616884709')) IN (family('255.150.15.43')))) PARTITION BY
HASH((t0.c0)oidvector_ops) WITH (autovacuum_freeze_min_age=404730583,
fillfactor=91, autovacuum_vacuum_scale_factor=1.0E-5,
autovacuum_vacuum_cost_delay=64, autovacuum_freeze_max_age=434090753,
autovacuum_analyze_threshold=1645614243, parallel_workers=74,
autovacuum_enabled=1, autovacuum_analyze_scale_factor=0.2) ON COMMIT DROP
;
ERROR: 22023: unrecognized parameter "autovacuum_freeze_min_age"
LOCATION: parseRelOptionsInternal, reloptions.c:1445Not a bug. autovacuum_vacuum_cost_delay and autovacuum_freeze_min_age are not table storage parameters.
And actually, they are. My bad.
--
Guillaume.
Le mar. 23 mars 2021 à 15:40, Guillaume Lelarge <guillaume@lelarge.info> a écrit :
Le mar. 23 mars 2021 à 15:38, Guillaume Lelarge <guillaume@lelarge.info> a écrit :Hi,Le mar. 23 mars 2021 à 14:31, PG Bug reporting form <noreply@postgresql.org> a écrit :The following bug has been logged on the website:
Bug reference: 16940
Logged by: Zhu Ethan
Email address: crimezjp@foxmail.com
PostgreSQL version: 13.2
Operating system: Ubuntu 20.04
Description:
postgres=# CREATE TEMP TABLE IF NOT EXISTS t0(c0 REAL PRIMARY KEY DEFAULT
(0.7718745), c1 boolean , c2 FLOAT DEFAULT (0.4103656432464894)) PARTITION
BY RANGE((t0.c0)) WITH (autovacuum_vacuum_cost_delay=84,
autovacuum_freeze_table_age=797746365, autovacuum_enabled=0,
parallel_workers=736, autovacuum_vacuum_cost_limit=1031, fillfactor=89,
autovacuum_freeze_min_age=296312345, autovacuum_analyze_threshold=542044648,
autovacuum_freeze_max_age=1616982866) ON COMMIT DROP ;
ERROR: 22023: unrecognized parameter "autovacuum_vacuum_cost_delay"
LOCATION: parseRelOptionsInternal, reloptions.c:1445
postgres=# CREATE TEMPORARY TABLE IF NOT EXISTS t0(c0 boolean DEFAULT
((to_hex('0.9439359616884709')) IN (family('255.150.15.43')))) PARTITION BY
HASH((t0.c0)oidvector_ops) WITH (autovacuum_freeze_min_age=404730583,
fillfactor=91, autovacuum_vacuum_scale_factor=1.0E-5,
autovacuum_vacuum_cost_delay=64, autovacuum_freeze_max_age=434090753,
autovacuum_analyze_threshold=1645614243, parallel_workers=74,
autovacuum_enabled=1, autovacuum_analyze_scale_factor=0.2) ON COMMIT DROP
;
ERROR: 22023: unrecognized parameter "autovacuum_freeze_min_age"
LOCATION: parseRelOptionsInternal, reloptions.c:1445Not a bug. autovacuum_vacuum_cost_delay and autovacuum_freeze_min_age are not table storage parameters.And actually, they are. My bad.
You can't use storage parameters on partitioned tables, as the fine docs say: "Specifying these parameters for partitioned tables is not supported, but you may specify them for individual leaf partitions." See https://www.postgresql.org/docs/13/sql-createtable.html#SQL-CREATETABLE-STORAGE-PARAMETERS.
Hope I'm not wrong this time :)
--
Guillaume.
On Tue, Mar 23, 2021 at 04:26:41PM +0100, Guillaume Lelarge wrote: > You can't use storage parameters on partitioned tables, as the fine docs > say: "Specifying these parameters for partitioned tables is not supported, > but you may specify them for individual leaf partitions." See > https://www.postgresql.org/docs/13/sql-createtable.html#SQL-CREATETABLE-STORAGE-PARAMETERS Partitioned tables have no relation options. As of reloptions.c: bytea * partitioned_table_reloptions(Datum reloptions, bool validate) { /* * There are no options for partitioned tables yet, but this is able to do * some validation. */ return (bytea *) build_reloptions(reloptions, validate, RELOPT_KIND_PARTITIONED, 0, NULL, 0); } -- Michael