Copy column definitions for a table

Copying column definitions from an existing table to a new table can save you time when you are creating tables that contain similar data. You can also copy column definitions to an existing table. To copy column definitions:

  1. In the System i Navigator window, expand the system you want to use.
  2. Expand Databases.
  3. Expand the database and schema that you want to work with.
  4. To copy column definitions to a new table, right-click the Tables container and select New.
  5. To copy column definitions to an existing table, click the Tables container, then right-click the table and select Definition.
  6. On the Table Definition dialog, to copy column definitions, click Browse.
  7. To see a list of tables, expand the schema you want in the tree view on the Browse Tables dialog.
  8. Click on the table you want. The list of columns in that table will be listed, along with their data type, size, and description.
  9. Click the columns you want to copy to the new table.
  10. When you have selected all the columns you want to copy from that table, click OK to copy them and close this dialog, or click Apply to copy the columns without closing this dialog.