Content Deep Dive
Generated hash columns in MySQL
Blog post from PlanetScale
Post Details
Company
Date Published
Author
Aaron Francis
Word Count
2,423
Language
English
Hacker News Points
5
Summary
The text discusses generating hash columns in MySQL for faster strict equality lookups. It explains how generated columns work and provides examples of using them to create compact indexes that are faster than wide indexes. The article also covers hashing multiple columns into one, using a composite hash, and storing the values as binary strings to improve efficiency. Additionally, it introduces functional indexes in MySQL 8.0.13, which allow for creating an index on the result of a function without using a generated column. The goal is to provide a more efficient way to perform strict equality lookups and enforce uniqueness across multiple columns.