zadean / xqerl

Erlang XQuery 3.1 Processor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

XQuery function fn:uri-collection()

grantmacken opened this issue · comments

https://www.w3.org/TR/xpath-functions-31/#fns-on-docs

At the moment calling fn:uri-collection() with empty arg is returning an error if no arg is supplied.

If $arg is not specified, the function returns the sequence of items in the default collection in the dynamic context.

Since the XQerl app server can store collections of XDM items and links in multiple databases
and these databases are defined by a base URI consisting of schema + authority
then then I think fn:uri-collection() could return a list of xqerl app server database URI.
As far as I can see there is no way to inspect what databases the xqerl app server holds,
so calling fn:uri-collection() with empty arg that returns xqerl app server database URI would be very handy.

So, just for my understanding, the default should be root or all?

Or just all DB base URIs?

I never settled on what it should do, so some well defined method would be great! 😄

I think it could return just the base uri of databases rather than the uri of all hierarchical collection items in all databases.