mysql> update tablename set fieldname = 'C200900674' where fieldname - 'C200900673';
ERROR 1062 (23000): Duplicate entry 'C200900674-2008-0-1' for key 1
Any thoughts or suggestions on this? We had someone accidentally do that update with a minus sign instead of an equal sign. It apparently tried to change all records less than that value? Even though it's alphanumeric and really fairly incomplete. On top of that, a quantity of records were updated before it got that error and there was no feedback at all. Nothing like "Query OK, X rows affected (0.00 sec)" so we had no idea how many were changed. autocommit=1 so no ability to rollback.
Anyway, just looking for any tips or pointers on this. Why that query did anything at all, it really looks like it should have returned an error to me. Other than the obvious answer of not letting inexperienced admins do boneheaded things of course.
Thanks