Databases 5 min read

Why a 20‑Year‑Old MySQL Bug Still Threatens Data Integrity

A two‑decade‑old MySQL bug (bug 11472) that prevents triggers from firing on cascading foreign‑key updates has remained unfixed, sparking community frustration, debates over ACID compliance, and a shift toward alternatives like PostgreSQL in modern applications.

21CTO
21CTO
21CTO
Why a 20‑Year‑Old MySQL Bug Still Threatens Data Integrity

In June 2005 a MySQL defect rated S2 (severe) remained unresolved for over 20 years, causing disappointment in the open‑source database community.

The bug, identified as bug 11472 , is described as “foreign key update/delete does not fire triggers”. Triggers are code blocks that automatically execute on insert, update, or delete operations to maintain data integrity. This flaw means that indirect updates to a table will not activate the associated triggers.

Although the MySQL team publicly labeled the issue a “known problem” and promised a fix in version 5.1, the fix never materialized. The manual records the bug as “cascading foreign‑key operations do not activate triggers”.

Developers have warned that the bug “seriously threatens ACID principles / data integrity”. In 2015 a contributor reported encountering the issue while trying to execute triggers on cascade delete and urgently needed a solution. ACID stands for atomicity, consistency, isolation, and durability.

In 2020 a young developer remarked, “this bug is older than me.”

The impact of the bug is far‑reaching. In 2023 another developer said they stopped using MySQL because the bug was the final straw, noting the need for an uncustomized platform to ensure data integrity.

MySQL was acquired by Oracle in 2010 as part of Sun Microsystems. Although the bug predates the acquisition, many view Oracle as neglecting community needs. Some argue that leaving a known defect unfixed can be safer to prevent applications from relying on it, but this reasoning does not hold in this case.

When Oracle acquired MySQL, its fork MariaDB also marked the bug as “unresolved”.

Reddit discussions have debated whether using triggers for database integrity is best practice. Some respondents suggest avoiding MySQL altogether and choosing a more suitable relational database, with PostgreSQL being the most common alternative. Others jokingly call the bug a “feature”.

According to the DB‑Engines ranking, MySQL remains the second‑most widely used database worldwide after Oracle and before Microsoft SQL Server. However, its popularity is declining while PostgreSQL’s is rising. The ranking is based on community mentions and job demand rather than actual usage, yet it signals a downturn for MySQL.

Last year Percona expert Peter Zaitsev, who has worked in the MySQL field for many years, said, “For years MySQL seems to have suffered neglect in the performance engineering department,” and noted that Oracle reserves important new features for its cloud‑only Heatwave service, deliberately marginalizing the open‑source edition.

Editor: 行动的大雄 Reference: https://devclass.com/2025/06/24/serious-mysql-bug-celebrates-20-years-unfixed-another-reason-to-switch-to-postgresql/
Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

mysqlPostgreSQLACIDTriggersDatabase Bug
21CTO
Written by

21CTO

21CTO (21CTO.com) offers developers community, training, and services, making it your go‑to learning and service platform.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.