Re: BUG #15934: pg_dump output in wrong order if custom operator class is used as subtype_opclass in a range type
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: tom@intevation.de
Cc: pgsql-bugs@lists.postgresql.org
Date: 2019-07-31T18:26:36Z
Lists: pgsql-bugs
Attachments
- fix-dump-dependencies-for-custom-opclasses.patch (text/x-diff) patch
I wrote: > Clearly, we gotta upgrade pg_dump's intelligence about handling this > dependency structure. The most straightforward fix would involve > promoting pg_amop (and pg_amproc) entries to be full DumpableObjects, > but I'm apprehensive about the overhead that would add ... After further thought, I realized we could fix it far less invasively than that, by teaching getDependencies() to translate pg_depend entries for the pg_amop/amproc rows to look like dependencies for their parent opfamily. This looks messy, but in a typical database without any custom opclasses, it's actually really cheap, because there won't be any pg_depend entries satisfying the classid conditions. I wasn't looking forward to back-patching the other idea, but this patch seems like it should be pretty painless. Again, thanks for the report! regards, tom lane
Commits
-
Fix pg_dump's handling of dependencies for custom opclasses.
- c64e2970592c 11.5 landed
- b31a9802262c 9.6.15 landed
- 9dd74ba5aebc 9.5.19 landed
- 7615afa48e7c 10.10 landed
- 4e10b6f82355 9.4.24 landed
- 408f759380c7 12.0 landed
- 07b39083c2ac 13.0 landed