tags:

views:

2153

answers:

2

I have a database model diagram created in MS Visio which I would like to export to DDL file to create a MySQL database. I've already installed the MySQL ODBC driver, which I can successfully use to generate DDL file, but I have some problems anyway.

Visio puts quotation marks around the table names which are also reserved words (like user). This is not OK, since MySQL uses backticks (`) and not quotation marks (") for this purpose.

MySQL ODBC driver also changes the BLOB data type to LONGVARBINARY, so it cannot be used directly with MySQL when creating the database.

Does anyone have any suggestion how to deal with these two problems?

A: 

BTW, here is a service creating MySQL DDL from Visio diagrams: http://aboutwhatever.net/posts/visio-2007-database-model-ddl-generation/

Maybe it will help you.

StarWind Software
+2  A: 

Other than editing it? No.

You might consider using MySQL Workbench. It is very similar to visio if you create everything in design mode. Additionally, with the paid version you can generate a pdf document as well for distribution (or plop that PDF into the flow chart diagrams, etc in visio) or you could possibly create a plugin that would generate a valid visio file on output since workbench is fully extensible via plugins.

Kevin Peno
That's what I did in the end.
aks