Hello All,
I'm new to MarkLogic and I have a question about updating a document node.  
Here's my problem:
I'm going through the nodes in my document to find a specific node.  Here's 
what my XPath looks like: 
   //dict/dict[preceding-sibling::key[1] = 
"Tracks"]/dict/string[preceding-sibling::key[1]]
My XML is like:
...
<dict>
...
   <key>Tracks</key>
       <dict>
      < key>Track ID</key>
      <integer>867</integer>
      <key>Name</key>
      <string>Air</string>
...
   </dict>
That should return a node that looks like:
<string>Air</String>
So it's technically returning an element node--I've also tried xdmp:node-kind 
and that gives me "element."

But when I try to update, I get this error:
[1.0-ml] XDMP-ARGTYPE: (err:XPTY0004) 
xdmp:node-replace(xs:untypedAtomic("Air"), <string>Air2</string>) -- arg1 is 
not of type node()
It seems like instead of getting back:
<string>Air</string>
I'm actually just getting: 
Air
Which I can't use to update the node since it isn't a node. 
Can anyone point me in the right direction?
Thanks!
Erin
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to