On 2007-09-24 19:03, Timothy Marc wrote:
Hello all,
I've downloaded MonetDB XQuery for evaluating the XQuery Update Facility. I've shredderd a document and can perform xqueries from MapiClient successfully. But, when i try to update a document, the process fails with error message: !ERROR updating read-only document.
May i have to specify some flags or something else???
Thx Timothy
------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
When you shred a document that you want to be able to update, you have to shred it with some slack space. This is done by giving a percentage as last extra argument to the pf:add-doc function. We typically use 10 for this: pf:add-doc("/path/to/file.xml", "cached-name.xml", "collection", 10) where "cached-name.xml" is the name under which the document is available from within XQuery (i.e. in a doc() function), "collection" is an optional parameter specifying the collection to which the document is added (defaults to the second parameter), and 10 is the percentage of free space. If that is 0 (the default), the document is read-only. -- Sjoerd Mullender