Slide 1

Slide 1 text

Graph databases: What? Why? and How? By Nicky Wrightson - Principal Engineer @ FT

Slide 2

Slide 2 text

What? What is a graph database? Why? Why use a graph database? How? How to use a graph database

Slide 3

Slide 3 text

What? What is a graph database?

Slide 4

Slide 4 text

Graph Theory G = (V, E) Where V is a set of nodes also called vertices E is a set of edges also called links

Slide 5

Slide 5 text

“a graph database is a database designed to treat the relationships between data as equally important to the data itself” Neo4J https://neo4j.com/developer/graph-database/

Slide 6

Slide 6 text

No content

Slide 7

Slide 7 text

No content

Slide 8

Slide 8 text

No content

Slide 9

Slide 9 text

What? What is a graph database? Why? Why use a graph database?

Slide 10

Slide 10 text

Live demo time: http://www.six-degrees.ft.com

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

Implicitly any content about horsemeat is also about food safety and so on

Slide 13

Slide 13 text

What? What is a graph database? Why? Why use a graph database? How? How to use a graph database

Slide 14

Slide 14 text

How can we store our Graph?

Slide 15

Slide 15 text

Triple Stores

Slide 16

Slide 16 text

PREFIX foaf: SELECT ?name WHERE { ?person foaf:name ?name . } Find me all subjects (?person) and objects (?name) linked with the foaf:name predicate

Slide 17

Slide 17 text

Cosmos DB Property Graphs

Slide 18

Slide 18 text

What makes a good candidate for a graph database?

Slide 19

Slide 19 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 20

Slide 20 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 21

Slide 21 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 22

Slide 22 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 23

Slide 23 text

LOAD CSV WITH HEADERS FROM “characters.csv” AS line https://github.com/nwrigh/game-of-thrones-dataset

Slide 24

Slide 24 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 25

Slide 25 text

Give me the details of who killed their own relative? MATCH (killer:Person)- [:HAS_FATHER|:HAS_MOTHER|:HAS_SIBLING]- (relative:Person)-[:KILLED_BY]-(killer) RETURN killer, relative https://github.com/nwrigh/game-of-thrones-dataset

Slide 26

Slide 26 text

https://github.com/nwrigh/game-of-thrones-dataset

Slide 27

Slide 27 text

Other examples …. Which house killed the most? Which house married the most? https://github.com/nwrigh/game-of-thrones-dataset

Slide 28

Slide 28 text

Gotchas with Property Graphs

Slide 29

Slide 29 text

Watch out for the size

Slide 30

Slide 30 text

Some more things to look out for

Slide 31

Slide 31 text

Conclusion

Slide 32

Slide 32 text

@nickywrightson We're hiring! https://ft.com/dev/null https://aboutus.ft.com/en-gb/careers/ Thanks!