Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
06-17-2021 01:14 AM
I have already searched and tried a lot. It is clear to me that Neo4j in version 4 multiples the databases in a different directory.
By the way, I am using Neo4j Desktop 1.4.3 with Zulu Java 11.
However, the admin import does not seem to create the database, which is empty. Difference between graph.db (V3) and Neo4j (V4) in the newer version is also clear.
Furthermore the program does not know "--mode=csv" anymore(?).
By the way, 5 large csv files are to be imported.
The admin import for Neo4j Desktop Version 4 (doesn't work)
SET dirNeo4jDb=C:\Users\xt35386.Neo4jDesktop\relate-data\dbmss\dbms-548a1c5a-cac2-4c70-919c-f108fe353b06
::***********************************************************************************************************
::Start with batch programm
::***********************************************************************************************************
CALL rmdir "%dirNeo4jDb%\data\databases\neo4j" /s /Q
:: Create new database (nodes and edges):
CALL %dirNeo4jDb%\bin\neo4j-admin import ^
-- mode= csv^
--database = neo4j ^
--delimiter=";" ^
--array-delimiter="|" ^
--id-type=STRING ^
--nodes="%dirNeo4jDb%\import\Knoten_nat.csv"^
--nodes="%dirNeo4jDb%\import\Knoten_jur.csv"^
--nodes="%dirNeo4jDb%\import\Knoten_re.csv"^
--relationships="%dirNeo4jDb%\import\Kanten_1_2.csv" ^
--relationships="%dirNeo4jDb%\import\Kanten_2_1.csv"
The whole admin import looks like this in version 3, which works:
SET dirNeo4jDb=C:\Users\Ulrike.Neo4jDesktop\neo4jDatabases\database-c288f0c8-a632-4675-8355-a1d2a4e0549d\installation-3.5.6\
::***********************************************************************************************************
::Start with batch programm
::***********************************************************************************************************
CALL rmdir "%dirNeo4jDb%\data\databases\graph.db" /s /Q
:: Create new database (nodes and edges):
CALL %dirNeo4jDb%\bin\neo4j-admin import ^
--mode=csv ^
--database=graph.db ^
--delimiter=; ^
--array-delimiter="|" ^
--id-type=STRING ^
--nodes="%dirNeo4jDb%\import\Knoten_nat.csv"^
--nodes="%dirNeo4jDb%\import\Knoten_jur.csv"^
--nodes="%dirNeo4jDb%\import\Knoten_re.csv"^
--relationships="%dirNeo4jDb%\import\Kanten_1_2.csv" ^
--relationships="%dirNeo4jDb%\import\Kanten_2_1.csv"
Thanks a lot!!!
06-23-2021 04:46 PM
Yes mode=csv is gone
the rest should still mostly work, see here in the docs
06-23-2021 04:47 PM
You should not remove database directories, instead use --force to override
neo4j 4.x has separate directories for databases and transaction logs that you would have both to delete.
All the sessions of the conference are now available online