From: | "Vitaly Davydov" <v(dot)davydov(at)postgrespro(dot)ru> |
---|---|
To: | "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | ALTER DATABASE RESET with unexistent guc doesn't report an error |
Date: | 2025-09-11 08:35:36 |
Message-ID: | 30783e-68c28a00-9-41004480@130449754 |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Dear Hackers,
I've found that ALTER DATABASE RESET with an unexistent guc does nothing without
error reporting.
ALTER DATABASE SET reports an error if guc doesn't exist:
> alter database mydb set myparam to 10;
ERROR: unrecognized configuration parameter "myparam"
ALTER DATABASE RESET doesn't report an error at all:
> alter database mydb reset myparam;
ALTER DATABASE
I think it is a wrong behaviour. I believe, ALTER DATABASE RESET should report
an error in this case. I've also think that ALTER DATABASE RESET TABLESPACE does
nothing without any error reporting. I've prepared a simple patch to handle this
case (master branch). It adds a check for guc existence with error reporting.
With best regards,
Vitaly
Attachment | Content-Type | Size |
---|---|---|
0001-Add-check-for-unexistent-guc-in-ALTER-DATABASE-RESET.patch | text/x-patch | 2.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | sunil s | 2025-09-11 08:51:14 | Re: Unnecessary delay in streaming replication due to replay lag |
Previous Message | Kirill Reshke | 2025-09-11 08:35:11 | Re: Display is_prev_bucket_same_wrt of xl_hash_squeeze_page |