Re: pg_dump new feature: exporting functions only. Bad or good idea ?

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Lætitia Avrot <laetitia(dot)avrot(at)gmail(dot)com>
Cc: Ryan Lambert <ryan(at)rustprooflabs(dot)com>, Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, ahsan hadi <ahsan(dot)hadi(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_dump new feature: exporting functions only. Bad or good idea ?
Date: 2021-11-09 14:23:07
Message-ID: E3C31209-12DD-4D1F-8B35-E52B2E11B59A@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> On 30 Jul 2021, at 12:55, Lætitia Avrot <laetitia(dot)avrot(at)gmail(dot)com> wrote:
>
> > On Fri, Jul 9, 2021 at 4:43 PM Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> wrote:
> >
> > The main question I have is whether this should include procedures. I'd
> > probably argue procedures should be considered different from functions
> > (i.e. requiring a separate --procedures-only option), because it pretty
> > much is meant to be a separate object type. We don't allow calling DROP
> > FUNCTION on a procedure, etc. It'd be silly to introduce an unnecessary
> > ambiguity in pg_dump and have to deal with it sometime later.
>
> I respectfully disagree. In psql, the `\ef` and `\df` metacommands will also list procedures, not just functions.

I tend to agree that we should include both, while they are clearly different I
don't think it would be helpful in this case to distinguish.

Looking at this thread I think it makes sense to go ahead with this patch. The
filter functionality worked on in another thread is dealing with cherry-picking
certain objects where this is an all-or-nothing switch, so I don't think they
are at odds with each other.

--
Daniel Gustafsson https://vmware.com/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Gustafsson 2021-11-09 14:28:45 Re: An out-of-date comment in nodeIndexonlyscan.c
Previous Message Daniel Gustafsson 2021-11-09 14:12:39 Commitfest 2021-11 Patch Triage - Part 2