==XQuery==
The {{Function|Database|db:add}} and {{Function|Database|db:updateput}} functions can also be used to add new XML documents to the database. The following example query uses the internal XML parser and adds all files to the database <code>DB</code> that are found in the directory <code>2Bimported</code>:
<syntaxhighlight lang="xquery">