From: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
---|---|
To: | Craig Ringer <craig(at)2ndquadrant(dot)com> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: patch: function xmltable |
Date: | 2016-09-27 05:29:03 |
Message-ID: | CAFj8pRAC=z_qPdA5PHmP_VzsnTiLU2cOyF5_DWcQSjp+cmqryA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
2016-09-27 5:53 GMT+02:00 Craig Ringer <craig(at)2ndquadrant(dot)com>:
> On 24 September 2016 at 14:01, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
> wrote:
>
> >> Did some docs copy-editing and integrated some examples. Explained how
> >> nested elements work, that multiple top level elements is an error,
> >> etc. Explained the time-of-evaluation stuff. Pointed out that you can
> >> refer to prior output columns in PATH and DEFAULT, since that's weird
> >> and unusual compared to normal SQL. Documented handling of multiple
> >> node matches, including the surprising results of somepath/text() on
> >> <somepath>x<!--blah-->y</somepath>. Documented handling of nested
> >> elements. Documented that xmltable works only on XML documents, not
> >> fragments/forests.
> >
> >
> > I don't understand to this sentence: "It is possible for a PATH
> expression
> > to reference output columns that appear before it in the column-list, so
> > paths may be dynamically constructed based on other parts of the XML
> > document:"
>
> This was based on a misunderstanding of something you said earlier. I
> thought the idea was to allow this to work:
>
> SELECT * FROM xmltable('/x' PASSING
> '<x><elemName>a</elemName><a>value</a></x>' COLUMNS elemName text,
> extractedValue text PATH elemName);
>
> ... but it doesn't:
>
>
> SELECT * FROM xmltable('/x' PASSING
> '<x><elemName>a</elemName><a>value</a></x>' COLUMNS elemName text,
> extractedValue text PATH elemName);
> ERROR: column "elemname" does not exist
> LINE 1: ...' COLUMNS elemName text, extractedValue text PATH elemName);
>
> ... so please delete that text. I thought I'd tested it but the state
> of my tests dir says I just got distracted by another task at the
> wrong time.
>
deleted
Regards
Pavel
>
> --
> Craig Ringer http://www.2ndQuadrant.com/
> PostgreSQL Development, 24x7 Support, Training & Services
>
Attachment | Content-Type | Size |
---|---|---|
xmltable-11.patch.gz | application/x-gzip | 28.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | davinder singh | 2016-09-27 06:02:11 | Some information about the small portion of source code of postgreSQL |
Previous Message | Amit Langote | 2016-09-27 05:27:25 | Re: Declarative partitioning - another take |