pg_dump table order - Mailing list pgsql-hackers

From Ross J. Reedstrom
Subject pg_dump table order
Date
Msg-id 19990912201856.A20044@wallace.ece.rice.edu
Whole thread Raw
Responses Re: [HACKERS] pg_dump table order  ("Ross J. Reedstrom" <reedstrm@wallace.ece.rice.edu>)
Re: [HACKERS] pg_dump table order  (Bruce Momjian <maillist@candle.pha.pa.us>)
Re: [HACKERS] pg_dump table order  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Hey hackers:
I'vebeen using pg_dump in a typical three db setup: development,
staging, and live. The output of pg_dump is ordered by oid, so as the
db's histories diverge, the output does as well. That is, if identical
tables get created in the development and staging dbs, for example, but
in a different order, I can't us diff to test this. I was wondering if
there is any reason why the order couldn't be by tablename, instead of
oid, since the ordering of creation of sequences and types and such is
taken care of. 

Ah I think I just figured it out: it's that pesky object
support, isn't it? In order to use a table (class) as a member (field)
of another table, it has to exist first, and the only thing in the
system table that ensures that is oid. Bummer. Hmm, it'd still be useful
for comparision purposes, but it wouldn't gaurantee correct SQL scripts.
Perhaps I'll just hack my local copy with an extra switch for "class
name order output".  Anyone else want it?

Ross
-- 
Ross J. Reedstrom, Ph.D., <reedstrm@rice.edu> 
NSBRI Research Scientist/Programmer
Computer and Information Technology Institute
Rice University, 6100 S. Main St.,  Houston, TX 77005


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: pgaccess update for 6.5.2?
Next
From: "Ross J. Reedstrom"
Date:
Subject: Re: [HACKERS] pg_dump table order