Hello,

> But you certainly have something different in your database / with your 
> environment, because clean deployment worked ok for me. If you want you 
> can (re)send me your java code and I can try running this too.

I use the following method to delete a collection from Xindice:

private boolean executeDropCollection(URI destination) throws Exception
{
        Collection collection = null;
        boolean success = false;
        try
        {
                Class c = Class.forName(dbDriver);
                Database database = (Database)c.newInstance();
                DatabaseManager.registerDatabase(database);

                // Destination is: "xmldb:xindice://localhost:8080/db/mdbm"
                collection = 
DatabaseManager.getCollection(getDestinationPath(destination)
);
                // the collection path is: 
                // "xmldb:xindice://localhost:8080/db/"
                org.apache.xindice.client.xmldb.services.CollectionManager 
service =
(org.apache.xindice.client.xmldb.services.CollectionManager)collection.getService("CollectionManager",
"1.0");
                // the collection name is: "mdbm"
                service.dropCollection(getDestinationName(destination) );
                success = true;
        }
        catch (Exception exception) {printException(exception, ERRORFILE); }
        finally {if (collection != null) collection.close(); }
        return success;
}

I am using JDK 1.4.2 and Tomcat 5.0.19 on Windows98.

Thanks in advance,

     Lars

-- 
NEU : GMX Internet.FreeDSL
Ab sofort DSL-Tarif ohne Grundgeb�hr: http://www.gmx.net/dsl

Reply via email to