CompTIA DataSys+ (DS0-001)Database FundamentalsMedium

A database administrator is setting up a new database system that needs to support complex analytical queries, often involving traversing deep, recursive relationships, such as organizational hierarchies or social network connections. Which database model is specifically optimized for this type of data and query pattern?

  1. AKey-Value Store
  2. BGraph Database
  3. CRelational Database
  4. DColumn-Family Store
Show answer & explanation

Correct answer: B. Graph Database

Graph databases are purpose-built for managing highly interconnected data and excel at traversing relationships. Their data model, based on nodes and edges, is inherently suited for queries involving complex, recursive relationships like hierarchies or networks.

Why the other options are wrong

  • A. Key-value stores are for simple data access by key, not for complex relationship queries.
  • C. Relational databases can handle relationships with joins, but traversing deep, recursive relationships can be inefficient and complex.
  • D. Column-family stores are good for wide tables and high write throughput, but not for complex relationship traversals.

Graph Database

A NoSQL database that uses graph structures (nodes, edges, and properties) to store and query highly interconnected data.

  • Optimized for relationships and network structures.
  • Excels at traversing complex, recursive connections.
  • Used for social networks, recommendation engines, fraud detection.

Memory trick: Graph databases 'Graph' out 'Relationships' perfectly.

More Database Fundamentals questions