Skip to content

Instantly share code, notes, and snippets.

@suellenstringer-hye
Created January 23, 2018 18:57
Show Gist options
  • Save suellenstringer-hye/30bed897dd4506b760b59e52a34c9703 to your computer and use it in GitHub Desktop.
Save suellenstringer-hye/30bed897dd4506b760b59e52a34c9703 to your computer and use it in GitHub Desktop.
Cypher for loading monsters csv
LOAD CSV WITH HEADERS FROM "https://gist.githubusercontent.com/EdWarga/cc1c28bd4cea6f54ca2d/raw/228561253c6a8c900f151127828bf5f819a6dddd/authors.csv" AS csvLine
CREATE (p:Person { id: toInt(csvLine.authID), name: csvLine.author })
LOAD CSV WITH HEADERS FROM "https://gist.githubusercontent.com/EdWarga/afbab50905eb285a764e/raw/387e03f89ccce08361567075a26d2a31998dcc59/articles.csv" AS csvLine
CREATE (a:Article { id: toInt(csvLine.articleID), handle: csvLine.handle, title: csvLine.title, datePublished: csvLine.date, journal: csvLine.journal })
LOAD CSV WITH HEADERS FROM "https://gist.githubusercontent.com/EdWarga/d2f520e20ec9436da525/raw/b9d96ea1a86c39afc548779a71c4d02132079614/lcsh.csv" AS csvLine
CREATE (s:Subject { id: toInt(csvLine.subID), subject: csvLine.lcsh })
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment