ps: Sorry for the multiple posts before. The anti-spam feature is confusing.
Thanks for the info; the feedback page has been fixed again.
The "QueryExample" app contains the following statement:
String query = "for $x in doc('etc/xml/input.xml')//li return $x";
What is the semantics of that? Does it mean that the (potentially huge) file `input.xml' will be converted into a binary database every time that statement is executed?
The XQuery specification doesn't contain information on how to interact with databases. This is why every DBMS pursues its own strategy. BaseX offers numerous approaches as well; the easiest thing to do is to explicitly create a single database for the document in question:
new CreateDB("input", "etc/xml/input.xml").execute(context);
Next, you can use the doc("...") or basex:db("...") functions to access the database:
new XQuery("for $d in doc('input') ...").execute(context);
Hth, Christian