Re: debug_print_plan logs table alias used in join, not table name itself - Mailing list pgsql-general

From Tom Lane
Subject Re: debug_print_plan logs table alias used in join, not table name itself
Date
Msg-id 23413.1295460631@sss.pgh.pa.us
Whole thread Raw
In response to debug_print_plan logs table alias used in join, not table name itself  (frank joerdens <fiskadoro@gmail.com>)
Responses Re: debug_print_plan logs table alias used in join, not table name itself  (frank joerdens <fiskadoro@gmail.com>)
List pgsql-general
frank joerdens <fiskadoro@gmail.com> writes:
> I was just experimenting with debug logging on 8.3 and am finding that
> I can't get it to log the table names involved in a given query, it
> will always print the table alias used in your join instead, e.g.

I don't know why you think that debug_print_plan is meant to do any such
thing; it isn't meant to be useful to end users at all.  You could get
the table identity from the relation OID that's in the plan tree, but
the name is not there.

In 8.4 and up there's an "auto_explain" contrib module that is probably
much closer to what you want.

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Some problem with the NOTIFY/LISTEN
Next
From: Tom Lane
Date:
Subject: Re: How can I find a schema that a table belong to?