Monday, 11 April 2011

MarkLogic: Performing an operation across two databases using xdmp:eval

There could be situations where you want to perform operations across two databases. One such example could be to quickly clone a batch of documents into a second database.

This can be achieved using xdmp:eval.

In this example, if you have several documents in a database called "DatabaseA" (and in CQ this is selected as your Content Source). An xdmp:eval statement could be used to write those documents into DatabaseB like so:

No comments: