On Wed, Jul 29, 2020 at 11:34:07PM +0200, Daniel Gustafsson wrote:
> Extreme cases for sure, but more importantly, there should be no cases when
> this would cause an increase wrt the status quo.
Yep.
> Maybe it'd be worth pre-computing by a first pass which tracks pinned objects
> in a bitmap; with a second pass which then knows how many and which to insert
> into slots?
Or it could be possible to just rebuild a new list of dependencies
before insertion into the catalog. No objections with a bitmap, any
approach would be fine here as long as there is a first pass on the
item list.
> Fair enough, let's break out pg_depend and I'll have another go at that.
Thanks. Attached is a polished version of the patch that I intend to
commit for pg_attribute and pg_shdepend. Let's look again at
pg_depend later, as there are also links with the handling of
dependencies for ALTER TABLE mainly.
--
Michael