Re: Make name optional in CREATE STATISTICS - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: Make name optional in CREATE STATISTICS
Date
Msg-id CANbhV-HPE9=d2Oa_zE6xJLA8HX1wtjDXguXWyHDQAXpEe0NpFw@mail.gmail.com
Whole thread Raw
In response to Re: Make name optional in CREATE STATISTICS  (Dean Rasheed <dean.a.rasheed@gmail.com>)
List pgsql-hackers
On Thu, 21 Jul 2022 at 15:12, Dean Rasheed <dean.a.rasheed@gmail.com> wrote:
>
> On Wed, 20 Jul 2022 at 12:01, Matthias van de Meent
> <boekewurm+postgres@gmail.com> wrote:
> >
> > On Wed, 13 Jul 2022 at 08:07, Simon Riggs <simon.riggs@enterprisedb.com> wrote:
> > >
> > > > + *                CREATE STATISTICS [ [IF NOT EXISTS] stats_name ]
> >
> > I think this is ready for a committer, so I've marked it as such.
> >
>
> Picking this up...
>
> I tend to agree with Matthias' earlier point about avoiding code
> duplication in the grammar. Without going off and refactoring other
> parts of the grammar not related to this patch, it's still a slightly
> smaller, simpler change, and less code duplication, to do this using a
> new opt_stats_name production in the grammar, as in the attached.
>
> I also noticed a comment in CreateStatistics() that needed updating.
>
> Barring any further comments, I'll push this shortly.

Nice change, please proceed.

-- 
Simon Riggs                http://www.EnterpriseDB.com/



pgsql-hackers by date:

Previous
From: Junwang Zhao
Date:
Subject: Re: [PATCH v1] eliminate duplicate code in table.c
Next
From: Robert Haas
Date:
Subject: let's disallow ALTER ROLE bootstrap_superuser NOSUPERUSER