Indexing an expression required adding a generated column and indexing that, which means a schema change and a column nobody wants in a SELECT *. The double parentheses…
Checking whether a key exists and then inserting it is two statements, and two requests can both pass the check before either inserts. The unique index is what…
A repository test against a mocked connection asserts that the code calls the methods you expected, which is a restatement of the code rather than a check on…
A report asking for the top quartile of customers by spend was a subquery computing a count, a second computing a threshold, and arithmetic in PHP. NTILE divides…
A five-year-old project has two hundred migrations, and every test run and every fresh install replays all of them in order. Forty seconds off every test run is…
Almost every MySQL tuning guide lists forty variables, and on a dedicated server the first one accounts for most of the difference. The rule of thumb is 60-70%…
Integration tests need a real database, and a hosted runner is an empty machine — which is the problem service containers exist for. The health options are not…