Re: pg_depend explained

From: David Fetter <david(at)fetter(dot)org>
To: Joel Jacobson <joel(at)gluefinance(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Florian Pflug <fgp(at)phlo(dot)org>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_depend explained
Date: 2011-01-12 19:36:28
Message-ID: 20110112193628.GC21124@fetter.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jan 12, 2011 at 08:06:24PM +0100, Joel Jacobson wrote:
> 2011/1/12 Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)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(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David E. Wheeler 2011-01-12 19:39:56 Re: arrays as pl/perl input arguments [PATCH]
Previous Message Alvaro Herrera 2011-01-12 19:36:17 Re: arrays as pl/perl input arguments [PATCH]