Quick revision
The short answer
The NoSQL wave often traded away transactions, joins and schemas for a scale most systems never needed, and the cost arrived later as consistency bugs and application code doing the database's job; distributed SQL now tries to keep SQL and transactions with horizontal scale, at its own latency and cost profile. The lesson is to choose data platforms on measured needs and data shape rather than trends, to value the boring choice with mature tooling, a hiring pool and known failure modes, and to keep data access behind service boundaries so a later change is a migration, not a rewrite. Most workloads fit a well-run single-primary relational database for years.
What to remember
In this answer, we looked at the swing from SQL to NoSQL and back. NoSQL traded transactions, joins and schemas for a scale many systems did not need, and the cost arrived later as consistency bugs and application complexity. Distributed SQL keeps SQL and transactions with horizontal scale, at a latency and cost premium. The lessons are to choose on measured needs and data shape, to value mature and well-understood platforms, and to keep data behind service boundaries, and we applied them to a decision where a large PostgreSQL usually remains the right choice.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
The NoSQL wave often traded away transactions, joins and schemas for a scale most systems never needed, and the cost arrived later as consistency bugs and application code doing the database's job; distributed SQL now tries to keep SQL and transactions with horizontal scale, at its own latency and cost profile. The lesson is to choose data platforms on measured needs and data shape rather than trends, to value the boring choice with mature tooling, a hiring pool and known failure modes, and to keep data access behind service boundaries so a later change is a migration, not a rewrite. Most workloads fit a well-run single-primary relational database for years.
Why this question is asked
Data platform decisions outlast most other technical choices: the database chosen today will hold the company's records for a decade, and moving off it is expensive. The swing from SQL to NoSQL and back is one of the clearest case studies the industry has, which is why senior candidates are asked what they took from it. The interviewer wants reasoning that can be applied to the next trend, not a verdict on MongoDB. In this answer, we will look at why the move to NoSQL happened and what it cost, why the industry moved back, the lessons that generalise, and how I would apply them to a concrete decision today.
1Why Companies Moved to NoSQL
Around 2010, a few internet companies had problems that relational databases of the time handled badly: huge write volumes, data spread across data centres, and schemas that changed weekly. Systems such as Dynamo, Bigtable, Cassandra and MongoDB showed that by giving up joins, multi-row transactions and fixed schemas, data could be partitioned across many cheap machines and stay available during failures. Those were real engineering advances for those workloads.
The trouble came when the pattern spread to companies that did not have those problems. Many applications with a few hundred gigabytes and a few thousand writes per second, comfortably within a single relational server, adopted document or wide-column stores because they were seen as modern and scalable, and because skipping schema design felt faster at the start.
2What It Cost Later
The costs arrived slowly. Without multi-document transactions (at the time), updating an order and its inventory consistently needed application logic, and bugs in that logic produced inconsistent data that was found months later. Without joins, data was duplicated across documents, and keeping the copies in sync became application code. Without a schema, every reader had to handle every historical shape of a document. Reporting, which SQL does well, required exporting to another system. Teams spent their time rebuilding database features badly in application code.
Notice the pattern: the scale benefit was real but unused, while the lost guarantees were needed every day. That mismatch, not any flaw in the technology, is the lesson.
3Why the Industry Moved Back
Three things changed. Single relational servers became enormous: a PostgreSQL or MySQL server with dozens of cores, hundreds of gigabytes of memory and NVMe storage handles workloads that needed clusters in 2010. PostgreSQL gained jsonb, so semi-structured data no longer required a separate store. And distributed SQL databases such as Spanner, CockroachDB, YugabyteDB and TiDB showed that horizontal scale and SQL transactions can coexist, by using consensus replication and distributed commits. NoSQL systems also moved toward SQL, adding transactions and query languages. The pendulum settled near the middle.
Distributed SQL is not free, though. Each write pays consensus round trips, cross-region transactions are slow, costs per node are higher and compatibility with PostgreSQL or MySQL is partial. It is the right answer for workloads that truly need it, and an expensive one for workloads that do not.
| Choice | What it gave | What it cost |
|---|---|---|
| Single-primary SQL | Transactions, joins, schema, mature tools | Vertical scale limit, failover care |
| NoSQL (2010s wave) | Horizontal scale, flexible schema | Lost transactions and joins; app complexity |
| Distributed SQL | SQL + transactions + horizontal scale | Consensus latency, cost, partial compatibility |
4The Lessons That Generalise
The first lesson is to choose on measured needs and the shape of the data, not on industry trends. Measure the data size today and in three years, the write and read rates, the latency targets, and how relational the data is: are there many relationships and invariants across entities, or is it naturally a set of independent documents or time series? Most business systems are deeply relational, and most fit a well-run single-primary relational database, with read replicas and partitioning, for many years.
The second lesson is to value the boring choice. A mature engine comes with tooling for backups, monitoring and migrations, a large pool of people who already know it, years of documented failure modes, and answers to most questions online. Those are worth a lot of raw performance. A new platform has to be clearly better for our problem to pay for its unknowns.
The third lesson is to keep options open. Put data access behind service boundaries, so only the owning service talks to its database. Then if one domain outgrows its platform, we migrate that domain's data and code, which is a project, rather than every service that queried the tables directly, which is a rewrite.
5Applying It to a Decision Today
Suppose a team proposes moving our main order database to a distributed SQL product because growth is coming. I would start with the numbers: 3 TB today, perhaps 10 TB in three years, 5,000 writes per second at peak. That fits a large PostgreSQL primary with partitioning for the biggest tables and replicas for reads. I would then ask what problem distributed SQL would solve that we actually have: multi-region writes, residency, or write rates beyond one machine. If none applies, I would stay on PostgreSQL, invest in the boring things such as partitioning, connection pooling and tested failover, and record the thresholds, for example writes per second or a regulatory change, that would reopen the question.
If one domain does have a real need, such as a global ledger that must accept writes in three regions, I would consider distributed SQL for that domain alone, behind its service boundary, after a proof on its real workload. That applies the lesson precisely: the right tool for the measured need, and nothing more.
- Measure size, rates, latency, data shapetoday and in three years
- Fits a well-run single-primary SQL database?YesChoose it; record review thresholdsNoContinue
- Need multi-region writes or extreme write scale?YesProve distributed SQL on real workloadNoConsider partitioning, replicas, caching
- Keep it behind the domain's service boundaryso the next change is a migration
4 steps in order. Play them, or step through them one at a time.
6Follow-up questions
Was the move to NoSQL a mistake?
For the companies with web-scale problems, no; it solved real problems. The mistake was adopting it as a default for workloads that fit a relational database, because the cost of lost transactions and joins was paid every day while the scale benefit was never used.
When would you still choose a NoSQL store today?
For data with a clear non-relational shape and access pattern: a key-value cache, a time series of metrics, a search index, or very high write volume of independent records with simple lookups. Usually next to a relational database, not instead of it.
How do you resist a trend when the team is excited about it?
By asking for the measured need and a proof, not by saying no. If the new platform wins on our numbers, we adopt it; if it does not, the evidence makes the decision for us, and the team learns the method.
7Conclusion
In this answer, we looked at the swing from SQL to NoSQL and back. NoSQL traded transactions, joins and schemas for a scale many systems did not need, and the cost arrived later as consistency bugs and application complexity. Distributed SQL keeps SQL and transactions with horizontal scale, at a latency and cost premium. The lessons are to choose on measured needs and data shape, to value mature and well-understood platforms, and to keep data behind service boundaries, and we applied them to a decision where a large PostgreSQL usually remains the right choice.
Open with
What the history taught me is that most of those moves were driven by trends rather than measured needs. NoSQL solved real problems for a few companies with web-scale writes and global distribution, but many others adopted it with a few hundred gigabytes of data, and traded away transactions, joins and schemas for scale they never used.
Then, if they want more
The cost showed up later: consistency bugs, duplicated data kept in sync by application code, and reporting that needed another system.
Now the industry has moved back, partly because single relational servers got huge and PostgreSQL got jsonb, and partly because distributed SQL showed you can have SQL, transactions and horizontal scale together, although with consensus latency, higher cost and partial compatibility. So my lessons are three.
Choose on measured needs and data shape: size, write rate, latency targets, and how relational the data is. Most workloads fit a well-run single-primary relational database with replicas and partitioning for years. Value the boring choice: mature tooling, a big hiring pool and well-known failure modes are worth a lot.
And keep data access behind service boundaries, so a later platform change is a migration of one domain, not a rewrite. Applied today, if a team wanted to move our order database to distributed SQL, I would first ask which measured need it solves.
If it is not multi-region writes, residency or write scale beyond one machine, I would stay on PostgreSQL and write down the thresholds that would reopen the decision.
About this answer
- Last updated
- 12 November 2026
- Checked
- Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
- Where the question comes from
- Written by Scrivio for practice. It is not taken from an interview.
- Official documentation
- PostgreSQL documentation, MySQL reference manual
Report an issue with this answer
Copy the line below and send it to the author with what you found. It carries the address of this page.
Issue with "Ten years ago many companies moved to NoSQL for scale; now many return to SQL, through...": https://scrivio-interview-library.netlify.app/databases/partitioning-and-sharding/b0de7ff1e0/