Thanks Steven and Stavros Steven, I should have said that the result xml I showed, is after a XMLDBException which occurs on the call to XUpdateQueryService.updateResource(String key, String document). The error persists after upgrading to xerces-2.2.1.jar. I think that to know more I need to find the source of that class in xmldb-api.jar. How can I get it or a more recent version?
Stavros, I did have trouble understanding the syntax of the xupdate:modifications. It took the XMLDBGUI and many readings of http://xmldb.org/xupdate/xupdate-wd.html The xupdate:modifications part of the query below does work in xmldbgui. Also Instructions for using xmldbgui with xindice1.1 are here http://titanium.dstc.edu.au/viewcvs/viewcvs.cgi/*checkout*/XMLdbGUI/docs/How To_Configure_XMLdbGUI_Lite.html?rev=1.1 but these may be more help http://marc.theaimsgroup.com/?l=xindice-users&m=103615588828273&w=2 (follow the thread) Don ----- Original Message ----- From: "Stavros Kounis" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Monday, April 14, 2003 1:06 PM Subject: RE: xupdate update in cocoon > > i have try to use XUpdate using all the GUI client they are in xindice web > site with out success and without any error message > > a messege in this list is talking about a bug in xindice > but i dont know more details > > if anyone run succesfull a XUpdate guery please post an example in this > list > > > ---stavros > > > On Mon, 14 Apr 2003, Steven Cummings wrote: > > > Don, > > > > What is it exactly that doesn't work? I'm using Xindice and Cocoon together on Tomcat (4.1) and jdk14 and what I've discovered is that you need to use the Xerces jar from Xindice (2.2.1 I think) in both Cocoon, and Tomcat underneath (meaning put it in $TOMCAT_HOME/common/endorsed). All of this is assuming that you're problem is a Java exception being thrown when you try to execute the update statements. > > > > Sorry if this wasn't what you were looking for. > > > > /S > > > > Don Saxton <[EMAIL PROTECTED]> wrote: > > > > >Hi > > > > > >I have a good start in putting xindice 1.1b together with cocoon 2.04 (jdk > > >1.4 tomcat 4.1.18), but I am really stuggling with Xupdate. > > > > > >I got this far by using the experiences of several people on this list. > > >Thank you greatly. Frequently I read that others get xupdate to work, so I > > >am hoping that someone can help me over the last hurdle. > > > > > >Below are xupdate query that I input to the cocoon transformer > > >XMLDBTransformer and the result. > > >With xmldbgui I can successfully xupdate with the modifications node set of > > >the update query below. > > > > > >The query side works well and I am able to snag a fragment from a document > > >or a document from a collection. I can do it through cocoon, xmldbgui, > > >xincon, and almost with "the ugly debug tool" (can't glue the xpath query > > >onto the http collection request, but it's still a keeper). > > > > > >One suspect is xmldb-api-20021118.jar. I could not find > > >xmldb-api-20021126.jar or how to get to xmldb cvs. My other suspect is > > >XMLDBTransformer which seems to require an oid attribute eventhough a query > > >of type="update" is documented as not needed. It doesn't seem to matter what > > >the value of oid is. Related to these is that I can't find documented (well, > > >meaningfully documented) the difference between these two: > > > > > >XUpdateQueryService.update(String document) > > >XUpdateQueryService.updateResource(String key, String document) > > > > > >Thanks for everything > > > > > >Don > > > > > ><!-- _________the query_________ --> > > ><?xml version="1.0" encoding="UTF-8"?> > > ><xindice:query xmlns:xupdate="http://www.xmldb.org/xupdate" > > > xmlns:xindice="http://apache.org/cocoon/xmldb/1.0" > > > type="update" oid="whatever"> > > > <xupdate:modifications version="1.0"> > > > <xupdate:remove select="//[EMAIL PROTECTED]'p1']"/> > > > <xupdate:append select="//persons"> > > > <xupdate:element name="person"> > > > <xupdate:attribute name="id">p1</xupdate:attribute> > > > <xupdate:attribute name="name">Don</xupdate:attribute> > > > <parents > > > xmlns:chiba="http://chiba.sourceforge.net/2001/09/xforms" > > > xmlns:xforms="http://www.w3.org/2002/08/xforms/cr" > > > xmlns:xlink="http://www.w3.org/1999/xlink" > > > xmlns:collection="http://apache.org/cocoon/xmldb/1.0" > > > xmlns:src="http://xml.apache.org/xindice/Query"> > > > <personref person="p2"/> > > > <personref person="p7"/> > > > </parents> > > > </xupdate:element> > > > </xupdate:append> > > > </xupdate:modifications> > > ></xindice:query> > > ><!-- _________end query_________ --> > > > > > ><!-- _________the result_________ --> > > ><?xml version="1.0" encoding="UTF-8"?> > > ><xindice:query oid="whatever" type="update" result="failure" > > > xmlns:xupdate="http://www.xmldb.org/xupdate" > > > xmlns:xindice="http://apache.org/cocoon/xmldb/1.0"> > > > Failed to update resource whatever: 1 > > ></xindice:query> > > ><!-- _________end result_________ --> > > > > > > > > > > > > > >
