Thanks Akihiro.

I tried replacing Xindice's xerces jar with version 1.4.4 and then 2.1.1, but it still doesn't work. Any other ideas?

Thanks,
Tom


At 09:10 PM 12/10/2002 +0900, you wrote:

Hello, Tom. I once had a problem like you under tomcat-3.3, jdk1.4.

Xindice 1.0 has xerces-1.4.3.jar in its java/lib directory.
I replaced the jar file with xerces-1.4.4, and the error was gone.
Maybe the version 1.4.3 not fit to use XUpdate.


Thanks, Akihiro


Hi,

I'm using Xindice 1.0 and have just started playing around with XUpdateQueryService but am having a few problems. If I try to perform an XUpdate query that does not match anything in the collection then nothing happens (as expected), but if I change it so that it does match something, then an exception is thrown and the update fails.

For example, if I use the perform the following XUpdate query:

String update =
"<xu:modifications version=\"1.0\" xmlns:xu=\"http://www.xmldb.org/xupdate\";>\n" +
"<xu:update select=\"/addresses/address[1]/town\"> \n" +
"Bristol\n" +
"</xu:update>\n" +
"</xu:modifications>";


On a collection that contains the following data:

<addresses xmlns:src="http://xml.apache.org/xindice/Query"; src:col="/db/test" src:key="doc3">
<address>
<town>Los Angeles</town>
</address>
<address>
<town>New York</town>
</address>
</addresses>


Then the following exceptions are thrown:

org.apache.xindice.client.corba.db.APIException: IDL:org/apache/xindice/client/corba/db/APIException:1.0
at org.apache.xindice.client.corba.db.APIExceptionHelper.read(APIExceptionHelper.java:112)
at org.apache.xindice.client.corba.db._CollectionStub.queryCollection(_CollectionStub.java:833)
at org.apache.xindice.client.xmldb.services.XUpdateQueryServiceImpl.updateResult(XUpdateQueryServiceImpl.java:165)
at org.apache.xindice.client.xmldb.services.XUpdateQueryServiceImpl.update(XUpdateQueryServiceImpl.java:185)


org.xmldb.api.base.XMLDBException: Query Processing Error

However, if I change the select attribute to "/addresses/address[3]/town" there are no exceptions.

Does anyone have any idea what I'm doing wrong?

Thanks a lot,
Tom



Reply via email to