I tried to reproduce this with 4.1-3 (linux x86-64) and didn't see a
problem. Here's my test case:
xquery version "1.0-ml";
xdmp:document-insert(
'/data/store/items/test',
<root>
<item type="title">Radiology & Ultrasound</item>
</root>
)
=> ()
xquery version "1.0-ml";
xdmp:directory('/data/store/items/', 'infinity')
//it...@type='title'][. = 'Radiology & Ultrasound']
=>
<item type="title">Radiology & Ultrasound</item>
That's exactly what I'd expect to see. So I don't think the problem is
due to ampersand handling in the broadest sense, but there might be
something narrower going on. Perhaps you can try this test case
yourself, and narrow down on the difference between it and what you have
observed?
-- Mike
On 2009-12-04 00:41, Baranov, Ivan - Moscow wrote:
Hi All,
I’ve encountered a problem while moving from 3.2 to 4.1. It seems like XQuery
dialect 1.0-ml is handling ampersand slightly different from 0.9-ml.
Suppose I have the file:
<root>
<item type=”title”>Radiology& Ultrasound</item>
</root>
Located in /data/store/items/
I am writing a simple query just to illustrate the problem:
xdmp:directory(“/data/store/items/”, “infinity”)//it...@type=’title’][. =
‘Radiology& Ultrasound’]
Under 3.2 it returns me the<item> node. Great! But under 4.1 I just get the empty
sequence (replacing& with& gives no effect). So could anyone please suggest
another idea of matching ampersand-containing strings in 4.1 environment?
Thanks in advance,
Van
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general