Hi,
Before Script Tab - Whatever you write into the Before Script section, it will be generated before the Entity definition.
After Script Tab - Whatever you write into the After Script section, it will be generated after the Entity definition.
Ok, I tried using it and examining the generated script. There was a problem though with the order of things. The table gets created, then my after script was inserted, and towards the end of the script the triggers were created. The after script needs to be executed after the triggers and not before.
I thought maybe the the “order” option in the generate dialog would assist me, but there was no option to change things the way I needed.
I just wrote another script and keep it seperate from the one TDM generates, which works for now. I should probably keep the insertion of data seperate from ddl anyway.
The after script needs to be executed after the triggers and not before.
In this case, you can use the After Script section in Model Properties (Model menu).
After Script of tables will be always generated right after tables.
OR
You can use our user package "Extra Objects - DDL Script Generation" where you can define an Extra Object and SQL code that you want to generate. Then you can set where you want to generate the Extra Object - via the option Order of Generated Objects (Model menu).