I've created an EER diagram with tables, foreign keys, etc in MySQL Workbench and now I want to generate a ".sql" script that will create this database. How do I do that?
Open the MySQL Workbench as an administrator (Right-click, Run as Admin). Click on File>Create Schema to create the database schema. Enter a name for the schema and click Apply. In the Apply SQL Script to Database window, click Apply to run the SQL command that creates the schema.
Create a SQL Database Diagram Use either of the following options: On the File menu, select New and then click Database Diagram. On the Database menu, click Database Diagram. On the Start Page > Database Design dashboard, click New Database Diagram.
Try: File->Export->Forward Engineer SQL CREATE Script
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With