Hello developers, I think, i need help.
I try to import ~400K json data into graph database by using APOC. But I got an error. I believe I just make a small mistake on my cipher query.
Error screen shot:
Take a look my cipher query:
with "file:///huulietgeed.json" as url
call apoc.load.json(url) yield values unwind values as value
merge (c:Company {register: value.info.register_number})
on create set c.name = value.info.company_name,
c.form = value.info.company_form,
c.register_date = value.info.register_date,
c.type = value.info.company_type,
c.number_of_owners = value.info.number_of_owner,
c.location = value.info.company_location
foreach (holder in value.stakeHolders |
merge (p:Person {person_id : holder.firstname + "." + holder.lastname})
on create set p.firstname = holder.lastname,
p.lastname = holder.firstname,
p.country = holder.country
create (holder1:RegisterDate {date: holder.date})
merge (p)-[:has]->(holder1)-[:holder_of]->(c)
)
foreach (manager in value.ceo |
merge (m:Person {person_id: manager.lastname + "." + manager.firstname})
on create set m.firstname = manager.firstname,
m.lastname = manager.lastname,
m.country = manager.country
create (manager1:RegisterDate {
position: manager.position,
date: manager.date
})
merge (m)-[:has]->(manager1)-[:has_position]->(c)
)
foreach (area in value.area |
merge (a:ActivityArea {code: area.code})
on create set a.title = area.title
create (area1:RegisterDate {
date: area.date
})
merge (c)-[:has]->(area1)-[:operation]->(a))
please help me!