Commit 89a5b96e authored by msvensson@neptunus.(none)'s avatar msvensson@neptunus.(none)

Merge bk-internal:/home/bk/mysql-5.1-new

into  neptunus.(none):/home/msvensson/mysql/mysql-5.1
parents 414242b3 235c5d35
......@@ -546,7 +546,7 @@ select extractvalue('<a>a<b>B</b></a>','a|/b');
extractvalue('<a>a<b>B</b></a>','a|/b')
a
select extractvalue('<a>A</a>','/<a>');
ERROR HY000: XPATH syntax error: '>'
ERROR HY000: XPATH syntax error: '<a>'
select extractvalue('<a><b>b</b><b!>b!</b!></a>','//b!');
ERROR HY000: XPATH syntax error: '!'
select extractvalue('<a>A<b>B<c>C</c></b></a>','/a/descendant::*');
......@@ -613,3 +613,5 @@ select extractValue('<e>1</e>','position()');
ERROR HY000: XPATH syntax error: ''
select extractValue('<e>1</e>','last()');
ERROR HY000: XPATH syntax error: ''
select extractValue('<e><a>1</a></e>','/e/');
ERROR HY000: XPATH syntax error: ''
......@@ -286,3 +286,12 @@ select extractvalue('<a>Jack</a>' collate latin1_bin,'/a[contains(../a,"j")]');
select extractValue('<e>1</e>','position()');
--error 1105
select extractValue('<e>1</e>','last()');
#
# Bug #18172 XML: Extractvalue() accepts mallformed
# XPath without a XPath syntax error
#
--error 1105
select extractValue('<e><a>1</a></e>','/e/');
This diff is collapsed.
......@@ -1561,10 +1561,8 @@ static int my_xpath_parse_AbsoluteLocationPath(MY_XPATH *xpath)
return my_xpath_parse_RelativeLocationPath(xpath);
}
if (my_xpath_parse_RelativeLocationPath(xpath))
return 1;
return 1;
return my_xpath_parse_term(xpath, MY_XPATH_LEX_EOF) ||
my_xpath_parse_RelativeLocationPath(xpath);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment