I've used BaseX to create a database of the XML Schema Test Suite, by specifying (in the GUI) the test suite's root directory and a filter of *.xml. (Well, to be completely explicit it's the root directory of a mirror in which each file is a symbolic link to the real test suite directories; this allows me to exclude ill-formed input and rename all XSD files as .xsd.xml.) But I find that when I retrieve an element $e and ask what document it was in, using document-uri($e), I do not get the expected result: I get the file name of the document, but I do not get the path to the document, only the path to the database root. For example: the BaseX database I'm working with was created by indexing directory /home/xmlschema/mirror-11. And for a query result element $a found in document /home/xmlschema/mirror-11/msData/additional/test73850.xml the expression document-uri($a/root()) returns /home/xmlschema/mirror-11/test73850.xsd.xml instead of the expected /home/xmlschema/mirror-11/msData/additional/test73850.xml (Side note: I do realize that the 'root()' in '$a/root()' is irrelevant; it's there to work around a bug in another XQuery processor, which shall remain nameless, which otherwise returns the empty sequence. Yes, it's true: I am seeing other XQuery engines as well as BaseX. I blush to admit it, because it makes me seem kind of promiscuous, but it's true.) Is this a bug? Did I do something wrong / set some parameter wrong when creating the database?) Is there a workaround? If it matters, I'm running BaseX 5.7 (cannot move to BaseX 6 at the moment because no Java 6 is available for my current hardware and software). -- **************************************************************** * C. M. Sperberg-McQueen, Black Mesa Technologies LLC * http://www.blackmesatech.com * http://cmsmcq.com/mib * http://balisage.net ****************************************************************