Re: PGXS: REGRESS_OPTS=--load-language=plpgsql

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: PGXS: REGRESS_OPTS=--load-language=plpgsql
Дата
Msg-id 7557.1266606569@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: PGXS: REGRESS_OPTS=--load-language=plpgsql  (David Fetter <david@fetter.org>)
Ответы Re: PGXS: REGRESS_OPTS=--load-language=plpgsql  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
David Fetter <david@fetter.org> writes:
> CREATE OR REPLACE LANGUAGE is an even bigger tar pit.
> http://archives.postgresql.org/pgsql-hackers/2009-10/msg00386.php

The reason that patch got rejected was that it was implementing
CREATE IF NOT EXISTS --- under a false name.  The problem with
that is summarized here:
http://archives.postgresql.org/pgsql-patches/2008-03/msg00416.php

It wouldn't be that hard to implement actual CREATE OR REPLACE
if we decide that's the most useful solution here.  The code
would need to be prepared to use heap_update instead of heap_insert,
and to get rid of old dependencies, but there is plenty of precedent
for that.

The sticking point for me is still whether or not it's really a good
idea for pg_dump to be emitting CREATE OR REPLACE LANGUAGE.  It does not
do that for any other object type.  On the other hand, we've already
made languages a special case in pg_dump, since it emits the abbreviated
form of CREATE LANGUAGE in most cases rather than trying to duplicate
the existing object definition.  Maybe there wouldn't be any bad results
in practice.
        regards, tom lane


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: PGXS: REGRESS_OPTS=--load-language=plpgsql
Следующее
От: Dimitri Fontaine
Дата:
Сообщение: Re: PGXS: REGRESS_OPTS=--load-language=plpgsql