Re: Explain XML patch v2

From: Tom Raney <raneyt(at)cs(dot)pdx(dot)edu>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-patches(at)postgresql(dot)org, Tom Raney <raneyt(at)cecs(dot)pdx(dot)edu>, Gregory Stark <stark(at)enterprisedb(dot)com>
Subject: Re: Explain XML patch v2
Date: 2008-07-02 20:05:38
Message-ID: 486BDF92.8090700@cs.pdx.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Peter Eisentraut wrote:
> Am Mittwoch, 2. Juli 2008 schrieb Tom Raney:
>
>> This is an update to my EXPLAIN XML patch submitted a few days ago.
>>
>
> Could you explain how you came up with the XML schema design? I suppose you
> just made something up that went along with the existing XML output.
>
Yes, it is based on the existing output.
> I would like to see more integration with the spirit of the existing XML
> functionality. For example, instead of things like
>
> "<runtime ms=\"%.3f\" />\n"
>
> we ought to be using XML Schema data types for time intervals and so on.
>
The DTD provides only rudimentary document validation but it has no
support for type checking. So, it may make sense to move to the more
rigorous XML Schema. There is a 'duration' data type that could be used
for the instance listed above. Or, we could define our own.
> We might also want to use an XML namespace.
>
Taking the 'ms' field listed above:
xmlns="http://www.postgresql.org/v8.4/ms" or something like this?
> Table and index names should be escaped using the existing escape mechanism
> for identifiers. There might also be encoding issues.
>
That's a good point. Or, wrap them with CDATA.
> It would also be interesting if EXPLAIN could optionally be a function that
> returns a datum of type XML, to allow further processing.
>
> Any thoughts on these issues?
>
I am in the process of writing a parser of this XML output for the Red
Hat Visual Explain tool. I want to see what surprises come up during
implementation.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Dave Page 2008-07-02 20:14:33 Re: A Windows x64 port of PostgreSQL
Previous Message Merlin Moncure 2008-07-02 19:48:24 Re: Commitfest status?

Browse pgsql-patches by date

  From Date Subject
Next Message Ken Camann 2008-07-02 21:41:07 Working on native Windows x64 version of PostgreSQL
Previous Message daveg 2008-07-02 19:39:32 Re: Explain XML patch v2