|- valign="top"
| '''Examples'''
| Return the contents of large {{Code|.txt}} files located in a specific directory:
<syntaxhighlight lang="xquery">
for $file in file:children('path/to/files/')
|- valign="top"
| '''Examples'''
| Return the contents of all {{Code|.txt}} files located in a specific directory and its subdirectories:
<syntaxhighlight lang="xquery">
for $file in file:descendants('path/to/files/')