Question

I was using python neo4j rest client in a project and just switched to Py2neo.

I tried to get a node from the database by its ID but got the following error :

AttributeError: 'GraphDatabaseService' object has no attribute 'get_node'

I used get_node function (http://nigelsmall.com/_api/py2neo/neo4j.html#py2neo.neo4j.GraphDatabaseService.get_node)

Am I doing something wrong or the doc should be updated ?

Thanks

Was it helpful?

Solution

The link I was referring to wasn't updated according to Nigel Small

For py2neo > v1.5, we can get a node by Id as follows : my_node = graph_db.node(id)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top