[basex-talk] Refer to a specific document in a BaseX DB using XQuery

cosmotron+basex at gmail.com cosmotron+basex at gmail.com
Thu Jul 29 16:29:40 CEST 2010


If I add two documents to a BaseX DB, let's say normal.xml and normal2.xml, is there a way to refer to each one individually?

I know about the doc() function, but it looks at the filesystem for their location, rather than in the database itself.

For instance, if I query with this: doc("normal.xml")/name , then I will get an error about normal.xml not being found.

I also tried: basex:db("my-db-name")/doc("normal.xml")/name and received the same error.

Thanks for any help!




More information about the BaseX-Talk mailing list