-
+
Functions and Operators
mappings. This array should be a two-dimensional array with the
length of the second axis being equal to 2 (i.e., it should be an
array of arrays, each of which consists of exactly 2 elements).
- The first element of each array entry is the namespace name, the
- second the namespace URI.
+ The first element of each array entry is the namespace name (alias), the
+ second the namespace URI. It is not required that aliases provided in
+ this array are the same that those being used in the XML document itself (in
+ other words, both in the XML document and in the xpath
+ function context, aliases are local>).
--------
{test}
(1 row)
+]]>
+
+
+ How to deal with default (anonymous) namespaces:
+
+SELECT xpath('//mydefns:b/text()', '
test',
+ ARRAY[ARRAY['mydefns', 'http://example.com']]);
+
+ xpath
+--------
+ {test}
+(1 row)
]]>