Relational Databases and NoSQL Databases
Relational Databases and NoSQL Databases
Executive summary
Relational databases and NoSQL databases solve different classes of data problems. The relational model,
introduced by E. F. Codd, organizes information as relations and is typically implemented today as tables
with keys, constraints, joins, and SQL-based transactional processing. In contrast, NoSQL is an umbrella
term for several non-relational families—most importantly document, key-value, column-family, and graph
stores—whose data models, access patterns, and tradeoffs differ substantially from one another.
PostgreSQL and MySQL describe the relational model in terms of tables and SQL, while DynamoDB,
MongoDB, Bigtable, Redis, Cassandra, and Neo4j document very different abstractions and query surfaces.
1
The most important practical differences are these: relational systems prioritize structured schemas, joins,
declarative querying, and strong transactional integrity; NoSQL systems usually prioritize model flexibility,
workload-specific data layouts, and easier horizontal scale for very large or geographically distributed
workloads. That does not mean “RDBMS = consistency” and “NoSQL = eventual consistency.” Modern
relational systems can scale out through replication, partitioning, or distributed-SQL designs; modern
NoSQL systems often provide stronger consistency options and transactional features than early
generations did. Examples include PostgreSQL replication and distributed extensions such as Citus,
MongoDB multi-document ACID transactions, DynamoDB ACID transactions, Cassandra lightweight
transactions, and Spanner’s globally distributed relational transactions. 2
The right choice is therefore not “Which is better?” but “Which model fits the workload, data shape,
transaction semantics, growth path, and operating model?” For systems of record with rich constraints,
multi-row invariants, complex ad hoc queries, and audit-heavy workflows, relational databases usually
remain the default. For rapidly changing schemas, massive key-based scale, low-latency denormalized
reads, globally distributed writes, event workloads, content/catalog data, or graph traversal problems, a
NoSQL system may be a better fit. In many mature architectures, the winning answer is polyglot
persistence: relational for authoritative transactions and one or more NoSQL systems for specialized
access patterns. 3
Some details that materially affect a final recommendation were unspecified: target cloud, expected scale,
latency SLOs, compliance regime, migration source systems, and whether the workload is OLTP, event-
driven, analytical, graph-centric, or mixed. Because those details were unspecified, this report focuses on
architecture-level differences and product families rather than a benchmark-style recommendation.
1
and MySQL documents relational tables together with foreign keys and normalized relationships. Oracle’s
transaction documentation reflects the classic transactional assumptions of the relational model by
centering ACID semantics. Codd’s original paper emphasized data independence, consistency, and a high-
level data language as core advantages of the relational view. 4
A NoSQL database is not a single model or standard. It is a category of non-relational systems optimized
around different abstractions and tradeoffs. Official vendor documentation makes this clear: MongoDB
uses JSON-like BSON documents in collections; Redis centers unique keys mapped to values; Bigtable uses a
sparse, sorted wide-column map indexed by row key, column key, and timestamp; Neo4j uses a property
graph model of nodes and relationships; and DynamoDB explicitly supports both key-value and document
models. 5
• Document databases store self-describing records, often JSON-like, and favor grouping data that is
accessed together into a single document. MongoDB describes flexible schema and access-pattern-
oriented data modeling as core principles. 6
• Key-value databases treat the database primarily as a map from key to value. Redis documents this
directly, and Dynamo-style systems were designed around simple single-key access. 7
• Column-family or wide-column databases organize data by sparse rows and grouped columns,
usually optimized for high write throughput and locality around row keys. Bigtable’s paper and
current overview are canonical references; Cassandra’s design and documentation are in the same
lineage. 8
• Graph databases store entities as nodes and relationships as first-class edges, which is valuable
when traversal depth and connectedness are central to the workload. Neo4j’s documentation
defines the property graph model in exactly those terms. 9
One important caveat is that the traditional boundary is increasingly blurred. PostgreSQL supports JSON
and SQL/JSON operations; Cassandra exposes CQL, a SQL-like language; Bigtable now supports GoogleSQL
queries; MongoDB has added stronger transactions and rich aggregation; and Spanner shows that globally
distributed, horizontally scalable systems can still be relational and strongly transactional. The comparison
is therefore best understood as a spectrum of design priorities rather than two perfectly separate camps.
10
The table below is a synthesis. Because NoSQL is a family rather than one model, the NoSQL column
intentionally says “varies by subtype” where a single answer would be misleading. 11
2
Attribute Relational databases NoSQL databases Sources
3
NoSQL design is more access-pattern-driven. MongoDB’s documentation states that data accessed together
should often be stored together, which naturally pushes document designs toward embedding and
denormalization. Cassandra’s modeling guidance is even more explicit: start by defining the queries, then
create a table for each query shape. Bigtable schema guidance similarly elevates row-key design because
row keys determine ordering and locality. In other words, many NoSQL systems shift effort away from
normalization and toward physical locality, partition behavior, and read/write path efficiency. 23
That difference changes how developers think. In an RDBMS, a customer, order, order line, payment, and
shipment are often modeled as separate normalized relations joined at query time. In a document store,
the same domain may be modeled as a customer document plus embedded or duplicated order-state
projections. In a wide-column store, the same information may be materialized into multiple tables keyed
by specific access paths. In a graph store, the focus would be on relationships such as CUSTOMER ->
PLACED -> ORDER -> SHIPPED_TO -> ADDRESS . None of these is inherently superior; they optimize
different work. 24
The query surface follows the model. Relational systems use SQL, which remains the dominant
standardized declarative language for defining tables, filtering rows, aggregating values, joining relations,
and expressing transactions. PostgreSQL’s SQL documentation is representative. By contrast, NoSQL query
surfaces vary widely: MongoDB uses CRUD plus the aggregation pipeline; DynamoDB is fundamentally API-
oriented with GetItem , PutItem , Query , and key-based access; Cassandra uses CQL, which looks SQL-
like but reflects Cassandra’s partitioned data model; Neo4j uses Cypher for graph pattern matching;
Bigtable now supports GoogleSQL in addition to client APIs. This fragmentation is one of the most
consequential operational differences between relational and NoSQL systems. 25
A second major difference is how each family treats joins and cross-record composition. Traditional
relational systems make joins first-class and optimize them through indexes and cost-based planning. Key-
value systems generally do not; DynamoDB states plainly that it does not support a join operator. Document
systems frequently encourage pre-joined data layouts, although they may add limited join-like features.
Graph systems invert the problem by making relationships native to the model rather than a derived join
condition. This has huge implications for application code: in relational systems, the optimizer often decides
how to combine data; in many NoSQL systems, the developer must decide the shape in advance. 26
Storage internals reinforce these design choices. PostgreSQL documents B-tree indexes as its standard
multi-level tree structure and treats WAL-based durability as a core reliability mechanism for backup and
recovery. MongoDB emphasizes secondary indexes for selective document retrieval, while warning that
indexes speed reads at the expense of writes. Cassandra and Bigtable document storage engines built
around in-memory buffers and immutable SSTables, which align well with high write throughput,
compaction, and large-scale distribution. Neo4j exposes search-performance indexes tuned for property
graph lookups. A fair summary is that mainstream RDBMS designs are commonly tuned around general-
purpose query planning and mature transactional storage, while many distributed NoSQL stores are tuned
around append-friendly write paths, partition locality, and predictable access at scale. 27
The architecture difference can be visualized as follows. This diagram is conceptual, but it reflects the official
storage and query paths documented by PostgreSQL, MongoDB, DynamoDB, Cassandra, Bigtable, and
Neo4j. 28
4
Tables and Indexes
The write and read paths also tend to differ. The relational path emphasizes transaction boundaries,
constraint checks, and log-backed recovery; the distributed NoSQL path emphasizes partition routing,
replica coordination, and access-pattern-aware materialization. This is again a synthesis of vendor
documentation rather than a claim about every product. 29
Client request
Relational or NoSQL
Relational NoSQL
5
The classic NoSQL response was not “ignore correctness,” but rather “choose different correctness
boundaries.” Dynamo’s original paper is explicit: it targeted simple key-based operations, weaker
consistency where necessary, and high availability; it did not provide isolation guarantees and only
permitted single-key updates in its original form. Pritchett’s BASE article framed the alternative as basically
available, soft state, eventual consistency, explicitly trading strong immediate consistency for higher
availability and scale in partitioned systems. 31
CAP is often misunderstood in day-to-day architecture discussions. Gilbert and Lynch’s proof concerns
distributed systems under partition: in an asynchronous network, it is impossible to guarantee consistency,
availability, and partition tolerance all at once. Brewer’s later discussion of Spanner emphasized that CAP is
not a blanket statement that systems “pick any two forever”; rather, the decisive tradeoff emerges when
network partitions occur. This matters because it prevents a simplistic reading of RDBMS versus NoSQL. A
relational database running on one node does not “beat” CAP; a distributed relational system must still
make choices under partition, and a NoSQL system may provide stronger consistency than its reputation
suggests. 32
Modern systems have converged substantially on transaction support. MongoDB supports multi-document
ACID transactions, while warning that they can have performance costs and operational limits. DynamoDB
supports atomic multi-item transactions, with up to 100 actions and a 4 MB aggregate size limit. Cassandra
exposes lightweight transactions with linearizable consistency for specific compare-and-set style cases,
while keeping eventual consistency as the ordinary write/read model for much of the system. Spanner goes
further by combining horizontal distribution with externally consistent distributed transactions in a
relational model. The analytic conclusion is that the real question today is not “Does this database support
transactions?” but “What transaction scope, consistency level, and cost model does it support, and are
those semantics the ordinary path or the expensive path?” 33
Scalability shows the mirror image of that tradeoff. Relational systems have historically scaled vertically
first—larger machines, more memory, faster storage—then added read replicas, partitioning, or sharding
when necessary. PostgreSQL documents streaming replication, logical replication, hot standby, and
continuous archiving; Citus shows how PostgreSQL can be extended into a shared-nothing distributed
architecture. NoSQL systems such as MongoDB, Cassandra, Bigtable, and DynamoDB tend to make
horizontal partitioning a first-class design assumption. MongoDB’s sharding documentation, Cassandra’s
distributed ring and replication model, Bigtable’s tablet sharding, and DynamoDB’s partition-key design
guidance all demonstrate this bias toward scale-out. 34
Replication strategies differ as well. PostgreSQL replication is typically configured around primary/standby
and WAL streaming or logical data changes. MongoDB uses replica sets with automatic failover. Cassandra
uses replication factors and gossip-based membership to route reads and writes across replicas, with
tunable consistency levels controlling how many acknowledgments are required. Bigtable and DynamoDB
abstract replication behind managed-service interfaces, but their designs still hinge on partitioning and
replicated storage. Operationally, this means RDBMS replication is often easier to reason about
semantically, while many NoSQL systems give operators more direct control over the consistency/
availability/latency envelope. 35
Performance is therefore more about fit than branding. Relational systems tend to excel at complex joins,
secondary indexes, and mixed transactional querying over normalized data. Document databases excel
when the document boundary matches the application boundary. Key-value databases excel at direct keyed
6
access with extreme simplicity and low latency. Wide-column systems excel at huge datasets, high write
throughput, and key-ordered processing such as time series, clickstream, counters, or large-scale event
storage. Graph databases excel when the cost driver is traversing relationships rather than filtering rows.
Benchmark claims without workload details are usually not decision-grade information. 36
The chart below is intentionally conceptual rather than benchmark-based. It summarizes the broad tradeoff
space reflected in the source material, including CAP, Dynamo, Spanner, MongoDB transactions, Cassandra
tunable consistency, and distributed relational extensions. 37
Graph DB
Wide-column AP system
Dynamo-style key-value
NoSQL operations vary more by subtype. MongoDB Atlas offers snapshots and continuous cloud backup;
Cassandra uses snapshots and repair processes to reconcile replica state; Bigtable provides on-demand and
automated backups plus Cloud Monitoring integration; DynamoDB supports backup and restore through
native services and AWS Backup; Neo4j distinguishes Community and Enterprise capabilities, with
enterprise clustering, failover, and backups, and offers Aura as the fully managed option. The consequence
7
is that “NoSQL” has no single operational profile: self-managed Cassandra is operationally very different
from serverless DynamoDB, and both differ again from Atlas or Bigtable. 39
Monitoring and tooling also reflect database philosophy. PostgreSQL exposes rich internal statistics;
Cassandra metrics can be queried via JMX and external reporters; MongoDB, Bigtable, and DynamoDB
strongly emphasize cloud console and API-driven observability; Neo4j has dedicated operations tooling and
RBAC-oriented management. This does not create a universal winner, but it does mean that relational
tooling is often strongest for SQL-centric database operations, while managed NoSQL platforms can sharply
reduce undifferentiated operational burden when their constraints align with the workload. 40
A balanced inference from those features is that relational databases usually reduce security and
compliance sprawl when the application depends heavily on database-enforced invariants, row-level
policies, joins across governed entities, and auditable transaction boundaries, while managed NoSQL
services can be equally strong for encryption, IAM integration, and resilience controls when the data
model is already aligned to their access patterns. That is an inference from the cited security and
transactional features, not a claim that one family is inherently “more secure.” 42
Cost and licensing are similarly nuanced. PostgreSQL is under a permissive license with no software fee;
MySQL Community Edition is GPL-licensed, while Oracle offers commercial licensing for OEM and related
use cases. Managed NoSQL services often price by usage dimensions rather than only instance size:
DynamoDB offers on-demand pay-per-request and provisioned throughput modes; MongoDB Atlas and
Neo4j Aura use managed-service pricing tied to cluster tiers and usage dimensions. The practical
implication is that relational open source can minimize license cost but still incur substantial labor cost at
scale, while managed NoSQL can minimize operational staffing but produce higher variable bills under
heavy throughput, replication, storage, backup, or cross-region usage. 43
Document databases are strong for content management, product catalogs, customer 360 views, mobile
backends, personalization, and rapidly evolving application schemas. MongoDB explicitly highlights use
cases such as customer data management, product catalogs, payments, IoT, operational analytics, and real-
8
time analytics. The common thread is that the “thing the application wants” often maps naturally to a self-
contained document. 45
Key-value databases and key-value-centric services shine for sessions, caches, carts, rate limiting,
configuration, event pointers, and high-volume direct key access. Redis describes itself as an in-memory
key/value store and data structure server used for caching, queuing, and event processing. DynamoDB
positions itself for resilient, low-latency digital applications and documents both key-value and document
modes. These systems are often optimal when the main question is “Do you know the key?” rather than
“Can you compose arbitrary relations?” 46
Wide-column systems such as Bigtable and Cassandra are especially well suited to very large data volumes,
high write rates, ordered key access, counters, clickstream, IoT, personalization, recommendation features,
and operational analytics with large partitioned datasets. Bigtable’s paper and product docs emphasize
petabyte-scale structured data, low latency, MapReduce adjacency, and use cases such as clickstream, IoT,
and ML-adjacent workloads; Cassandra emphasizes linear scalability, high availability, and no single point of
failure. 47
Graph databases are specialized for connected data problems: fraud detection, recommendations, identity
and access management, knowledge graphs, supply chains, and master data relationships. Neo4j’s use-case
documentation emphasizes these domains because pathfinding, neighborhood analysis, and pattern
matching over many hops are where graph databases usually outperform relational joins or denormalized
NoSQL workarounds. 48
Migration strategy should usually be incremental rather than “big bang.” AWS DMS explicitly supports
migration among relational databases, NoSQL databases, and other data stores. MongoDB offers Relational
Migrator for mapping relational schemas into MongoDB models. Neo4j offers ETL tooling and guidance for
relational-to-graph mapping. PostgreSQL offers foreign data wrappers and strong JSON support, which can
help build interoperability layers rather than immediate rewrites. Bigtable exposes change streams for CDC-
style processing. The most successful migrations usually begin by moving a single bounded context or read
model, not an entire enterprise platform at once. 49
A practical interoperability pattern is to keep the relational database as the authoritative source of record
while projecting selected data into NoSQL read models through CDC, ETL, or event streams. That pattern
preserves transactional integrity where it matters most, while allowing denormalized, partition-friendly, or
graph-friendly projections for low-latency serving and analytics. AWS DMS, Datastream-style CDC, Bigtable
change streams, PostgreSQL logical replication, and graph ETL tools all support versions of this
architecture. 50
Relational databases
• Pros: strong ACID transactions, mature integrity constraints, expressive SQL and joins, and rich
governance/security features. 51
• Pros: excellent fit for normalized systems of record and complex ad hoc querying. 52
• Cons: horizontal scale can require sharding or distributed extensions that increase design and
operational complexity. 53
9
• Cons: rigid schema governance can slow teams when the domain is rapidly changing or mismatch-
heavy. 54
NoSQL databases
• Pros: model flexibility and workload-specific layouts often make application-facing reads and writes
simpler and faster at very large scale. 55
• Pros: many products are built for horizontal growth, geographic replication, and high availability
from the start. 56
• Cons: query capabilities, joins, and transaction semantics are far less uniform, so application
complexity can rise quickly if the model is poorly matched. 57
• Cons: denormalization and multiple read models can shift consistency and governance burdens
from the database into application logic and pipelines. 58
Decision checklist
Use the following flow as a first-pass decision framework. It reflects common tradeoffs documented across
the cited systems; it is not a substitute for workload testing. 59
Start
Yes No
Yes No
Yes No
Yes No
Yes No
• If the database must enforce business invariants across many entities, start relational. 30
10
• If the workload is document-shaped and schema evolution is frequent, document databases are
often a better match. 6
• If throughput, partitioning, and single-key or ordered-key access dominate, prefer key-value or
wide-column. 60
• If relationships are the data product, consider graph. 61
• If you need both strong relational semantics and distributed scale, evaluate distributed relational
systems before assuming NoSQL is required. 62
• If different parts of the system have different access patterns, use polyglot persistence and move
data through CDC/ETL rather than forcing one database to do every job. 63
The most rigorous conclusion is that relational and NoSQL databases are not competitors in the abstract;
they are different optimization strategies around data correctness, flexibility, locality, and scale. The
strongest architecture is the one that matches the database model to the workload’s true invariants and
access patterns, and it is increasingly common for serious production systems to use both. 64
3 16 20 29 30 44 51 59 13 Transactions
[Link]
8 47 [Link]
[Link]
11
17 PostgreSQL: Documentation: 18: 13.1. Introduction
[Link]
21 PostgreSQL: About
[Link]
32 37 [Link]
[Link]
43 PostgreSQL: License
[Link]
12
53 Concepts — Citus 13.0.1 documentation
[Link]
54 64 [Link]
[Link]
13