Hello all,
I wonder whether someone could help me with what I'm sure is just some newbie error on my part.
I'm running an XQuery Update using BaseX from the command line over an XML document, and I want the XML declaration to be preserved. My input is:
basex -uVwsomit-xml-declaration=no <input xQuery Update file>
That looks correct to me per the documentation, but when I run it, I lose the XML declaration nevertheless. (The xQuery Update executes correctly.) I've tried the following, all to no avail:
--split out the -s flag, putting it as the first and last flag, respectively --setting the value to "yes" (well, I knew that wasn't going to work, but I had to check, right?) --upper case NO (ditto...) --adding the following two lines to my xQuery file: declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization"; declare option output:omit-xml-declaration "no";
I know this question has come up before, but I couldn't find an approach that worked for me in the list archives. Obviously, at this point I'm just throwing darts at the problem. I'd be grateful for any pointers!
Sincerely,
Regine Heberlein Principal Cataloger and Metadata Analyst, Rare Book Collections Princeton University Library One Washington Road Princeton, NJ 08540 609-258-6156