I got nothing or "Error XQDY0025" when I use a xQuery, which is as below, but the eXide shows "Found 4 in 0.004s", please help me, can't find the problem.
for $s in doc("customers.xml")/customers/Customer
return $s/@Name
to query the "Name" attributes in the below xml document
<customers>
<Customer Name="c2">
<Order OrderNumber="o1">
<Item Description="ab">
i1
</Item>
</Order>
</Customer>
<Customer Name="c3">
<Order OrderNumber="o2">
<Item Description="cd">
i2
</Item>
<Item Description="ef">
i3
</Item>
</Order>
<Order OrderNumber="o2">
<Item Description="cfg">
i5
</Item>
</Order>
</Customer>
<Customer Name="c1">
<Order OrderNumber="o1">
<Item Description="abc">
i1
</Item>
<Item Description="def">
i2
</Item>
</Order>
</Customer>
<Customer Name="c4">
<Order OrderNumber="o1">
<Item Description="abc">
i1
</Item>
</Order>
<Order OrderNumber="o2">
<Item Description="def">
i2
</Item>
</Order>
</Customer>
No comments:
Post a Comment