Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
12-14-2019 09:02 AM
Hello, i have the following problem
I have spring boot application which is running in docker along with neo4j image.
In database i have 10mln records and i want export it to csv file but i don't know where the exported file is located or how i can set path where it should be exported.
I use apoc.export.csv.query as below
CALL apoc.export.csv.query("MATCH (n:Rating) RETURN n", "ratings.csv", {})
Im starting application and all services through docker-compose.yaml file
path for import in volumes works fine but for export i cant set in this way.
Where is the exported file ratings.csv?
12-14-2019 01:32 PM
Surprisingly the export functions by default write to the import
folder, see https://neo4j.com/docs/labs/apoc/current/export/.
12-15-2019 03:34 AM
I added this line with dbms.directiories.import=import.
I have the following settings and that does not work still.
The exported file is not in this directory
12-15-2019 10:05 AM
Your volume shouldn't be mounted to /import
but instead to /var/lib/neo4j/import
- I've just verified that the exported file does end up there.
12-15-2019 03:14 PM
I did as you ordered but it didn't help
This volume for import works good but the second does not
12-16-2019 01:02 AM
I've used that command to start a container. Once it's up and I do an export I see the csv file produced in the mounted import folder:
docker run --rm \
--name neo4j \
-e NEO4J_AUTH=neo4j/123 \
-e NEO4J_ACCEPT_LICENSE_AGREEMENT=yes \
-e NEO4J_apoc_import_file_enabled=true \
-e NEO4J_apoc_export_file_enabled=true \
-e NEO4J_apoc_import_file_use__neo4j__config=true \
-e NEO4J_dbms_security_procedures_unrestricted=apoc.\\\*,algo.\\\* \
-e NEO4J_dbms_backup_address=0.0.0.0:6362 \
-e NEO4JLABS_PLUGINS=\[\"apoc\"\] \
-v $PWD/data:/data \
-p 7474:7474 \
-p 7687:7687 \
-p 6362:6362 \
-v $PWD/import:/var/lib/neo4j/import \
--user=$(id -u):$(id -g) \
neo4j:3.5.13-enterprise
All the sessions of the conference are now available online