Junior dev's code worked in tests, deleted data in prod
Briefly

Reggie, working on accounting systems, was assigned to zero out a database field. After testing his script, he ran it on production, unintentionally erasing 1,500 employees' insurance records. His mistake was due to a lack of guidance on the database structure. Meanwhile, Sam observed a colleague attempting to delete test records from a large database using a simple command, only to find it took longer than expected. The incident illustrates the complexities and potential pitfalls of database management in the workplace.
"One day, Reggie's boss assigned him to another team that needed someone to zero out a database field in a sub-record used to store important information about employees' insurance."
"Quicker than you can say 'WTF?!?' my phone started ringing. I had accidentally erased about 1,500 employees' private insurance records."
"Removing the records therefore looked easy. Mike suggested the following syntax: DELETE FROM bigtable WHERE secretfield = 1;"
"I watched as my code ran on production systems. It turned out the sub-record was actually a multi-type, and I was only supposed to update that field if it was the right type."
Read at Theregister
[
|
]