Questions tagged [py2neo]

Py2neo provides Python bindings for the Neo4j graph database via its REST web service interface.

Py2neo provides Python bindings for the Neo4j graph database via its REST web service interface. With more detailed information available from py2neo.org, the source code can be found on GitHub and an installable package from the Python Package Index.

The library provides both in-depth support for the Cypher query language as well as the Geoff graph data notation.

729 questions
2
votes
1 answer

In py2neo, how do I know if a push() worked?

I'm updating a node and pushing it: remote_graph.push(node) push() seems to return nothing. How can I tell if the push works? In my test code, I ought to be violating a unique constraint in Neo4J. How can I tell using py2neo? I expected an…
Tony Ennis
  • 12,000
  • 7
  • 52
  • 73
2
votes
1 answer

Are my Cypher statements 'overdone'

I am using py2neo with transactions. This means I am using the Cypher language. I am appending the textual Cypher statements to a transaction queue and submitting the contents of the queue in one shot with commit. It works fine. However, it is slow.…
Tony Ennis
  • 12,000
  • 7
  • 52
  • 73
2
votes
2 answers

Neo4j 2.2: Cypher Spatial request with other parameters returns Index does not exist

I'm using Neo4j to find Users who are in a 50 km radius and who are available on specific days. This question is similar to this other question but Indexes have changed since Neo4J 2.0 so the solution does not work. I use Neo4j 2.2.1, Neo4j-spatial…
bpipat
  • 3,700
  • 4
  • 20
  • 22
2
votes
4 answers

Stop Log from Outputting in py2neo

How can I stop py2neo from spitting out each created relationship/node, like the following: (http://localhost:7474/db/data/' ref=u'relationship/13441' start=u'node/13446' end=u'node/3' type=u'IN' properties={}>,) As encouraged by this page,…
NumenorForLife
  • 1,736
  • 8
  • 27
  • 55
2
votes
1 answer

py2neo (Neo4j) : py2neo.packages.httpstream.http.SocketError: Operation not permitted

I am running Neo4j 2.2.1 in ubuntu Amazon EC2 instance. When I am trying to connect through python using py2neo-2.0.7, I am getting following error : py2neo.packages.httpstream.http.SocketError: Operation not permitted I am able to access the…
Remis Haroon - رامز
  • 3,304
  • 4
  • 34
  • 62
2
votes
1 answer

Fast access to nodes in Neo4j

I have a method that creates a graph with nodes and relationships yadda. I want to return a list of node IDs to my caller so a later step can quickly locate these nodes and create additional relationships. I won't be able to return the Node…
Tony Ennis
  • 12,000
  • 7
  • 52
  • 73
2
votes
2 answers

How to convert neo4j return types to python types

I am using py2neo and I would like to extract the information from query returns so that I can do stuff with it in python. For example, I have a DB containing three "Person" nodes: for num in graph.cypher.execute("MATCH (p:Person) RETURN…
Phylth
  • 368
  • 2
  • 14
2
votes
3 answers

py2neo - How can I use merge_one function along with multiple attributes for my node?

I have overcome the problem of avoiding the creation of duplicate nodes on my DB with the use of merge_one functions which works like that: t=graph.merge_one("User","ID","someID") which creates the node with unique ID. My problem is that I can't…
panomi
  • 21
  • 3
2
votes
1 answer

How to declare a unique contraint with py2neo

I need ot enforce a unique contraint on my graph database. I found the following method: graph.schema.create_uniqueness_constraint("Website", "url") But it yields the following error: graph.schema.create_uniqueness_constraint("Website",…
bsuire
  • 1,383
  • 2
  • 18
  • 27
2
votes
1 answer

Auto increment property with py2neo (Neo4j)?

I'm using flask with py2neo for my Rest service , I have a user node with the label "User". how to autoincrement id for the "User" label , in neo4j using py2neo?
user2601376
2
votes
0 answers

Neo4j: Slow input and what garbage collector to use?

I'm working on a larger project, with a couple of million nodes, and relations. What I want in the end, is "just" a way to speed up my input of data. I've experinced that it is really slow, and only work on one CPU. As far as I have read, there is…
Thomas
  • 237
  • 4
  • 15
2
votes
1 answer

py2neo: py2neo.packages.httpstream.http.SocketError: timed out - execute, stream or Transactions?

First of all. I'm sorry if this is not complicity structured. I'm just not sure where to start or end, but did my best to give you as many information as possible. I work on a AWS M3.large, py2neo 2.0.4 and neo4j-community-2.1.7 I am trying to…
Thomas
  • 237
  • 4
  • 15
2
votes
1 answer

py2neo cypher error: KeyError: "u'cypher'

I'm trying to execute a cypher query with py2neo 2.0 (and Neo4j 2.1.6), but it fails with the following error: File "C:\Envs\project\lib\site-packages\py2neo\core.py", line 678, in cypher self.__cypher = CypherResource(metadata["cypher"],…
Daniel Silva
  • 379
  • 1
  • 11
2
votes
2 answers

neo4j, in a forum structure, how to find how many response each post got (including child of child...)

I'm writing a program that analyse posts in a forum. After loading forum threads into neo4j DB, I'm trying to "Rank" posts by the number of responses they got. Responses include direct responses as well as the entire sub-tree for each direct…
Izack
  • 823
  • 7
  • 13
2
votes
1 answer

Fastest way to get a large number of nodes from Neo4j using py2neo

I'm trying to load nodes (about 400) and relationships (about 800) from a Neo4j DB to create a force directed graph using D3. This is my get function (I'm using Tornado): def get(self): query_string = "START r=rel(*) RETURN r" query…
luisdaniel
  • 907
  • 11
  • 20