From: | Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Matthias van de Meent <boekewurm+postgres(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: get_constraint_index() and conindid |
Date: | 2020-12-09 14:50:26 |
Message-ID: | 2ddf07fc-883f-f1c4-dfbc-e977a0162e66@enterprisedb.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2020-12-09 07:37, Michael Paquier wrote:
>>> Only thing I could think of is that it maybe could use a (small)
>>> comment in the message on that/why get_constraint_index is moved to
>>> utils/lsyscache from catalog/dependency, as that took me some time to
>>> understand.
>>
>> commit message could reasonably say that maybe, but I don't think we
>> need to memorialize it in a comment. lsyscache.c *is* where one
>> would expect to find a simple catalog-field-fetch function like this.
>> The previous implementation was not that, so it didn't belong there.
>
> Agreed.
Thanks, I committed it with an expanded commit message.
After further inspection, I'm not going to do anything about the nearby
get_index_constraint() at this item. The current implementation can use
an index on pg_depend. A scan of pg_constraint has no index available.
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2020-12-09 15:40:21 | Insert Documentation - Returning Clause and Order |
Previous Message | Alvaro Herrera | 2020-12-09 13:56:45 | Re: [bug fix] ALTER TABLE SET LOGGED/UNLOGGED on a partitioned table does nothing silently |