Re: EXPLAIN omits schema?

From: "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>
To: Gregory Stark <stark(at)enterprisedb(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Dave Page <dpage(at)postgresql(dot)org>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: EXPLAIN omits schema?
Date: 2007-06-13 19:33:15
Message-ID: 4670467B.2070802@commandprompt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Gregory Stark wrote:
> "Joshua D. Drake" <jd(at)commandprompt(dot)com> writes:
>
>>> I agree. XML seems like a fairly natural fit for this. Just as people should
>>> not try to shoehorn everything into XML, neither should they try to shoehorn
>>> everything into a relational format either.
>>>
>>> Now all we need is an XML schema for it ;-)
>> Well I am not a big fan of XML but it certainly seems applicable in this
>> case.
>
> I'm not a fan either so perhaps I'm biased, but this seems like a good example
> of where it would be an *awful* idea.
>
> Once you have an XML plan what can you do with it? All you can do is parse it
> into constituent bits and display it. You cant do any sort of comparison
> between plans, aggregate results, search for plans matching constraints, etc.

Honestly, I had never even considered doing such a thing. I would just
like a nice way to parse explain output :)

Joshua D. Drake

>
> How would I, with XML output, do something like:
>
> SELECT distinct node.relation
> FROM plan_table
> WHERE node.expected_rows < node.actual_rows*2;
>
> or
>
> SELECT node.type, average(node.ms/node.cost)
> FROM plan_table
> GROUP BY node.type;
>

--

=== The PostgreSQL Company: Command Prompt, Inc. ===
Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240
Providing the most comprehensive PostgreSQL solutions since 1997
http://www.commandprompt.com/

Donate to the PostgreSQL Project: http://www.postgresql.org/about/donate
PostgreSQL Replication: http://www.commandprompt.com/products/

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-06-13 21:23:03 Can autovac try to lock multiple tables at once?
Previous Message Alvaro Herrera 2007-06-13 18:49:11 Re: [PATCHES] Autovacuum launcher doesn't notice death of postmaster immediately