config = new HashMap<String, String>();
config.put(LayerNodeIndex.LAT_PROPERTY_KEY, "la");
config.put(LayerNodeIndex.LON_PROPERTY_KEY, "lo");
config.put(SpatialIndexProvider.GEOMETRY_TYPE, LayerNodeIndex.POINT_PARAMETER);
layerIndex = new LayerNodeIndex("layerIndex", graph, config);
layerIndex.delete()
SpatialDatabaseService s = new SpatialDatabaseService(graph);
Listener l = new Listener() {
@Override
public void begin(int i) {
}
@Override
public void worked(int i) {
}
@Override
public void done() {
}
};
s.deleteLayer("layerIndex", l);
Exception in thread "main" org.neo4j.graphdb.NotFoundException: More than one relationship[RTREE_REFERENCE, INCOMING] fo
und for NodeImpl#7208228
at org.neo4j.kernel.impl.core.NodeImpl.getSingleRelationship(NodeImpl.java:305)
at org.neo4j.kernel.impl.core.NodeProxy.getSingleRelationship(NodeProxy.java:125)
at org.neo4j.collections.rtree.RTreeIndex$1.onIndexReference(RTreeIndex.java:163)
at org.neo4j.collections.rtree.RTreeIndex.visitInTx(RTreeIndex.java:372)
at org.neo4j.collections.rtree.RTreeIndex.visitInTx(RTreeIndex.java:365)
at org.neo4j.collections.rtree.RTreeIndex.visitInTx(RTreeIndex.java:365)
at org.neo4j.collections.rtree.RTreeIndex.removeAll(RTreeIndex.java:157)
at org.neo4j.gis.spatial.DefaultLayer.delete(DefaultLayer.java:296)
at org.neo4j.gis.spatial.SpatialDatabaseService.deleteLayer(SpatialDatabaseService.java:300)
..
Rita
--
You received this message because you are subscribed to the Google Groups "Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email to neo4j+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
config = new HashMap<String, String>();
config.put(LayerNodeIndex.LAT_PROPERTY_KEY, "la");
config.put(LayerNodeIndex.LON_PROPERTY_KEY, "lo");
config.put(SpatialIndexProvider.GEOMETRY_TYPE, LayerNodeIndex.POINT_PARAMETER);
layerIndex = new LayerNodeIndex("layerIndex", graph, config);
Transaction tx = graph.beginTx();
index = graph.index();
nodes = index.forNodes("nodeA");
hits = nodes.query("idpv", "*");
Node node = null;
while (hits.iterator().hasNext()) {
node = hits.iterator().next();
layerIndex.add(node, "", "");
}
hits.close();
tx.success();
tx.finish();