an XQuery recipe: generating lots of documents in a single XQuery run …

… by putting them in a single large XML object – then use a post-processor to split this into separate files. (Alright this isn’t really a true “single XQuery run” approach. But it is close enough.)

With Saxon-HE there is no way to write to separate text files from within a true single XQuery run, but using xmlstarlet (or whatever) the mentioned post-processor is rather easy to implement:


Comments

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.