Bug #55861 Unhandled Exception: Invalid node index after droping schema in SQL Editor
Submitted: 9 Aug 2010 21:19 Modified: 8 Sep 2010 15:44
Reporter: Matthew Hall Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:5.2.26 OS:MacOS (10.6.4)
Assigned to: Alfredo Kojima CPU Architecture:Any
Tags: drop schema, invalid node index, Unhandled exception

[9 Aug 2010 21:19] Matthew Hall
Description:
MySQL Workbench SQL Editor exhibits strange behavior after dropping schema.  Rather than refreshing the list of available schema, the schema that was dropped remains as a list entry, but with the name of the schema after it in the list.  Upon refreshing the list of available schema, an "Unhandled Exception" reading "An unhandled exception has occurred: Invalid node index" is thrown.

How to repeat:
This reproduces for me every single time:

1. Connect SQL editor to a MySQL server instance with more than one database.
2. In the list of available schema, select then right-click one somewhere in the middle of the list.
3. Select "Drop schema..." and confirm.
4. After being notified of the successful execution of the drop statement, inspect the list of available schema.  You should see that in the place of the schema you have dropped is now an entry that looks to be a duplicate of the one after the schema you dropped.
5. Right-click in the list of available schema and select "Refresh All".  The exception listed in the description is thrown and presented in a message dialog.
[23 Aug 2010 17:23] Alfredo Kojima
fixed
[26 Aug 2010 8:59] Johannes Taxacher
fix confirmed in repository
[8 Sep 2010 15:44] Tony Bedford
An entry has been added to the 5.2.27 changelog:

After dropping a schema from the list in the Object Browser, the schema that was dropped remained, but with the name of the schema that came after it. When the list of available schemata was refreshed, an unhandled exception was generated:

An unhandled exception has occurred:
Invalid node index