Create a test ER diagram

Click export à forwar engineer CREATE script

Start filling out the details and the page flow to create tables in the database.
Make sure you give a name to the sql file and save it . this will help in future when you want to generate alter table scrips.


After next ,

Make sure you save the file… this will be your first initial state of the database.
OR
clicking finish will create the file which was earlier specified.
Update or alter the schema
Now if you want to change some fields in the database, you can generate a alter script with the difference and execute that.
Change the from_date to from_d and till_date to till_d

Click on export à forward engineer SQl ALTER script


Select the first sql file which you created and then give a new name to the alter script and click next

Notice that it got the difference in sql files,
Now save this file somewhere else and click on execute.
This should update the database. If not , execute the SQLs directly onto the database.
After this , take a snapshot of the current latest version of your database by doing a “create a forward engineering script” and saving it as your latest version.next time you change something , you will need this to compare and get the diff of sql files for alter script.
After the process make sure you have the the tables created in DB
