Hi,
I would like to make successive updates on a database using RESTXQ. For example : db:create(...) then db:add(...) on the newly created database.
But, it seems impossible to do it in the same query because of the order in which the functions are processed.
Is there a workaround for that without asking the user to send two requests manually ? For example, if there could be a way to redirect to a new query or Restxq, or something like that.
Thanks ! Best regards,
Hi Tojo,
I would like to make successive updates on a database using RESTXQ. For example : db:create(...) then db:add(...) on the newly created database.
But, it seems impossible to do it in the same query because of the order in which the functions are processed.
True, that’s not possible. With RESTXQ, the usual way is to use the forward and redirect features [1]. If you write scripts, the command script syntax will allow you to perform sequential update operations on a database [2]. If you only use, db:create and db:abb, the third alternative is to pass on initial input to the create function [3] (but you probably have seen that anyway).
[1] http://docs.basex.org/wiki/RESTXQ#Forwards_and_Redirects [2] http://docs.basex.org/wiki/Commands#Command_Scripts [3] http://docs.basex.org/wiki/Database_Module#db:create
On Thu, Dec 19, 2013 at 4:02 PM, Tojo Rakotoarison tojo.urs@gmail.com wrote:
Hi,
Is there a workaround for that without asking the user to send two requests manually ? For example, if there could be a way to redirect to a new query or Restxq, or something like that.
Thanks ! Best regards,
BaseX-Talk mailing list BaseX-Talk@mailman.uni-konstanz.de https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk
basex-talk@mailman.uni-konstanz.de