postgresql/src/backend
Alvaro Herrera 251cf2e27b Fix minor deficiencies in XMLTABLE, xpath(), xmlexists()
Correctly process nodes of more types than previously.  In some cases,
nodes were being ignored (nothing was output); in other cases, trying to
return them resulted in errors about unrecognized nodes.  In yet other
cases, necessary escaping (of XML special characters) was not being
done.  Fix all those (as far as the authors could find) and add
regression tests cases verifying the new behavior.

I (Álvaro) was of two minds about backpatching these changes.  They do
seem bugfixes that would benefit most users of the affected functions;
but on the other hand it would change established behavior in minor
releases, so it seems prudent not to.

Authors: Pavel Stehule, Markus Winand, Chapman Flack
Discussion:
   https://postgr.es/m/CAFj8pRA6J25CtAZ2TuRvxK3gat7-bBUYh0rfE2yM7Hj9GD14Dg@mail.gmail.com
   https://postgr.es/m/8BDB0627-2105-4564-AA76-7849F028B96E@winand.at

The elephant in the room as pointed out by Chapman Flack, not fixed in
this commit, is that we still have XMLTABLE operating on XPath 1.0
instead of the standard-mandated XQuery (or even its subset XPath 2.0).
Fixing that is a major undertaking, however.
2019-03-07 18:16:34 -03:00
..
access tableam: introduce table AM infrastructure. 2019-03-06 09:54:38 -08:00
bootstrap tableam: introduce table AM infrastructure. 2019-03-06 09:54:38 -08:00
catalog Fix the BY {REF,VALUE} clause of XMLEXISTS/XMLTABLE 2019-03-07 11:20:35 -03:00
commands Allow ATTACH PARTITION with only ShareUpdateExclusiveLock. 2019-03-07 11:13:12 -05:00
executor Allow ATTACH PARTITION with only ShareUpdateExclusiveLock. 2019-03-07 11:13:12 -05:00
foreign Update copyright for 2019 2019-01-02 12:44:25 -05:00
jit Renaming for new subscripting mechanism 2019-02-01 12:50:32 -03:00
lib Make use of compiler builtins and/or assembly for CLZ, CTZ, POPCNT. 2019-02-15 23:22:33 -05:00
libpq Get rid of another unconstify through API changes 2019-02-14 20:44:47 +01:00
main Replace @postgresql.org with @lists.postgresql.org for mailinglists 2019-01-19 19:06:35 +01:00
nodes Allow ATTACH PARTITION with only ShareUpdateExclusiveLock. 2019-03-07 11:13:12 -05:00
optimizer Fix handling of targetlist SRFs when scan/join relation is known empty. 2019-03-07 14:22:13 -05:00
parser Fix the BY {REF,VALUE} clause of XMLEXISTS/XMLTABLE 2019-03-07 11:20:35 -03:00
partitioning Allow ATTACH PARTITION with only ShareUpdateExclusiveLock. 2019-03-07 11:13:12 -05:00
po Translation updates 2018-06-25 12:37:18 +02:00
port Add shared_memory_type GUC. 2019-02-03 12:47:26 +01:00
postmaster Don't log incomplete startup packet if it's empty 2019-03-06 15:36:41 -05:00
regex Update copyright for 2019 2019-01-02 12:44:25 -05:00
replication Use a virtual rather than a heap slot in two places where that suffices. 2019-03-01 17:26:43 -08:00
rewrite tableam: introduce table AM infrastructure. 2019-03-06 09:54:38 -08:00
snowball Update copyright for 2019 2019-01-02 12:44:25 -05:00
statistics Rename nodes/relation.h to nodes/pathnodes.h. 2019-01-29 16:49:25 -05:00
storage Drop the vestigial "smgr" type. 2019-03-07 15:44:04 +13:00
tcop More unconstify use 2019-02-13 11:50:16 +01:00
tsearch Update copyright for 2019 2019-01-02 12:44:25 -05:00
utils Fix minor deficiencies in XMLTABLE, xpath(), xmlexists() 2019-03-07 18:16:34 -03:00
.gitignore Add .gitignore entries for AIX-specific intermediate build artifacts. 2015-07-08 20:44:22 -04:00
Makefile Ensure link commands list *.o files before LDFLAGS. 2019-01-02 13:57:54 -05:00
common.mk Remove PARTIAL_LINKING build mode. 2018-03-30 17:33:04 -07:00
nls.mk Translation updates 2018-06-25 12:37:18 +02:00