Re: about allow_system_table_mods and SET STATISTICS - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: about allow_system_table_mods and SET STATISTICS
Date
Msg-id dfdb11ce-ddc7-0d7c-0b9f-4ec78eff3388@2ndquadrant.com
Whole thread Raw
In response to Re: about allow_system_table_mods and SET STATISTICS  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: about allow_system_table_mods and SET STATISTICS  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 2019-12-05 00:16, Tom Lane wrote:
> Seems reasonable.  The argument for making this an exception to
> allow_system_table_mods was always more about expediency than logical
> cleanliness.  After the recent changes I think it's okay to remove the
> special case (especially since nobody has griped about it being broken).
> 
> However ... if we're not going to have that special case, couldn't
> we get rid of the whole business of having a special permissions test?
> What is it that ATSimplePermissions can't handle here?  The business
> about requiring a colName certainly doesn't need to be done before the
> ownership check (in fact, it could be left to execution, so we don't need
> a prep function at all anymore).

Good point.  Done in the attached patch.

(If someone wanted to revive the original functionality, it would 
nowadays probably be easier to add a flag ATT_SYSTEM_TABLE to 
ATSimplePermissions(), so there is really no reason to keep the old 
function separate.)

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment

pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: Unicode normalization test broken output
Next
From: "Karl O. Pinc"
Date:
Subject: Re: proposal: minscale, rtrim, btrim functions for numeric