Reputation: 3850
I have a Neo4J Database with Nodes that have an id, lat, and lon property.
I created a PointLayer and created a SpatialIndex.
Now I have to add all Nodes to the Index. The REST call for a single node is:
POST /db/data/ext/SpatialPlugin/graphdb/addNodeToLayer HTTP/1.1
Host: localhost:7474
Accept: application/json
Content-Type: application/json
Cache-Control: no-cache
{
"layer": "geom",
"node": "http://localhost:7474/db/data/node/<my_nodeid_goes_here>"
}
But how can this be extended to match multiple or even every node?
Upvotes: 1
Views: 421
Reputation: 41706
There is a function that does it for multiple nodes, you just pass a list of your nodes, see:
here is a test:
I would recommend to do perhaps 1000 at a time.
Upvotes: 1