neo4j

Neo4j database size grows

…衆ロ難τιáo~ 提交于 2019-12-07 18:19:33
问题 Im using neo4j 3.0.1 community, and i have a few GBs of data. Those data very quickly become outdated (like 2,3 times per day) and i have to create new data first, and then delete the old stuff (so at any point in time some data are available). The problem is that neo4j doesnt reuse space from deleted nodes/relationships. Im using MATCH (n) WHERE condition DETEACH DELETE n I can see that nodes are beeing deleted (their number is constant ~30M) but the size is growing (after 12 updates, size

Neo4j slow creation method [closed]

♀尐吖头ヾ 提交于 2019-12-07 17:58:48
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . In my Neo4j/Neo4j Spring Data application I have a following entities: VoteGroup contains relationships VOTED_ON and VOTED_FOR to entities Criterion and Decision and list of Vote @NodeEntity public class VoteGroup extends BaseEntity { private static final String VOTED_ON = "VOTED_ON"; private final static String

Can't connect neo4j shell to local server

徘徊边缘 提交于 2019-12-07 17:52:18
问题 I've installed neo4j 2.0.0 via homebrew and started the server. I'm able to access the webadmin console at port 7474 but when I run neo4j-shell -host localhost -port 7474 I get: non-JRMP server at remote endpoint java.rmi.ConnectIOException: non-JRMP server at remote endpoint at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:248) at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202) at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:341) at sun.rmi

How to import .rdf file in Neo4j database?

风流意气都作罢 提交于 2019-12-07 17:37:29
I have a .rdf file which I was used for Dgraph in order to import the data and the subsequently queries in order to get the relations in the Dgraph Ratel UI. Now I need to include in my web application for which Dgraph doesn't have support ( link ). Hence I started looking for Neo4j. Can anyone please help out how to import .rdf file in Neo4j if not what's the workaround. Thanks. Labeled property graph (LPG) and RDF graph are different graph data models, see: RDF Triple Stores vs. Labeled Property Graphs: What's the Difference? by Jesus Barrasa Reification is red herring by Bob DuCharme Neo4j

Neo4j Cypher: Create a relation only if the end node exists

霸气de小男生 提交于 2019-12-07 17:26:47
问题 For the following Cypher statement: start n=node:types(id={typeId}), g=node:groups(id={groupId}) create unique (n)<-[:has_type]-(unit {props})-[:has_group]->(g) return unit There are cases when g may be null (i.e. a group with id groupId does not exist). In such a case, what should I do to make this statement still create the unit, but skip the has_group relation to g? Right now, unit does not get created, presumably because g is null. I'm using Neo4j Advanced 1.8 Thanks! 回答1: I would suggest

How do I see if DELETE was successful om Neo4j via REST API?

非 Y 不嫁゛ 提交于 2019-12-07 17:15:54
问题 How do I see if DELETE was successful om Neo4j via REST API ? Here is my query. MATCH (from_user:User),(to_user:User) WHERE from_user.id = '522fed61e4b0a1f88d599ae0' AND to_user.id = '52b9f410e4b03902bd21629e' MATCH from_user-[r]->to_user DELETE r via REST I get following response regardless of whether anything was deleted or not. { "results": [ { "columns": [], "data": [] } ], "errors": [] } 回答1: Add this to your POST body "includeStats":true For example, [ { "statement": "MATCH (from_user

node_auto_index does not exist

孤街醉人 提交于 2019-12-07 16:23:30
问题 I have created the data set with some entities like Users, Media and their relationships. My neo4j.properties file has auto indexing turned on for both nodes and relationships. I have also added an attribute 'type' to node_keys_indexable . However when I get the following error when running the following queries. START user =node:node_auto_index(fn="Balaji") RETURN user.ln Error: Index `node_auto_index` does not exist I am new to neo4j . Appreciate any help. Thanks and Regards Balaji 回答1: did

Logging http request/response with separate timings for each in Neo4j server

这一生的挚爱 提交于 2019-12-07 16:22:00
问题 I wanted to log http request and response to Neo4j server. I searched and got the answer on stackoverflow itself in below question: How to log query statement to Neo4j server, is it possible? The configuration in the answer to above question results in same time logged for both request/response. I was wondering what that time represents ,i.e, when the server received the request or when it generated the response? Also, I want to log the request and response with individual time for each(i.e,

Cypher query in py2neo

余生长醉 提交于 2019-12-07 16:18:21
问题 How do I perform the functions of shortestPath() and allShortestPaths() in py2neo? In Cypher, I'd execute something like: START beginning=node(4), end=node(452) MATCH p = shortestPath(beginning-[*..500]-end) RETURN p I've tried what I thought was the equivalent (below), but this doesn't work (these relationships work in cypher, and the node_* objects are indeed the correct nodes >>> rels = list(graph_db.match(start_node=node_4, end_node=node_452)) >>> rels [] 回答1: I don't want to steal

Neo4j use only one core in Cypher query running

懵懂的女人 提交于 2019-12-07 16:10:49
问题 When i run a Cypher query in UI, only one core in server is going up and the query gets stuck or responds very slow. I use Neo4j 3.0.7 Community. Someone have idea what i can tune for using all cores? 回答1: A single Cypher query is limited to a single thread. See this tweet from late 2015 by Stefan Armbruster: A cypher statement is (in most cases) one transaction and therefore only on one thread. If your query is slow, you can use various tricks for optimizing it: this blog post is a good