dom:domains() as element(dom:domain)*
Return all the domains.
xquery version "1.0-ml"; import module namespace dom = "http://marklogic.com/cpf/domains" at "/MarkLogic/cpf/domains.xqy"; for $domain in dom:domains() return $domain/dom:domain-name