Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
01-05-2022 03:13 PM
Hello ,
I am currently working with the 4.4.0 version of the Neo4j Desktop, on mac of version 11.6.2.
I have been able to load 1.24M nodes and am now trying to load the associated 3.1M relationships.
I have tried loading them with the following command
:auto USING PERIODIC COMMIT 1000
LOAD CSV WITH HEADERS
FROM "file:///2022-01-05_seattle_users_relationships.csv" as row
MATCH (follower:user {id:row.user_id})
MATCH (followed:user {id:row.follows_id})
MERGE (follower)-[r:FOLLOWS]->(followed)
ON CREATE SET
r.age=row.relationship_age
but am getting the following error:
Neo.TransientError.Transaction.MaximumTransactionLimitReached
Unable to start new transaction since limit of concurrently executed transactions is reached. See setting dbms.transaction.concurrent.maximum
I also tried running the same command with smaller files (500k relationships per file). The first 2 were processed properly, but the 3rd one showed the same error.
I tried looking for the dbms.transaction.concurrent.maximum
field in the neo4j.conf file, but could not find it.
Could you please let me know if I should add that field to that file? And if so, what value I should assign to it? if not that, could you let me know how I could solve this problem?
If that can help, the rows in my relationship file look like the below:
user_id,follows_id,created,relationship_age
12345,98765,2019-05-05 07:00:00 UTC,976
Thank you very much for any help you can provide.
Alexandra.
01-05-2022 03:30 PM
We wouldn't expect to see that error unless there are other transactions executing, maybe you started additional transactions that are still executing?
Also, please provide an EXPLAIN plan of the query. You will want to make sure you have an index or unique constraint on :user(id)
to support fast matching.
01-05-2022 06:17 PM
Hello Andrew,
Thank you for your answer.
Yes, I had run CREATE CONSTRAINT ON (u:user) ASSERT u.id IS UNIQUE;
before anything else.
The only thing I had run aside from that was the import of the nodes:
:auto USING PERIODIC COMMIT 5000
LOAD CSV WITH HEADERS
FROM "file:///2022-01-05_seattle_users_and_followers.csv" as row
MERGE (u: user {id:row.user_id})
I only executed the import of the relationships once all nodes had been fully imported.
I am sorry, but I am not sure how to run an EXPLAIN or PROFILE on a query that starts with :auto
. I tried running
PROFILE <-- I also tried EXPLAIN
:auto USING PERIODIC COMMIT 1000
LOAD CSV WITH HEADERS
FROM "file:///2022-01-05_seattle_users_relationships.csv" as row
MATCH (follower:user {id:row.user_id})
MATCH (followed:user {id:row.follows_id})
MERGE (follower)-[r:FOLLOWS]->(followed)
ON CREATE SET
r.age=row.relationship_age
but am getting a syntax error.
Is there another way of running the EXPLAIN plan you could recommend?
01-06-2022 12:59 PM
Try placing the PROFILE after the :auto. :auto
is not actually Cypher, it's a command that is interpreted by the browser so it knows to execute the query a certain way to the server.
01-06-2022 03:15 PM
Ah, ok. Thank you for your suggestion, and for explaining.
I tried
:auto PROFILE USING PERIODIC COMMIT 1000
LOAD CSV WITH HEADERS
FROM "file:///2022-01-05_seattle_users_relationships.csv" as row
MATCH (follower:user {id:row.user_id})
MATCH (followed:user {id:row.follows_id})
MERGE (follower)-[r:FOLLOWS]->(followed)
ON CREATE SET
r.age=row.relationship_age
but got the same error:
Neo.TransientError.Transaction.MaximumTransactionLimitReached
Unable to start new transaction since limit of concurrently executed transactions is reached. See setting dbms.transaction.concurrent.maximum
I have no other neo4j operation running. This is the first command I ran, after starting this DBMS again (in which I had already run the CONSTRAINT
command and had already loaded all my nodes).
01-07-2022 11:42 AM
Goodevening,
You could try the new syntax for importing a csv file:
Syntax Deprecated
USING PERIODIC COMMIT ...
``` Replaced by:
CALL {
...
} IN TRANSACTIONS
Yours kindly Omer
01-07-2022 05:47 PM
Hello Omer,
Thank you very much for your suggestion. I will try it too.
01-10-2022 11:15 AM
Hello Alexandra,
We identified a bug that is responsible for this error, and it should go out with the next 4.4.x release (should be 4.4.3).
01-10-2022 02:23 PM
Hello Andrew,
Thank you very much for looking into this, and implementing a fix. I appreciate it. I will download 4.4.3, when it becomes available.
All the sessions of the conference are now available online