Skip to content

Instantly share code, notes, and snippets.

@thecraftman
Last active May 30, 2021 03:52
Show Gist options
  • Save thecraftman/3ae6ba7354fb5f7932e1c47860153107 to your computer and use it in GitHub Desktop.
Save thecraftman/3ae6ba7354fb5f7932e1c47860153107 to your computer and use it in GitHub Desktop.
SQL vs NoSQL
SQL NoSQL
When your access patterns aren't defined When your access pattern is defined.
When you want to perform flexible queries. If your access patterns arent define you won't know what queries to perform. When your primary key is known.
When you want to perform relational queries. When your data model fits (graphs)
When you want to enforce field constraints, this allows you to keep your data consistent. High efficiency Scaling
When you want to use a documented access language (SQL) is generally universal across all the Relational Database Engines. When you need high performance and low latency.
Data use Schemes Schema-less
Relations! No (very few) Relations
Data is distributed across multiple tables Data is typically merged and nested in a few collections
Horizontal scaling is difficicult/impossible; vertical scaling is possible Both horizontal and vertical scaling is possible
Limitations for lots of (thousand) read & write queries per second. Great performance for mass (simple) read & write queries.
Structured data can be stored in tables Using JSON data un-structured data can be stored.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment