SQLNirvana by Pyro

The SQLNirvana blog

Articles about schema

Tuning, upgrades, vacuum, indexes and security, written for teams that look after their own databases.

Allmysql 10postgresql 9upgrade 3indexes 2locks 2tuning 2vacuum 2aws 1queries 1schema 1security 1
mysqlpostgresqlschema

AUTO_INCREMENT and sequences running out: spot it before inserts fail

An INT primary key tops out at about 2.1 billion. When it runs out, every insert fails. How to check how close you are in MySQL and PostgreSQL, and how to fix it.

05 Sep 2026 · 3 min read

RSS feed