summaryrefslogtreecommitdiff
path: root/mysql-test/r/xml.result
diff options
context:
space:
mode:
authorunknown <bar@mysql.com>2006-02-10 13:24:10 +0400
committerunknown <bar@mysql.com>2006-02-10 13:24:10 +0400
commitc736708725e897af315eb566454644da246b0e05 (patch)
tree744505de8dac77231d37560311a9b28c7e2b2bb5 /mysql-test/r/xml.result
parent094fcd2611b3a171a64b5d20a4b851cdba2c55e7 (diff)
downloadmariadb-git-c736708725e897af315eb566454644da246b0e05.tar.gz
Bug#16234 XML: Crash if ExtractValue()
Also fixes 16314: XML: extractvalue() crash if vertical bar xml.result, xml.test: Adding test case item_xmlfunc.cc: Using root element as a context node, instead of NULL, with relative paths. sql/item_xmlfunc.cc: Bug#16234 XML: Crash if ExtractValue() Also fixes 16314: XML: extractvalue() crash if vertical bar Use root element as a context node, instead of NULL, with relative paths. mysql-test/t/xml.test: Adding test case mysql-test/r/xml.result: Adding test case
Diffstat (limited to 'mysql-test/r/xml.result')
-rw-r--r--mysql-test/r/xml.result22
1 files changed, 22 insertions, 0 deletions
diff --git a/mysql-test/r/xml.result b/mysql-test/r/xml.result
index 693dd6eea81..4d66e034964 100644
--- a/mysql-test/r/xml.result
+++ b/mysql-test/r/xml.result
@@ -520,3 +520,25 @@ UpdateXML(@xml, '/a/b/@bb2', '')
select UpdateXML(@xml, '/a/b/@bb2', 'bb3="bb3"');
UpdateXML(@xml, '/a/b/@bb2', 'bb3="bb3"')
<a aa1="aa1" aa2="aa2"><b bb1="bb1" bb3="bb3">bb</b></a>
+SET @xml= '<order><clerk>lesser wombat</clerk></order>';
+select extractvalue(@xml,'order/clerk');
+extractvalue(@xml,'order/clerk')
+lesser wombat
+select extractvalue(@xml,'/order/clerk');
+extractvalue(@xml,'/order/clerk')
+lesser wombat
+select extractvalue('<a><b>B</b></a>','/a|/b');
+extractvalue('<a><b>B</b></a>','/a|/b')
+
+select extractvalue('<a><b>B</b></a>','/a|b');
+extractvalue('<a><b>B</b></a>','/a|b')
+
+select extractvalue('<a>a<b>B</b></a>','/a|/b');
+extractvalue('<a>a<b>B</b></a>','/a|/b')
+a
+select extractvalue('<a>a<b>B</b></a>','/a|b');
+extractvalue('<a>a<b>B</b></a>','/a|b')
+a
+select extractvalue('<a>a<b>B</b></a>','a|/b');
+extractvalue('<a>a<b>B</b></a>','a|/b')
+a