Database

39 articles

Practical Introduction to SQL: Writing Fast and Understandable Queries
Database 2024-04-01

Practical Introduction to SQL: Writing Fast and Understandable Queries

Practical Introduction to SQL: Writing Fast and Understandable Queries

#DB#NewSQL#Book Review
What is a Database Index? How It Works and When You Need It
Database 2024-04-01

What is a Database Index? How It Works and When You Need It

Understand how database indexes work internally—B-tree and hash structures—when to add or avoid indexes, and how to measure index effectiveness using EXPLAIN.

#DB#Index#MySQL
Database ID Design: UUID vs Auto Increment vs ULID — Which to Choose?
Database 2024-03-30

Database ID Design: UUID vs Auto Increment vs ULID — Which to Choose?

Compare auto-increment integers, UUIDs, and ULIDs as database IDs. Learn the trade-offs in performance, sortability, and distributed system compatibility.

#DB
NULL in Database Design: Common Pitfalls and Best Practices
Database 2024-03-30

NULL in Database Design: Common Pitfalls and Best Practices

Learn how NULL works in relational databases, the three-valued logic problem, common query mistakes with NULL, and schema design strategies to avoid NULL-related bugs.

#DB
Notes on Spanner Insights
Database 2024-03-03

Notes on Spanner Insights

Explore Cloud Spanner architecture, replication strategies, indexing, and performance optimization for distributed databases.

#Spanner
Exploring Aurora Serverless
Database 2023-12-27

Exploring Aurora Serverless

Explore Aurora Serverless v2 capabilities including multi-AZ support, auto-scaling, cost optimization, and deployment considerations for databases.

#Amazon Web Service
MySQL Transaction Isolation Levels: Preventing Dirty Reads, Phantom Reads, and More
Database 2023-06-08

MySQL Transaction Isolation Levels: Preventing Dirty Reads, Phantom Reads, and More

Learn MySQL's four transaction isolation levels, the anomalies each prevents (dirty read, non-repeatable read, phantom read), and how to choose the right level.

#Transaction#MySQL
Transaction Overview
Database 2023-06-07

Transaction Overview

Understand database transaction fundamentals including ACID properties, concurrency control, and isolation for data integrity.

#Transaction
Sharding vs Partitioning: Key Differences and When to Use Each
Database 2023-06-03

Sharding vs Partitioning: Key Differences and When to Use Each

Understand the difference between database sharding and partitioning. Learn horizontal and vertical strategies, sharding trade-offs, and when each approach makes sense.

#Partitioning#Sharding
Full-Text Search with MySQL
Database 2023-04-30

Full-Text Search with MySQL

Implement MySQL full-text search with FULLTEXT INDEX, ngram parsing, and MATCH...AGAINST query patterns.

#MySQL
Exploring NewSQL Resources
Database 2023-03-29

Exploring NewSQL Resources

A summary of various resources related to NewSQL.

#NewSQL#Link Collection
Encountered 'Permission denied' Error When Starting MySQL Container on Ubuntu 20.04.2 LTS
Database 2021-09-12

Encountered 'Permission denied' Error When Starting MySQL Container on Ubuntu 20.04.2 LTS

Fix MySQL container permission denied errors on Ubuntu 20.04 by properly configuring docker-compose user UID/GID mappings.

#Ubuntu#MySQL#Tips
Cannot Start MySQL 8.0.17 Container on M1 Mac
Database 2021-09-05

Cannot Start MySQL 8.0.17 Container on M1 Mac

Fix the MySQL container startup failure on Apple M1 Mac (failed to create new OS thread errno=22). Use MySQL 8.0.26+ with --platform=linux/amd64 in the Dockerfile for ARM architecture support.

#Docker#Docker Compose#MySQL#M1#Tips
Tools for Automatically Generating DB Documents (ER Diagrams, etc.) - schemaspy, tbls
Database 2020-07-09

Tools for Automatically Generating DB Documents (ER Diagrams, etc.) - schemaspy, tbls

Exploring and reviewing open-source tools for automatically generating DB documents.

#Docker#ER
SQL for Generating Test Data in MySQL
Database 2019-07-16

SQL for Generating Test Data in MySQL

A note on generating test data using only MySQL.

#MySQL#SQL#Cross Join
Approaches to Table Design for Many-to-One Relationships with Multiple Tables
Database 2018-08-06

Approaches to Table Design for Many-to-One Relationships with Multiple Tables

Learn how to handle a table related to multiple tables in many-to-one relationships. Compares polymorphic associations (SQL anti-pattern, no FK constraints) with cross/pivot tables.

#Polymorphic#SQL Anti-pattern
Types of Relationships in ER Diagrams
Database 2018-07-31

Types of Relationships in ER Diagrams

Understand the three types of ER diagram relationships: dependent (parent-child, solid line), independent (dotted line), and many-to-many. Includes SQL table design examples for each.

#ER
MySQL JOIN vs UNION: Differences, Use Cases, and Examples
Database 2018-07-18

MySQL JOIN vs UNION: Differences, Use Cases, and Examples

Learn the difference between MySQL JOIN and UNION with practical SQL examples. Covers INNER JOIN, LEFT JOIN, FULL OUTER JOIN, and how to combine result sets correctly.

#MySQL#join#union
The N+1 Problem Explained: How to Detect and Fix It in Go/Rails
Database 2018-05-12

The N+1 Problem Explained: How to Detect and Fix It in Go/Rails

Learn what the N+1 query problem is, why it degrades application performance, how to detect it with query logs, and how to fix it with eager loading in Go and Rails.

#N+1