Graph Data Models 101

Learning Goals

In this tutorial, you will learn about graphs, and how a graph database is different from a database built on a relational data model. You will not find any code or syntax in this tutorial, but rather a comparison of graphs and relational data models. By the end of this tutorial, you will be able to answer the following questions:

  • What is a graph?
  • How are graphs different from relational models?
  • How is data modeled in a graph?
  • How is data queried from a graph?

Along the way, you might find that a graph is the right fit for the data model used by your app. Any data model that tracks lots of different relationships (or edges) between various data types is a good candidate for a graph model.

Whether this is the first time you are learning about graphs or looking to deepen your understanding of graphs with some concrete examples, this tutorial will help you along your journey.

If you are already familiar with graphs, you can jump right into our coding example for React.

If you are a SQL user and you’d like to learn how common SQL syntax maps to similar GraphQL syntax so you can use your SQL knowledge to jump-start your GraphQL learning journey, see Introduction to Dgraph for SQL Users.