Re: pgsql: Declare assorted array functions using anycompatible not anyelem

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: pgsql: Declare assorted array functions using anycompatible not anyelem
Дата
Msg-id dc77bfb2-3b98-c3e5-a825-6c087d51f51c@dunslane.net
обсуждение исходный текст
Ответ на Re: pgsql: Declare assorted array functions using anycompatible not anyelem  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: pgsql: Declare assorted array functions using anycompatible not anyelem  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-committers
On 11/9/20 5:41 PM, Tom Lane wrote:
>
> What I have in mind to apply to 9.5 through 13 is per attached.
> You could either redefine the aggregate similarly in 9.2-9.4,
> or just drop it.  I doubt the latter leads to any interesting
> loss of coverage for xversion upgrade, as there's plenty of other
> user-defined aggregates in the regression database.



You also need to modify first_el_agg_any.


Here's what I have working on crake::


        if ($oversion le 'REL9_4_STABLE')
        {
            # this is to be fixed in 9.5 and later
            $prstmt = join(';',
                           'drop aggregate if exists
public.array_cat_accum(anyarray)',
                           'CREATE AGGREGATE array_larger_accum
(anyarray) ' .
                           ' ( ' .
                           '   sfunc = array_larger, ' .
                           '   stype = anyarray, ' .
                           '   initcond = $${}$$ ' .
                           '  ) ' );
            system( "$other_branch/inst/bin/psql -X -e "
                      . " -c '" . $prstmt . "' "
                      . "regression "
                      . ">> '$upgrade_loc/$oversion-copy.log' 2>&1");
            return if $?;
        }
        # drop this branch when upstream is renovated
        else
        {
            $prstmt = join(';',
                          'drop aggregate if exists
public.array_cat_accum(anyarray)',
                          'drop aggregate if exists
public.first_el_agg_any(anyelement)');
            system( "$other_branch/inst/bin/psql -X -e "
                      . " -c '$prstmt' "
                      . "regression "
                      . ">> '$upgrade_loc/$oversion-copy.log' 2>&1");
            return if $?;
        }


When you fix the live branches I'll delete the "else" branch and push
the change to the git repo.


cheers


andrew








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

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: pgsql: Remove -o option to postmaster
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: pgsql: pg_rewind: Fix thinko in parsing target WAL.