ALTER DATABASE RESET with unexistent guc doesn't report an error

Поиск
Список
Период
Сортировка
От Vitaly Davydov
Тема ALTER DATABASE RESET with unexistent guc doesn't report an error
Дата
Msg-id 30783e-68c28a00-9-41004480@130449754
обсуждение исходный текст
Ответы Re: ALTER DATABASE RESET with unexistent guc doesn't report an error
Список 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

Вложения

В списке pgsql-hackers по дате отправления: