Greetings!

What I thought would be a simple task has turned out to not be so simple.

I wrote:

SET CHOP false
SET EXPORTER indent=no,omit-xml-declaration=no
SET BINDINGS $ndb=Ruth
CREATE DB $ndb ./sources/Ruth.xml

In BaseX 9.6.4, and when testing it I got this result:

CHOP: false
EXPORTER: indent=no,omit-xml-declaration=no
BINDINGS: $ndb=Ruth
Database '$ndb' created in 544.5 ms.

What? Why isn't the mapping of Ruth to the variable $ndb effective in the bxs file?

Moreover, there are query files that follow in the bxs file that I want to have resolve $ndb to Ruth (the desired name of the database).

1) How should I declare a variable in a bxs file?

2) In such a way that it carries over to following xquery files?

BTW, I've seen this posting by Christian: https://stackoverflow.com/questions/28018354/how-to-run-a-xquery-with-xml-file-containing-value-as-one-of-the-bound-variabl

but it doesn't seem to be working for me.

What am I missing?

Thanks!

Patrick
<https://twitter.com/servicenow>--

Patrick Durusau
patr...@durusau.net
Technical Advisory Board, OASIS (TAB)
Editor, OpenDocument Format TC (OASIS), Project Editor ISO/IEC 26300
Co-Editor, ISO/IEC 13250-1, 13250-5 (Topic Maps)

Another Word For It (blog): http://tm.durusau.net
Homepage: http://www.durusau.net
Twitter: patrickDurusau

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

Reply via email to