Bug #36047 undo for creating views/routines doesn't work as expected
Submitted: 14 Apr 2008 8:44 Modified: 13 Oct 2008 16:32
Reporter: Johannes Taxacher Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.0.18 OS:Windows
Assigned to: Sergei Tkachenko CPU Architecture:Any

[14 Apr 2008 8:44] Johannes Taxacher
Description:
when creating views and routines the entry in history (undo-name) shows "Parse MySQL View/Routine" instead of "View/routine created". When undoing such action it works but a redo after that does not.
Additionally, undoing a routine group renames the previous undo action to the undone one and the last one is deleted.

How to repeat:
case1
- new document
- add view
- switch to history pane
(there are two entries about parsing now ... parsing itself should not be in history list, imo)
- undo the last (does nothing obvious, except setting the entry in braces)
- undo the first (closes the view editor and removes the view ... and the second entry)
- redo the action ... nothin happens

case2
- new document
- add table
- add routine
- switch to history pane
- undo last action ("Parse MySQL Routine")
(now the table-create action is gone)
- undo/redo last action again (the only remaining action is "Parse MySQL Routine")
this triggers undo/redo table-create - so obviously the caption of the "Add new table object" entry has been overwritten with "Parse MySQL Routine"
[10 Sep 2008 12:52] Johannes Taxacher
his has been fixed and undo(-list) behaves as expected now for routine/view editors.
fix will go into 5.0.25
[13 Oct 2008 16:32] Tony Bedford
An entry was added to the 5.0.25 changelog:

When creating Views and Routines, the entry in the Undo History window showed “Parse MySQL View” instead of “View Created”, and “Parse MySQL Routine” instead of “Routine Created”. 

When subsequently undoing this operation the correct text was displayed. Performing a redo then resulted in the incorrect text being displayed again. 

Additionally, when undoing a Routine Group, the previous undo action in the history was incorrectly renamed and the last entry in the history was deleted.