How to save changes to input document?
I am tryinig to use a cache while generating RSS feed for a collection in eXist database. So I need to read content from a document, makes some changes and write back to the cache.
I have following code:
let $test := doc("/db/test/test.xml")/items/item
let $开发者_如何学PythontestSet := <items>{$test}</items>
let $write := xmldb:store("/db/test", "test.xml", $testSet)
return $test
But it seems writing back to the document(line 3) screws up the content of $test(line 1).
Any help is appreciated.Thank you very much!
I see you've asked this same question on the exist-open list, and I think Wolfgang already gotten it answered there. See http://exist-open.markmail.org/thread/g4dnipbcngimrqma.
精彩评论