From: | Philip Warner <pjw(at)rhyme(dot)com(dot)au> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, The Hermit Hacker <scrappy(at)hub(dot)org> |
Cc: | Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Suggested fix for pg_dump |
Date: | 2001-01-12 13:03:28 |
Message-ID: | 3.0.5.32.20010113000328.02e2ad40@mail.rhyme.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
At 13:29 7/01/01 -0500, Tom Lane wrote:
>The Hermit Hacker <scrappy(at)hub(dot)org> writes:
>> Essentially, worst case scenario, we are going from 'broken->broken' ...
>
>No, I don't think so. The current pg_dump code is only broken if
>you've renamed a column involved in a foreign-key dependency (if I
>understood the thread correctly). But Philip is proposing to change
>pg_dump to rely on alter table add constraint for *all* PRIMARY KEY
>constructs.
I've got a version of this working now, but it raises a further question:
should I also put the CHECK constraints into ALTER TABLE statements?
Eventually they should go there, but maybe not for 7.1 given the concerns
over ALTER TABLE ADD CONSTRAINT.
Reasons for:
- It's nicer
- It's more consistent with PK
- Can use pg_restore to restore tables without constraints
Reasons against:
- ALTER TABLE ADD CONSTRAINT is untested
- We're in beta, and the code ain't broke
I suspect the last point says it all...
----------------------------------------------------------------
Philip Warner | __---_____
Albatross Consulting Pty. Ltd. |----/ - \
(A.B.N. 75 008 659 498) | /(@) ______---_
Tel: (+61) 0500 83 82 81 | _________ \
Fax: (+61) 0500 83 82 82 | ___________ |
Http://www.rhyme.com.au | / \|
| --________--
PGP key available upon request, | /
and from pgp5.ai.mit.edu:11371 |/
From | Date | Subject | |
---|---|---|---|
Next Message | The Hermit Hacker | 2001-01-12 13:07:03 | RE: AW: Re: GiST for 7.1 !! |
Previous Message | Anatoly K. Lasareff | 2001-01-12 12:40:34 | pgaccess: russian fonts && SQL window??? |