Re: why partition pruning doesn't work? - Mailing list pgsql-hackers

From Robert Haas
Subject Re: why partition pruning doesn't work?
Date
Msg-id CA+TgmoZmLY7=b4_ry1OiRAha+aTg8FqScc0D3Ju2Z5_DT0KndQ@mail.gmail.com
Whole thread Raw
In response to Re: why partition pruning doesn't work?  (David Rowley <david.rowley@2ndquadrant.com>)
List pgsql-hackers
On Sun, Jul 15, 2018 at 8:24 PM, David Rowley
<david.rowley@2ndquadrant.com> wrote:
>> +1.  In fact, maybe we ought to go a little further and have a
>> relation_reopen(oid, mode) that verifies that a lock in the specified
>> mode is held.
>
> Wouldn't it be better to just store the Relation indexed by its relid
> somewhere the first time we opened it? Then just do a direct array
> lookup on that rather than looking up by hashtable in syscache?

Yes, that would be better, IMHO anyway.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: David Rowley
Date:
Subject: Re: Internal error XX000 with enable_partition_pruning=on, pg 11beta1 on Debian
Next
From: David Fetter
Date:
Subject: Make foo=null a warning by default.