Method 2: Using schemaSpy
This method produces a *much* more refined, and detailed multipage HTML Schema than SQL::Translator does, plus it is multiplatform, being Java based.
Homepage:
http://schemaspy.sourceforge.net/
Install the following on Debian Linux, other platforms will have similar programs.
• schemaSpy_5.0.0.jar (248.9 kB) from
http://sourceforge.net/projects/schemaspy/
• Java 5 or higher
http://www.java.com/en/download/manual.jsp?locale=en, I used jre-6u30-linux-i586.bin
• apt-get install libmysql-java
Run the following command line string to produce the Schema in a directory of files for browser viewing. Note the Mysql database may be on another Host:-
# deb505:/usr/local/src# /usr/local/jre1.6.0_30/bin/java -jar ./schemaSpy_5.0.0.jar -t mysql -host localhost -db <mysql database name> -u <your mysql user> -p <password> -dp /usr/share/java/mysql-connector-java-5.1.6.jar -o /<directory for the Schema web files>
Using database properties:
[./schemaSpy_5.0.0.jar]/net/sourceforge/schemaspy/dbTypes/mysql.properties
Gathering schema details.............................................................................................................................(3sec)
Writing/graphing summary..............(16sec)
Writing/diagramming details..........................................................................................................................(110sec)
Wrote relationship details of 122 tables/views to directory '/var/www/weberpschema' in 130 seconds.
View the results by opening /var/www/weberpschema/index.html
You can view the very detailed output here, note my database name used in this Schema is "tjporter":-
http://www.portertech.org/test/webERP/we...index.html
Cheers
Terry