Re: [PATCH] Optional OR REPLACE in CREATE OPERATOR statement

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PATCH] Optional OR REPLACE in CREATE OPERATOR statement
Дата
Msg-id 1917173.1657034968@sss.pgh.pa.us
обсуждение исходный текст
Ответ на [PATCH] Optional OR REPLACE in CREATE OPERATOR statement  (Svetlana Derevyanko <s.derevyanko@postgrespro.ru>)
Ответы Re[2]: [PATCH] Optional OR REPLACE in CREATE OPERATOR statement  (Svetlana Derevyanko <s.derevyanko@postgrespro.ru>)
Re: [PATCH] Optional OR REPLACE in CREATE OPERATOR statement  ("Gregory Stark (as CFM)" <stark.cfm@gmail.com>)
Список pgsql-hackers
=?UTF-8?B?U3ZldGxhbmEgRGVyZXZ5YW5rbw==?= <s.derevyanko@postgrespro.ru> writes:
> It seems useful to have [OR REPLACE] option in CREATE OPERATOR statement, as in CREATE FUNCTION. This option may be
goodfor writing extension update scripts, to avoid errors with re-creating the same operator. 

No, that's not acceptable.  CREATE OR REPLACE should always produce
exactly the same final state of the object, but in this case we cannot
change the underlying function if the operator already exists.

(At least, not without writing a bunch of infrastructure to update
existing views/rules that might use the operator; which among other
things would create a lot of deadlock risks.)

            regards, tom lane



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

Предыдущее
От: Jelte Fennema
Дата:
Сообщение: Re: [EXTERNAL] Re: Support load balancing in libpq
Следующее
От: vignesh C
Дата:
Сообщение: Re: Handle infinite recursion in logical replication setup