#28 Add option to link tables by indexed columns


Similar to the earlier request for ruby-on-rails
implied relations - add an option that causes
schemaspy to map relationships for 'utility' tables
when a column name in one table matches to any other
tables with indexed columns with the same name. So
only link if the column names, type, and size are the
same and the column being linked to has an index.
Might be nice to be able to supply a regex with the
option that tells it which tables to do this for -
with the default being all tables.

Example - adding the -link option would trigger this
for all tables, using -link "(invoice.*)|(order.*)"
would only link the tables that start with invoice or


  • John Currier

    John Currier - 2006-11-21

    Logged In: YES
    Originator: NO

    If I'm reading this correctly then the only change in current behavior is from "primary keys" to "indexed columns", right? I'm not sure what implications this will have though as I believe that I start with primary keys when trying to determine child table relationships. I'll look into it.


  • John Currier

    John Currier - 2006-11-21
    • assigned_to: nobody --> johncurrier
  • Nobody/Anonymous

    I was thinking that using the proposed new option -link would be an addition to what schemaspy already does. So do the existing primary key link always, but if the -link option is used, then also show indexed column linkages. The original request mentioned 'utility tables', but the new feature should be done for all tables.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks