Generate SQL for objects

Start of changeThe Generate SQL function allows you to reconstruct the SQL used to create existing database objects. This process is often referred to as reverse engineering. You can generate SQL for most database objects. Additionally, if you generate SQL for a table that has constraints or triggers associated with it, the SQL will be generated for those as well. You can generate the SQL for one object or many at a time. You also have the option of sending the generated SQL to the Run SQL Scripts window for running or editing, or you can write the generated SQL directly to a database or PC file.

To generate SQL for an object, right-click the object and select Generate SQL.

Start of changeYou can also start the Generate SQL interface from Run SQL Scripts by selecting Insert Generated SQL from the Edit menu.End of change

End of change