Fix a pg_dump output ordering problem introduced in 8.3 by the addition of
authorTom Lane <tgl@sss.pgh.pa.us>
Sun, 18 Jan 2009 20:44:45 +0000 (20:44 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sun, 18 Jan 2009 20:44:45 +0000 (20:44 +0000)
commit390081e3f5071f777159f0ff28b2813c97b35b6e
tree8ca8e537015c1b0b51a95d5901fece728de46437
parentfd1d4b3acdcf335d39c5cf9f3e9daf0b30227f82
Fix a pg_dump output ordering problem introduced in 8.3 by the addition of
array types for composite types.  Although pg_dump understood it wasn't
supposed to dump these array types as separate objects, it must include
them in the dependency ordering analysis, and it was improperly assigning them
the same relatively-high sort priority as regular types.  This resulted in
effectively moving composite types and tables up to that same high priority,
which broke any ordering requirements that weren't explicitly enforced by
dependencies.  In particular user-defined operator classes, which should come
out before tables, failed to do so.  Per report from Brendan Jurd.

In passing, also fix an ill-considered decision to give text search objects
the same sort priority as functions and operators --- the sort result looks
a lot nicer if different object types are kept separate.  The recent
foreign-data patch had copied that decision, making the sort ordering even
messier :-(
src/bin/pg_dump/pg_dump.c
src/bin/pg_dump/pg_dump.h
src/bin/pg_dump/pg_dump_sort.c