Member-only story

How to Scale SQL and NoSQL Databases

Zeng Hou Lim
Better Programming
Published in
9 min readApr 28, 2020

Photo by Taylor Vick on Unsplash

When the amount of data gets too large for our databases, it’s natural that we consider scaling them to cope with the increased load. However, depending on whether it is a SQL or NoSQL database, the techniques and principles behind scaling are different. We’ll be exploring the main ideas behind scalability for both databases. Since this article assumes some fundamental knowledge about databases and their properties, it would be helpful to review SQL/NoSQL databases.

Content Overview

  • Vertical v.s. Horizontal Scaling
  • Database Sharding
  • Scaling SQL Database
  • Scaling NoSQL Database

Vertical v.s. Horizontal Scaling

Before we jump in, let’s understand the differences between the two types of scaling.

Vertical scaling

Vertical scaling is the process of improving the processing power of the server, by increasing its hardware capacity (e.g. CPU, RAM). While this could be a plausible option, there’s a threshold to the hardware improvements — it’s capped at what’s currently available. In…

Create an account to read the full story.

The author made this story available to Medium members only.
If you’re new to Medium, create a new account to read this story on us.

Or, continue in mobile web

Already have an account? Sign in

Zeng Hou Lim
Zeng Hou Lim

Written by Zeng Hou Lim

Excited about living my best life and becoming a better engineer. I like taking complex ideas and breaking them down.

Write a response

Thanks for the article! One question: I noticed that you mentioned "In scaling a SQL database, we sacrifice consistency for eventual consistency", but also that "it would make sense that financial systems that require high precision of data would…

Thank for the great article and it certainly helps. But I have one question here. In this article, you mentioned for nosql (Casandra), data sharding is applied to cluster of nodes and each shard is equal with no master-slave architecture notion here…