Insert a column

You can insert columns into a new or existing table.

  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 add a column to a new table, right-click Tables and select New.
  5. To add a column to an existing table, click Tables, then right-click the table and select Definition.
  6. On the Table Definition dialog, select the Columns tab.
  7. Click Add.
  8. In the Column definition dialog, specify a name for the column.
  9. Specify a short column name in the Short column name field. If no name is selected, the system automatically generates a name.
  10. To select a type for the column, click the type currently listed, click the down arrow and select a type from the list provided.
  11. Specify a length for the column. For data types where the size is predetermined, the size is filled in and you cannot change the value.
  12. Specify a description for the column in the Text field. This step is optional.
  13. Specify a heading for the column. The heading is the name that will appear on top of the column when displaying or printing. You are limited to 60 characters, 20 per line.
  14. Select Nullable to allow the column to contain null values.
  15. Specify a default value.
  16. Click OK to close the Table definition dialog and to insert the new column.
Note: You can copy column definitions from other tables.