In case you renamed a column and do not want to spend too much time by comparing your model with your database, going through the Sync & Convert Wizard etc., take advantage of simple macro that will prepare Alter table xxx rename column command for you (Oracle models only).
Instructions:
- Download macro FastColumnRename from our library.
- Import it to Toad Data Modeler
Here you can find an article about how to import custom packages to Toad Data Modeler.
- Open your model and in Model Explorer right click any attribute and choose Macros -> Column Rename
- New dialog opens. Specify new column name. Alter table command will change automatically. Click Execute to rename column in your model and then click Close to close the dialog.
Notes: When you click Execute, the column name will be renamed in your model. Toad Data Modeler will update all related information automatically (indexes, columns in child tables in case the column is a part of alternate key or primary key etc.). On Toad Data Modeler side the operation is safe. But in case the column really is a part of index or alternate key, for example, you will need more complex alter scripts – and in this situation the Sync & Convert Wizard should be used.
Of course, feel free to modify or improve the script. In case you work with another database system you may need different commands.
Good luck,
Vaclav
Start the discussion at forums.toadworld.com