HiveBrain v1.2.0
Get Started
← Back to all entries
debugsqlMinor

mysql workbench *reverse engineer* is not connecting tables graphically. How to fix?

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
engineerfixtablesworkbenchreversehowconnectingmysqlgraphicallynot

Problem

I thought that previously when I reverse engineered databases, mySql Workbench figured out the relationships from the id names and connected the tables leading to an awesome ERD, even when the foreign key constraint clauses don't exist and they are just used through the fields (xxxx_id) have the foreign key values.

However currently, when I pick various databases (I create them in rails) and try to import them I end up with this nasty looking smodge:

Instead of:

Solution

MySQL Workbench does not have the capability to "infer" the relationships from table column names, or MyISAM tables. It requires that the constraints be defined in the database or SQL script being reverse engineered.

Context

StackExchange Database Administrators Q#19725, answer score: 7

Revisions (0)

No revisions yet.