Hi all, we are rather interested in experimenting with the new facility provided with the latest snapshot mixupdates. I have a question related to the scope of the mixupdates option. For us (using the GUI) neither declaring the option at module level with
declare option db:mixupdates 'true';
nor inlining it with a pragma as in
declare function local:sample() { (# db:mixupdates 'true' #){ let $d := <a><b></b></a> return (replace node $d/b with <d/>, "Success") } };
prevent the compiler from complaining with: "... all expressions must be updating or return an empty sequence".
Instead it works neatly when the option is set in the .basex file. Is setting the option globally for the whole basex instance the only way to enable the compiler for mixed updates? Regards, Marco.
Hi Marco,
the MIXUPDATES option must indeed be specified globally (in .basex or in the web.xml file), because it's too influential in order to get effective within the query. We even think about making it the default option in BaseX, but we'll first need to gain more experience.
Hope this helps, Christian
On Wed, May 14, 2014 at 10:23 AM, Marco Lettere marco.lettere@dedalus.eu wrote:
Hi all, we are rather interested in experimenting with the new facility provided with the latest snapshot mixupdates. I have a question related to the scope of the mixupdates option. For us (using the GUI) neither declaring the option at module level with
declare option db:mixupdates 'true';
nor inlining it with a pragma as in
declare function local:sample() { (# db:mixupdates 'true' #){ let $d := <a><b></b></a> return (replace node $d/b with <d/>, "Success") } };
prevent the compiler from complaining with: "... all expressions must be updating or return an empty sequence".
Instead it works neatly when the option is set in the .basex file. Is setting the option globally for the whole basex instance the only way to enable the compiler for mixed updates? Regards, Marco.
basex-talk@mailman.uni-konstanz.de