1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

Bug#18170: XML: ExtractValue(): XPath expression can't use QNames (colon in names)

Problem source:
Qualified names (aka QName) didn't work as tag names and attribute names,
because the parser lacked a real rule to scan QName, so it understood
only non-qualified names without prefixes.

Solution:
New rule was added to check both "ident" and "ident:ident" sequences.


mysql-test/r/xml.result:
  Adding test case
mysql-test/t/xml.test:
  Adding test case
sql/item_xmlfunc.cc:
  Adding real QName parser rule and using it in NodeTest rule.
This commit is contained in:
unknown
2006-04-17 11:49:20 +05:00
parent 3ef014862b
commit 1a3cb50c24
3 changed files with 42 additions and 1 deletions

View File

@@ -321,3 +321,11 @@ END//
DELIMITER ;//
CALL p2();
DROP PROCEDURE p2;
#
# Bug#18170: XML: ExtractValue():
# XPath expression can't use QNames (colon in names)
#
select extractValue('<ns:element xmlns:ns="myns"/>','count(ns:element)');
select extractValue('<ns:element xmlns:ns="myns">a</ns:element>','/ns:element');
select extractValue('<ns:element xmlns:ns="myns">a</ns:element>','/ns:element/@xmlns:ns');