I expect you'll get a few copies of this link: http://developer.marklogic.com/pubs/5.0/apidocs/Lexicons.html#cts:collections
> Returns values from the collection lexicon. This function requires the > collection-lexicon database configuration parameter to be enabled. If the > collection-lexicon database-configuration parameter is not enabled, an > exception is thrown. -- Mike On 30 Nov 2011, at 20:24 , John Zhong wrote: > Hi all, > > I want to know if there any apis to return all the collection names in a > database? I only can think out a stupid way: > > let $collections := for $doc in fn:doc() > return > xdmp:document-get-collections(fn:base-uri($doc)) > return fn:distinct-values($collections) > > Yes, I know those names are what I define before adding files into > collections, but I just want to know if there is a way to do that. > > Thank you, > John > _______________________________________________ > General mailing list > [email protected] > http://developer.marklogic.com/mailman/listinfo/general _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
