CompTIA Data+ (DA0-002)Data Concepts and EnvironmentsMedium

A software development team is building a new application that requires a flexible, schema-less document store to manage user profiles. Each user profile can have a varying number of attributes, and new attributes may be added frequently without requiring changes to the database schema. The team needs to efficiently store and retrieve these JSON-like documents. Which type of NoSQL database is BEST suited for this use case?

  1. AGraph Database
  2. BKey-Value Store
  3. CDocument Database
  4. DColumn-Family Database
Show answer & explanation

Correct answer: C. Document Database

Document databases are specifically designed to store and retrieve semi-structured data, often in JSON or XML formats. Their schema-less nature and flexibility make them ideal for managing user profiles with evolving attributes.

Why the other options are wrong

  • A. Graph databases are designed for storing and navigating relationships between entities, not for schema-less document storage.
  • B. Key-value stores are simpler, storing data as a collection of key-value pairs, less suited for complex JSON-like documents.
  • D. Column-family databases are optimized for wide columns and large datasets, not primarily for flexible document storage.

Document Database

A NoSQL database that stores data in flexible, semi-structured documents, typically in JSON, BSON, or XML format. They offer schema-less design and horizontal scalability.

  • Stores data as documents (e.g., JSON)
  • Schema-less design for flexibility
  • Ideal for evolving data models like user profiles
  • Supports rich queries within documents

Memory trick: NoSQL: Not just SQL, for diverse data needs.

More Data Concepts and Environments questions