On 10/05/2026 00:52, Ben Engbers via BaseX-Talk wrote:
Hi,
While improving my C++ test application for the libBasexCpp library, I tried to execute this line: update insert <Line_1 line="1">Content 1</Line_1> into doc('/TestCppClient/Test.xml')/root
This resulted in a crash. And since I only know the basics from XQuery, I wanted to use the GUI for debugging this instruction. Even in the GUI this line could not be executed.
I consulted Mistral/leChat and it came to the conclusion that probably I haven't enabled the XQuery Update facility. But in the GUI I don't see how I could enable the update facility.
Reading https://docs.basex.org/main/Updates#original_files might help: In BaseX, all updates are performed on database nodes or in main memory. By default, update operations do not affect the original input file (the info string “Updates are not written back” is output to indicate this). The following solutions exist to write XML documents and binary resources to disk: * Updates on main-memory instances of files that have been retrieved via|fn:doc|or|fn:collection|will be propagated back to disk if|WRITEBACK <https://docs.basex.org/main/Options#writeback>|is turned on. This option can also be activated oncommand line <https://docs.basex.org/main/Command-Line_Options#standalone>via|-u|. Make sure you back up the original documents before running your queries. * Functions like|fn:put|or|file:write <https://docs.basex.org/main/File_Functions#file:write>|can be used to write single XML documents to disk. With|file:write-binary <https://docs.basex.org/main/File_Functions#file:write-binary>|, you can write binary resources.