7
votes

I am trying to load a csv and create nodes in neo4j 2.1.0 using the following:

USING PERIODIC COMMIT LOAD CSV FROM "file://c:/temp/listings.TXT" AS line FIELDTERMINATOR '\t' CREATE (p:person { id: line[0] });

The columns are separated using 0x9 (tab) characters. But the created nodes have the entire row content in the id.

Any help is greatly appreciated.

3
Can you post an example of the file?suing
how large is the csv file? a cleanup with python/bash beforehand might just do the trick.cantdutchthis

3 Answers

4
votes

try FIELDTERMINATOR '\\t'
that's what worked for me

0
votes

Try casting toint(line[0]) since the default type when importing is string.

-2
votes

Open your csv file with notepad++ and try to delete the (") or to replace them with spaces.

I had the same problem but when I removed all the characters " it worked

enter image description here