I just discovered yesterday, the use of WHERE
with LOAD
. This is really great as you can do controlled imports instead of blundering your way with the data.
WHERE
with LOAD
is shown in an example, but not discussed here:
//skip null values
LOAD CSV WITH HEADERS FROM 'file:///companies.csv' AS row
WITH row WHERE row.Id IS NOT NULL
MERGE (c:Company {companyId: row.Id});
In these URLs, LOAD
with WHERE
is not described at all, but would be useful:
- LOAD CSV - Neo4j Cypher Manual
- How-To: Import CSV Data with Neo4j Desktop - Developer Guides
- graphgist - Neo4j Graph Database Platform
- Using LOAD CSV for Import - Introduction to Neo4j 4.x Series
Finally, as a feature request, it would be useful to add an argument for conditions for importing into the APOC: