Re: Anyone working on pg_dump dependency ordering?

From: Rod Taylor <pg(at)rbt(dot)ca>
To: Andreas Pflug <pgadmin(at)pse-consulting(dot)de>
Cc: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>, Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>, PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Anyone working on pg_dump dependency ordering?
Date: 2003-11-22 22:20:48
Message-ID: 1069539647.16912.124.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 2003-11-22 at 16:53, Andreas Pflug wrote:
> Stephan Szabo wrote:
>
> >You're going to potentially have the constraints scattered in any case due
> >to circular dependency chains. I'd think that having all the constraints
> >in one place would be easier than trying to go through the list of tables
> >that might be in a circular chain in order to find the constraints.
> >
> >
> I still disagree. cyclic dependencies should be avoided anyhow. You'll
> get an awful lot of trouble loading data in such a case. Some database
> systems refuse to create such stuff right away (mssql).

CREATE TABLE a (col integer primary key);
CREATE TABLE b (col integer primary key);
ALTER TABLE a ADD FOREIGN KEY (col) REFERENCES b INITIALLY DEFERRED;
ALTER TABLE b ADD FOREIGN KEY (col) REFERENCES a;

How does MSSQL deal with the above?

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Stark 2003-11-22 22:24:08 Re: Sponsoring enterprise features
Previous Message Andreas Pflug 2003-11-22 21:53:59 Re: Anyone working on pg_dump dependency ordering?