fn:collection( [$uri as xs:string*] ) as document-node()*
Returns all of the documents that belong to the specified collection(s).
fn:collection("mycollection")[1] => returns the first document in the "mycollection" collection
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.