Bug #63636 Object reference not set to an instance of an object
Submitted: 6 Dec 2011 22:22 Modified: 13 Jan 2012 17:17
Reporter: Paul Melhuish Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Workbench: Modeling Severity:S2 (Serious)
Version:5.2.36 CE OS:Windows (7)
Assigned to: CPU Architecture:Any

[6 Dec 2011 22:22] Paul Melhuish
Description:
Sorry I'm new to MySQL Workbench and just working my way into it. i've just been trying to do my first project on it and it keeps popping up a message saying "Object reference not set to an instance of an object" and asking me to submit a bug report.

At the same time (presumably connected) I am unable to get one instance of a foreign key to work properly. I have two tables both with a row called hid which should be a foreign key of hid in a third table (where hid is the primary key). In the Foreign Key tab of the table editor, I can put hid in the first column and select the name of the table in the second column. The third column has a column of checkboxes corresponding to all the rows in the "third" table but it is impossible to tick any of them. The fourth column has an empty dropdown menu.

If I ignore the problem in the para above and then try to forward engineer the schema, the SQL runs OK until it gets to the line corresponding to the problematic foreign key, when it throws a mySQL syntax error. The lines it objects to is:
   FOREIGN KEY ()
   REFERENCES `lithot_extranet2`.`ex_hotel` ()
As I understand it, the brackets should contain the name of the foreign key ("hid").

How to repeat:
How to repeat?

Just keep trying to do what I've been trying to do, and it happens every time. Obviously there is a bit more to it because I have other foreign keys working successfully, but I've no idea what. I've got about five hours experience on this programme. Hopefully you have a bit more than that.
[13 Dec 2011 17:17] Valeriy Kravchuk
Please, upload .mwb file that demonstrates the problem and detailed instructions on how to repeat it.
[14 Jan 2012 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".