Select multiple entities on the diagram, right click on one of them and select Generate SQL... from the pop-up menu.
| Generate SQL |
The Generate SQL dialog box shows the DDL and DML for the selected entities.
![]() |
| Generate SQL dialog box |
DDL stand for Data Definition Language, include create, drop and alter statements. DML stand for Data Manipulating Lanauge, include select, insert, update, delete statements.
The generated DDL statements can directly execute to database without any modification. Generate alter statement require connection to database, query the object from database and compare with the ERD. The alter statements are not generated by default, you can click the Generate button to generate on demand.
![]() |
| Generate alter statements |
The generate DML is a template for select, insert, update, delete statements, you are required to modify the statement before execute.
Click the Database Configuration button to open the database configuration dialog.
![]() |
| Database configuration |
If you selected multiple database, you can select one of the database from the database combo box.
After change the database, the SQL will re-generate for the selected database.
![]() |
| SQL updated |
There are several option on the top of the Generate SQL dialog box.
![]() |
| Generate SQL options |
![]() |
| Delimiter |
![]() |
| Upper SQL |
![]() |
| Formatted SQL |
There is a toolbar above each group of statements.
| Generate SQL toolbar |