Hi: I was playing with the Neo4j and its python binding. I want to import the user relationship data to Neo4j. Say id is the unique id for the user, I found no easy way to prevent the same id from generating different Nodes. The code below may works, but the data may be too big for memory.
id_node_mapping = {} def get_node(id): if id in id_node_mapping: return id_node_mapping.get(id) else: node = neo.node(name=id) id_node_mapping[id] = node return node Any solution to this problem? Thanks. _______________________________________________ Neo mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user