I am new to Neo4j. I tried to create "Account" nodes and "Trade_History" relations at the same time using apoc.import.csv.
CALL apoc.import.csv(
[{fileName: "file:///Account.csv", labels: ['Account']}],
[{fileName: "file:///Trade_History.csv", type: 'TRANSACTION'}],
{}
)
However, I received the following error message.
Neo.ClientError.Procedure.ProcedureCallFailed Failed to invoke procedure
apoc.import.csv
: Caused by: java.lang.IllegalStateException: Node for id space __CSV_DEFAULT_IDSPACE and id xxxxxxx not found
I think the error is that the id "xxxxxxx" is not found, but which id, Account or Trade_History, is missing? Is there an ID that exists in Trade_History that does not exist in Account? If so, is it possible to implement any way to skip (not create a relationship) if the Trade_History ID pair does not exist in the Account? Or, If you know of another candidate query, it would be appreciated.
This might be basic, but could you tell me some advice? Thank you in advance.
P.S. The first three lines of Account.csv and Trade_History.csv are as follows;
Account.csv
:ID,name
000000000080,James
000000000056,Kevin
000000000039,Thomas
Trade_History.csv
LABEL:STRING,ACCOUT:START_ID,ACCOUT:END_ID
XYZ36417771,AAA_20670095845, 047316281
XYZ56315967,BBB_0000970982, 456317783746
XYZ61489917,CCC_00209200036399,093891638