Using the basex Zip distribution for both 8.0.3 and 8.1, I'm getting a failure on REPLACE but not ADD for the same XML data.
This command succeeds:
basexclient -c "CHECK dfst_dfst-sample-project_master; OPEN dfst_dfst-sample-project_master; ADD to dfst/metadata.xml <dfst_metadata/>"
But this command fails
basexclient -c "CHECK dfst_dfst-sample-project_master; OPEN dfst_dfst-sample-project_master; REPLACE dfst/metadata.xml <dfst_metadata/>"
"..." (Line 1): Premature end of file.
This definitely worked in the past, so something must have changed on my system.
Obviously, the error message is not very helpful in this case.
Any idea what the problem might be or how I would diagnose this failure?
Thanks,
E.
————— Eliot Kimber, Owner Contrext, LLC http://contrext.com
Hi Eliot,
basexclient -c "CHECK dfst_dfst-sample-project_master; OPEN dfst_dfst-sample-project_master; REPLACE dfst/metadata.xml <dfst_metadata/>"
I just tried this with BaseX 8.0, 8.1 and the latest snapshot; it worked on my machine. Maybe it's due to some configuration details? Does it also happen with a fresh instance of basex80.zip?
By the way, if you use CHECK, there is no need to call OPEN afterwards. This works as well:
basexclient -Uadmin -Padmin -c "check x; replace a.xml <a/>"
Christian
basex-talk@mailman.uni-konstanz.de