11cGraphDBs

Database Management

Mick McQuaid

University of Texas at Austin

11 May 2026

Intro

  • One of the first kinds of databases was the network database
  • It relaxed an assumption of the very first databases, which were strictly hierarchical
  • Instead of every node having one parent (except the root), the network database node could have multiple parent-child relationships
  • It fell out of favor when relational databases were introduced in the 1970s
  • The network database was considered difficult to manage in comparison to the relational model
  • But it served an important purpose and has been reborn in a sense in contemporary graph databases

The graph database

  • Graph theory is a branch of mathematics that works with sets of objects called nodes (also known as vertices or locations) and edges (also known as arcs or links)
  • Graph theory enjoyed a surge in popularity when social networks on the web became popular and it was found that social networks obeyed certain laws of graph theory
  • But representing social networks was problematic with existing databases
  • Hence, graph databases have become fairly popular for representing relationships between things

Example: Neo4j

  • Neo4j is the most popular graph database product
  • Represents three basic concepts
    • nodes (things, people)
    • edges (relationships)
    • properties (key-value pairs attached to nodes or edges)
  • Uses the Cypher Query Language to manage databases

Cypher Query Language

  • Similar to SQL except it models relationships and properties
  • Uses a MATCH keyword to match patterns in the graph
  • Contains a WHERE clause to define conditions
  • Uses a RETURN clause to organize output of a query
  • In the following example, the keywords begin each line, all other words are user defined
  • In the following example, the punctuation is vital to specifying the patterns

Wikipedia example of a Cypher query

MATCH (nicole:Actor {name: 'Nicole Kidman'})-[:ACTED_IN]->(movie:Movie)
WHERE movie.year < $yearParameter
RETURN movie

A visual graph produced by Neo4j

Further reading

  • I taught a class in Contemporary Databases a decade ago and wrote a hundred page study guide for it, mostly focused on MongoDB and Neo4j. That book is in Canvas > Files > contemporaryDatabases.pdf.
  • I made extensive use of Robinson et al. (2015) in that class, and recommend it if you want to learn more about Neo4j.

END

References

Robinson, Ian, Jim Webber, and Emil Eifrem. 2015. Graph Databases, 2nd Edition. O’Reilly Media.

Colophon

This slideshow was produced using quarto

Fonts are Roboto, Roboto Light, and Victor Mono Nerd Font