I'm very beginner to Cypher query. So, I'm trying to understand MATCH and CREATE. Here's what I am currently defining relationship between author and the book:
MATCH (book1:Book1 {title: 'The Ones Who Walk Away From Omelas'})
MATCH (author1:Author1 {name: 'Ursula K. Le Guin'})
CREATE (author1) - [:IS_AUTHOR_OF] -> (book1)
MATCH (book2:Book2 {title: 'A Fire Upon the Deep'})
MATCH (author2:Author2 {name: 'Vernor Vinge'})
CREATE (author2) - [:IS_AUTHOR_OF] -> (book2)
But this throws me error:
SyntaxError: WITH is required between CREATE and MATCH
I have looked in this post but still not able to solve this issue.
Here's what I have tried and still getting the same error:
MATCH (author1:Author1 {name: 'Ursula K. Le Guin'})
MATCH (book1:Book1 {title: 'The Ones Who Walk Away From Omelas'})
WITH author1, book1
CREATE (author1) - [:IS_AUTHOR_OF] -> (book1)
MATCH (author2:Author2 {name: 'Vernor Vinge'})
MATCH (book2:Book2 {title: 'A Fire Upon the Deep'})
WITH author2, book2
CREATE (author2) - [:IS_AUTHOR_OF] -> (book2)