I have come across a problem. I want to check here whether the given xml 
contains any kind of text. I don't want any output if any of the children 
doesn't have any text. Like in the example given, it should not give me 
anything.
let $x :=
<head xmlns="http://www.w3.org/1999/xhtml";>
    <script type="text/javascript"></script>
    <title></title>
</head>
(1) $x/text() will yield nothing. But if I change Hi David, then also it is 
returning nothing since text() works on the self-node. That's fine.
(2) $x/string() will yield something but dont know what? I was expecting it 
should not give me anything in the example mentioned. Can you please help?
(3) $x/data gives "XDMP-NONMIXEDCOMPLEXCONT: Node has complex type with 
non-mixed complex content." since the head node is under some namespace 
{WHY??}. Removing the namespace solves this error but behaving same like string.

Thanks & Regards,
Rahul
_______________________________________________
General mailing list
[email protected]
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to