Peter Eisentraut <peter_e@gmx.net> writes:
> The problem with a pure oid-based ordering concept is that (as you
> yourself pointed out) it won't work if you alter some object in question
> after creation. The obvious case would be an alter function (to be
> implemented), but another case is (probably) alter column set default (is
> implemented).
Right; a genuine dependency analysis would be better. Also a lot more
painful to implement.
As you say, pg_dump could do with a wholesale rewrite, and maybe that
would be a good time to look at the dependency-based approach. In the
meantime, I think dumping in OID order would fix 90% of the problem for
10% of the work...
regards, tom lane