Re: pg_depend explained - Mailing list pgsql-hackers

From David Fetter
Subject Re: pg_depend explained
Date
Msg-id 20110112193628.GC21124@fetter.org
Whole thread Raw
In response to Re: pg_depend explained  (Joel Jacobson <joel@gluefinance.com>)
Responses Re: pg_depend explained  (Joel Jacobson <joel@gluefinance.com>)
Re: pg_depend explained  (Joel Jacobson <joel@gluefinance.com>)
List pgsql-hackers
On Wed, Jan 12, 2011 at 08:06:24PM +0100, Joel Jacobson wrote:
> 2011/1/12 Tom Lane <tgl@sss.pgh.pa.us>:
> > I've sometimes found it useful to think of internal dependencies as
> > acting like normal dependencies pointing in the other direction.
> > I'm not sure that would do much to solve your problem, but it might
> > be worth trying.
> 
> Tom, you are a genious! No, seriously, I mean it, this is awesome, it
> worked! YES! You totally saved my day! Thank you! Finally! I'm so
> happy! :-) :-) :-)
> 
> This was the little piece of code:
> 
> CASE WHEN DepType ~ '^(a|ni|in|an|na)$' THEN
>     --- Swap edges
> ELSE
>     -- Do not swap edges
> END
> 
> Look at the attached svg graph how beautiful the automatically
> generated graph look like now! :-)
> 
> The tsort of the objects now sort all the normal objects in a creatable order!
> 
> Here is the result of the tsort (only including the normal objects
> (the one I care about (I don't have to create the internal/auto
> objects, nor drop them))):
> 
> The query below can both produce a DOT-format graph and a tsort of the
> creatable order of objects:
> 
> WITH
> NewObjectOids AS (
>     SELECT * FROM pg_depend WHERE deptype <> 'p'
>     EXCEPT
>     SELECT * FROM pg_depend_before

To what does pg_depend_before refer?

Cheers,
David.
-- 
David Fetter <david@fetter.org> http://fetter.org/
Phone: +1 415 235 3778  AIM: dfetter666  Yahoo!: dfetter
Skype: davidfetter      XMPP: david.fetter@gmail.com
iCal: webcal://www.tripit.com/feed/ical/people/david74/tripit.ics

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: arrays as pl/perl input arguments [PATCH]
Next
From: "David E. Wheeler"
Date:
Subject: Re: arrays as pl/perl input arguments [PATCH]