Bug #49441 Creating foreign key, receive "external component has thrown an exception."
Submitted: 4 Dec 2009 1:30 Modified: 5 Dec 2009 1:43
Reporter: Charlie Brensinger Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.1.18 OS:Windows (Vista 64)
Assigned to: CPU Architecture:Any

[4 Dec 2009 1:30] Charlie Brensinger
Description:
************** Exception Text **************
System.Runtime.InteropServices.SEHException: External component has thrown an exception.
   at bec.FKConstraintColumnsListBE.get_column_is_fk(FKConstraintColumnsListBE* , NodeId* )
   at MySQL.Grt.Db.FKConstraintColumnsListBE.get_column_is_fk(NodeId node)
   at MySQL.GUI.Workbench.Plugins.DbMysqlTableFkColumnListModel.columnEnabledFkNodeControl_CheckStateChanged(Object sender, TreePathEventArgs e)
   at System.EventHandler`1.Invoke(Object sender, TEventArgs e)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.OnCheckStateChanged(TreePathEventArgs args)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.OnCheckStateChanged(TreeNodeAdv node)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.SetCheckState(TreeNodeAdv node, CheckState value)
   at Aga.Controls.Tree.NodeControls.NodeCheckBox.MouseDown(TreeNodeAdvMouseEventArgs args)
   at Aga.Controls.Tree.TreeViewAdv.OnMouseDown(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

************** Loaded Assemblies **************
mscorlib
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4200 (NetFxQFE.050727-4200)
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
MySQLWorkbench
    Assembly Version: 5.1.18.4456
    Win32 Version: 5.1.18.4456
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/MySQLWorkbench.exe
----------------------------------------
wbprivate.wr
    Assembly Version: 0.0.0.0
    Win32 Version: 
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/wbprivate.wr.DLL
----------------------------------------
wbpublic.wr
    Assembly Version: 0.0.0.0
    Win32 Version: 
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/wbpublic.wr.DLL
----------------------------------------
System.Windows.Forms
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4016 (NetFxQFE.050727-4000)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4016 (NetFxQFE.050727-4000)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4016 (NetFxQFE.050727-4000)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
MySQLCsUtilities
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/MySQLCsUtilities.DLL
----------------------------------------
msvcm90
    Assembly Version: 9.0.21022.8
    Win32 Version: 9.00.21022.8
    CodeBase: file:///C:/Windows/WinSxS/x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.21022.8_none_bcb86ed6ac711f91/msvcm90.dll
----------------------------------------
MySQLGrtShell
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/MySQLGrtShell.EXE
----------------------------------------
WeifenLuo.WinFormsUI.Docking
    Assembly Version: 2.2.3534.11304
    Win32 Version: 2.2.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/WeifenLuo.WinFormsUI.Docking.DLL
----------------------------------------
WbPlugins
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/WbPlugins.DLL
----------------------------------------
Aga.Controls
    Assembly Version: 1.6.0.0
    Win32 Version: 1.6.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/Aga.Controls.DLL
----------------------------------------
grt.db.fe
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/grt.db.fe.DLL
----------------------------------------
grt.helpers.be
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/grt.helpers.be.DLL
----------------------------------------
db.mysql.editors.wbp.fe
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/db.mysql.editors.wbp.fe.DLL
----------------------------------------
db.mysql.editors.wbp.wr
    Assembly Version: 0.0.0.0
    Win32 Version: 
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/db.mysql.editors.wbp.wr.DLL
----------------------------------------
sqlide.fe
    Assembly Version: 0.0.0.0
    Win32 Version: 0.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/sqlide.fe.DLL
----------------------------------------
ScintillaNet
    Assembly Version: 2.0.3534.11496
    Win32 Version: 2.0.0.0
    CodeBase: file:///F:/MySQL/MySQL%20Workbench%205.1%20OSS/ScintillaNet.DLL
----------------------------------------
System.Xml
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.4016 (NetFxQFE.050727-4000)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------

How to repeat:
Within EER Diagram:
Attempting to create foreign key referencing the primary key of one table, for a NOT NULL column in the new table. Happens after: (1) Reference table is selected [no errors] (2) Column is selected [error on all columns except the PRIMARY KEY columns for this table].

Suggested fix:
I couldn't tell you. Sorry ;)
[4 Dec 2009 14:02] MySQL Verification Team
Thank you for the bug report. I couldn't repeat using your test case project and instructions, please check if is necessary another detail (step) for. Thanks in advance.
[4 Dec 2009 18:11] Charlie Brensinger
My apologies. Upon review, it is not giving me errors at this stage. I think it's safe to assume that it was some background process I was running which interfered, as restarting the program had not fixed it but restarting the computer certainly did. Simply a conflict on my end, I suppose.

Thank you very much.
[5 Dec 2009 1:43] MySQL Verification Team
Thank you for the feedback. Changing status to can't repeat.
[5 Dec 2009 1:43] MySQL Verification Team
Thank you for the feedback. Changing status to can't repeat.