Skip to content
uencoder

NoSQL

NoSQL is the umbrella term for non-relational databases, including document, key-value, column-family, and graph models, designed for scalability and flexible schemas.

Purpose

To address relational database limitations in massive data volumes, flexible schemas, and horizontal scaling.

Mechanism

Four major types: document (MongoDB, JSON documents), key-value (Redis, simple and fast), column-family (Cassandra, wide sparse rows), graph (Neo4j, relationship-dense). Trades part of ACID for BASE eventual consistency and horizontal scaling. No fixed schema (or flexible schema).

Use cases

  • Horizontal scaling of massive data
  • Flexible/dynamic schemas
  • Caching and session storage
  • Social graphs and recommendations

Examples

  • Input
    db.users.insert({name:"Ada",tags:[...]})
    Output
    No fixed schema

    Document store

Common errors

Assuming NoSQL needs no data modeling
Document structure and indexes still need design

Related terms

References