MySQL Forums
Forum List  »  MySQL Workbench

Forward SQL CREATE script from Command line
Posted by: David Sarrio
Date: April 30, 2013 08:11AM

Hi,

I want to export my model as a create script with drop statements and its visual representation as a png file.
I've found how to export a png from command line but not for sql create script.
So far i managed to get a basic export using:

options = {}
DbMySQLFE.generateSQLCreateStatements(_catalog, grt.root.wb.info.version, options)
DbMySQLFE.createScriptForCatalogObjects("/tmp/script.sql", _catalog, options)

or

print DbMySQL.generateSQLForDifferences(None, grt.root.wb.doc.physicalModels[0].catalog, {})

but i was unable to find how to set options. It seems that there is options like GenerateDrops, GenerateSchemaDrops, etc. but i can't get them to work.


Would be nice if someone can help me a bit with that,

Thank you.

Options: ReplyQuote


Subject
Views
Written By
Posted
Forward SQL CREATE script from Command line
1509
April 30, 2013 08:11AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.