You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Christian Zoffoli <cz...@littlepenguin.org> on 2002/02/28 04:53:25 UTC
XMLDBTransformer -- UPDATE
I'm very happy to see a XMLDBTrasformer in the scratchpad of Cocoon2!!!
... but I have some problems with the update ...it doesn't seem to work
...is it possible or it's my fault ?
the result of a simple query [ xindice xpath_query -c /db/beta -q / ]
---------------------
<?xml version="1.0"?>
<users xmlns:src="http://xml.apache.org/xindice/Query"
src:col="/db/beta" src:key="users">
<user id="1">
<name>Christian</name>
<surname>Zoffoli</surname>
<email />
<address />
<login>czoffoli</login>
<password>chr!s</password>
</user>
<user id="2">
<name>Pippo</name>
<surname>Pluto</surname>
<email />
<address />
<login>pippo</login>
<password>p!ppo</password>
</user>
</users>
---------------------
the xupdate query
---------------------
<?xml version="1.0"?>
<page xmlns:xindice="http://apache.org/cocoon/xmldb/1.0">
<xindice:query type="update" oid="users">
<xu:modifications version="1.0"
xmlns:xu="http://www.xmldb.org/xupdate">
<xu:update select="/users/user[@id =
'2']/surname">paperino</xu:update>
</xu:modifications>
</xindice:query>
</page>
---------------------
the result
----------------
<?xml version="1.0" encoding="UTF-8"?>
<page xmlns:xindice="http://apache.org/cocoon/xmldb/1.0">
<xindice:query oid="users" type="update" result="failure">Failed to
update resource users: 1</xindice:query>
</page>
----------------
Thanks, Christian
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org
Re: XMLDBTransformer -- UPDATE
Posted by Stephan Michels <st...@vern.chem.tu-berlin.de>.
On Thu, 28 Feb 2002, Christian Zoffoli wrote:
> I'm very happy to see a XMLDBTrasformer in the scratchpad of Cocoon2!!!
>
> ... but I have some problems with the update ...it doesn't seem to work
> ...is it possible or it's my fault ?
>
> ---------------------
>
> the xupdate query
> ---------------------
> <?xml version="1.0"?>
>
> <page xmlns:xindice="http://apache.org/cocoon/xmldb/1.0">
>
> <xindice:query type="update" oid="users">
> <xu:modifications version="1.0"
> xmlns:xu="http://www.xmldb.org/xupdate">
> <xu:update select="/users/user[@id =
> '2']/surname">paperino</xu:update>
> </xu:modifications>
> </xindice:query>
>
> </page>
>
> ---------------------
>
> the result
> ----------------
> <?xml version="1.0" encoding="UTF-8"?>
> <page xmlns:xindice="http://apache.org/cocoon/xmldb/1.0">
>
> <xindice:query oid="users" type="update" result="failure">Failed to
> update resource users: 1</xindice:query>
>
> </page>
Yes ;-) I'm not the only one with this problem. Since two days I got
headaches more and more.
The problem is that this message isn't very useful.
In the cmdline everything works, and with xupdate :-|
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org