Bug #17925 Foreign keys not shown in Table Editor | Foreign Keys tab panel list
Submitted: 5 Mar 2006 7:49 Modified: 31 Jul 2006 20:14
Reporter: Paul Furbacher Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Administrator Severity:S1 (Critical)
Version:1.1.3 OS:MacOS (Mac OS X 10.4.5 (intel))
Assigned to: Alfredo Kojima CPU Architecture:Any
Tags: Object Editors

[5 Mar 2006 7:49] Paul Furbacher
Description:
If I have a table for which I know at least one foreign key has been defined (e.g., can confirm by dumping db), the Foreign Keys list box in the Table Editor | Foreign Keys tab panel for that table will *not* show any foreign keys.  However, if I flip to the Indices tab in the Table Editor, I see the foreign keys in the Indices list on the left-hand side of that panel.

How to repeat:
1. Create sql (ddl) which has a table which defines a foreign key.  
2. Run that sql in the Query Browser or from the command line.
3. Open Administrator 1.1.3 on OS X.
4. Navigate to the catalog, select db.
5. Open the table editor for the table which has at least one foreign key.
6. View "Foreign Keys" tab panel.
7. See "Indices" tab for comparison.

Suggested fix:
None.
[5 Mar 2006 7:59] Paul Furbacher
indices list shows foreign keys

Attachment: mysql_indices_list.png (image/png, text), 92.48 KiB.

[5 Mar 2006 8:00] Paul Furbacher
foreign keys tab list shows no foreign keys for same table

Attachment: mysql_foreignkey_list.png (image/png, text), 104.80 KiB.

[7 Mar 2006 15:26] Paul Furbacher
I have just boosted the severity of this.  This is a killer and essentially prevents me from using this application on OS X.  And since OS X is my only development environment at the moment, it's pretty severe.  I have to do everything in DDL and import it in via either the command line or the Query Browser.
[7 Mar 2006 15:28] Paul Furbacher
Sorry, I meant to say that I boosted it to S1, the highest level of severity.
[7 Apr 2006 16:03] Richard Connamacher
I tried to use the Table Editor to add a foreign key, and it resulted in MySQL Administrator crashing on me (apparantly after sending the query to the server, since SHOW CREATE <table> shows the foreign key, though as with this bug, it's not shown in the Table Editor). Opening up the table editor for this table or switching to the foreign keys view sometimes causes a crash now.
[29 Apr 2006 3:32] Alfredo Kojima
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html
[17 Jun 2006 6:02] Richard Connamacher
It's fixed, almost.

I can't name a newly created foreign key anything other than "newfk", and I can't rename an existing foreign key either.

It seems to completely ignore whatever is entered in the "Name" field of the Foreign Key tab.
[17 Jun 2006 6:04] Richard Connamacher
(Forgot to include the version I'm running in the above comment)

I'm running MySQL Administrator 1.1.10, Mac OS X 10.4.6.
[11 Jul 2006 13:14] Jari-Matti Mäkelä
I don't know if this is somehow related but adding foreign key constraints has been broken a long time on Linux. I'm using 1.1.10 on Gentoo, but I recall that the one that comes with Ubuntu Dapper is also broken.

The problem is that there's no way to type anything to the column under the text 'Foregin Column'. The GUI lets me write everything, but pressing Enter clears all text. I've also tried to paste text from clipboard and drag'n'drop from other windows. No help. When I click 'Apply Changes', there's `(null)` in the query instead of anything I tried to write. Changing the query manually helps. This is _very_ annoying.

The cells under 'Column' kind of work - I can drag'n'drop a row from the table above to this table, but I'm unable to manually edit the cell contents.
[31 Jul 2006 20:14] Alfredo Kojima
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://www.mysql.com/doc/en/Installing_source_tree.html