Re:We’re Fucked, It’s Over: Coming Back from the Brink
by salvadors on Wednesday March 26, 2014 @03:05AM
(#7472026)
We persuaded mySQL to add the --i-am-a-dummy (http://sql-info.de/mysql/notes/I-am-a-dummy.html) option after about the third time one of our developers did this.
Re:We’re Fucked, It’s Over: Coming Back from the Brink
by cousin_it on Tuesday March 25, 2014 @04:27PM
(#7468715)
I never really understood why databases don't have undo.
Re:We’re Fucked, It’s Over: Coming Back from the Brink
by specialist on Tuesday March 25, 2014 @05:27PM
(#7469079)
I largely avoid UPDATE and DELETE statements. Changes are new rows, time ordered, which supersede prior rows. Like an audit log.
Works great. Especially for anything that needs history, e.g. medical data.
Re:We’re Fucked, It’s Over: Coming Back from the Brink
by brongondwana on Tuesday March 25, 2014 @10:25PM
(#7471153)
Wrote one of those many years ago, yes - for medical data. It's the right solution to just about every problem actually, and I'm surprised that it isn't more commonly taught.
Re:We’re Fucked, It’s Over: Coming Back from the Brink
by GFischer on Wednesday March 26, 2014 @11:31AM
(#7474065)
Yeah, logical deletes ftw :) .
One thing I haven't figured out is how to archive old records, I think it's not a problem for modern DBMSs, but we have a problem at work with 15 years' worth of historical data.
The issue was that my manager never caught it in my migration file and it went live.
I was lucky that we backed up every day..and didn't really lose a ton of data.