Thank you for your reply. I don't understand why import-all.xq would throw this warning and import-and-process.xq would not. In the case of the latter, the nodes imported with that call are in fact updated properly, while in the former, no updates are seen.
To be sure: You mean that…
• import-all.xq throws the warning, but peforms no updates, and • import-and-process.xq doesn’t raise a warning, but works as expected?
So there may be two questions to solve?
In order to reproduce this behavior, you might need to provide me with 1, 2 files that you are trying to import.
Can you tell me why -u would change the behavior of the one and not the other, or in other words, what is different about the two queries that makes this distinction important?
The -u argument should actually work consistently for all files.
-----Original Message----- From: Christian Grün christian.gruen@gmail.com Sent: Wednesday, May 22, 2019 14:07 PM To: Joshua Kordani joshua.kordani@speedcastwireless.com Cc: BaseX basex-talk@mailman.uni-konstanz.de Subject: Re: [basex-talk] Attempting to write bulk import of files is failing
Hi Joshua,
I write the function in lib.xqm as a standalone query. All it does it add some attributes to each testcase before importing the content into the database. Forgive me if this is hard to read, it was my first attempt at making a function which updates some records and then imports in the same query.
Looks fine. Thanks for sending code that can be parsed out-of-the-box.
I am now trying to write a bulk import, which is import-all.xq and this is not working. I receive a message about updates not being written back. My first attempt to write that function inside of a for-each also failed.
This warning is only shown on command line. It simply indicates that your updates won’t be propagated back to the original files.
If that’s what you would like to achieve, you can use the command-line argument -u (see [1]). If something else is not working as expected, feel free to provide us with more details.
Best, Christian
[1] http://docs.basex.org/wiki/Options#WRITEBACK
DISCLAIMER: This email communication and any attached files are Speedcast Wireless proprietary and may be legally privileged. Export-controlled information shall not be disseminated without proper authorization and proper export-control markings, per Speedcast Wireless export policy. If you have received this transmission in error please notify the sender immediately and then delete this email and all its attachments. If you are not the addressee, any disclosure, reproduction, copying, distribution, or any other dissemination or use of this communication is strictly prohibited. Thank you.