I have been running in to the same error as documented above when attempting to use apoc.export.cypher from apoc-4.0.0.0-all-jar with Neo4j 4.0.0 as follows based on the information found at https://neo4j.com/docs/labs/apoc/current/export/cypher/:
// default config populated for illustration
CALL apoc.export.cypher.all("all.cypher", {
format: "cypher-shell",
useOptimizations: {type: "UNWIND_BATCH", unwindBatchSize: 20}
})
YIELD file, batches, source, format, nodes, relationships, properties, time, rows, batchSize
RETURN file, batches, source, format, nodes, relationships, properties, time, rows, batchSize;
Note that if I change the output format to JSON, it works:
CALL apoc.export.json.all("all.json",{useTypes:true})
I don't want JSON, but hey, it's a data point.
Here's what's interesting, though.
If I use the Cypher export query above on a database that WAS NOT UPGRADED from 3.5.x to 4.0.0, it creates a file with the right data in it. All of the databases I was trying originally were upgraded from 3.5.x, but when I created a dummy 4.0.0 database by hand with one node in it, the Cypher export was fine. At the risk of perpetrating a correlation-equals-causation fallacy, I wonder if they are related?
Ali