Creating Fields in the Table

In the initial screen of the ABAP Dictionary, enter a table name, select object class Tables and choose Create. The field maintenance screen for the table appears, where you must make the following entries:

  1. Enter an explanatory short text in the field Short text.
  2. Define a delivery class for the table.
  3. Proceed as follows for each field to select the fields of the table:

  4. Enter a name for the table field in the column Field name.
  5. You can also

    · include existing fields from a substructure (see Including Substructures)

    · copy fields from another table (see Copying Fields from Another Table) or

    · copy fields from an entity type (see Copying Fields from an Entity Type).

  6. Select the Key column if the field should be part of the table key.
  7. Note that all the key fields of a table must be stored together at the beginning of the table. A non-key field may not occur between two key fields.

    A maximum of 16 key fields per table is permitted.

  8. Enter the data element to which the field refers in the Data element field.
  9. If there is no suitable data element, you can go to the data element maintenance routine by entering a name and double-clicking on it.

    You can enter the data type, field length and short description directly with Edit ® Direct type entry. If you want to enter data elements for further fields, you can return to the standard maintenance routine with Edit ® Reference data elem.

    You must define the number of decimal places of the field for fields with data type Dec. You can do this by double-clicking on the field name, upon which you will go to the detailed display of the field attributes. You can make the required entry in the Decimal places field.

    Only a limited functionality is provided for fields without data elements. No foreign keys or fixed values may be defined for such fields and there is no F1 help.

  10. You must specify the Reference Field and Reference Table for fields of type QUAN (quantity) and CURR (currency amount).
  11. You can make these entries by pressing the >| key (at the lower edge of the screen). Fields RefTab, RefField and Initial are faded in. Enter the reference table in field RefTab and the reference field in field RefField. Alternatively you can go to the field attribute by double-clicking on the field name and make the necessary entries there.

  12. You can assign a search help (see Search Helps) to a table field by positioning the cursor on this field and choosing Goto ® Search help for field.
  13. A dialog box appears in which you must enter the search help name and choose Continue. The system automatically makes a proposal for the assignment of the search help parameters to the table fields. It attempts to assign a table field with the same domain to a search help parameter. If there is no such field, the assignment is open.

    You can change the system proposal (except for the search field, that is the field to which the search help was assigned) by assigning a table field with the same data type and field length to a search help parameter.

  14. Save your entries after defining all the fields of the table. You will be requested to assign a development class to the table.

Optional Settings

This flag defines whether or not maintenance of the table entries is allowed with System ® Utilities ® Table maintenance. Table maintenance should not be allowed for example for tables which are automatically filled by system or application programs.

You can assign a search help to the table. This search help is then proposed for all the screen fields which are checked against the table.

Choose Search help for table. A dialog box appears in which you must enter the name of the search help. You must also assign the search help parameters to table fields here. Proceed as when assigning a search help to a table field.

The Activation Type defines whether the table can be activated directly from the ABAP Dictionary or whether the runtime object of the table must first be generated with a C program.

Choose Extras ® Activation type. A dialog box appears in which you can enter the required activation type.

If you want to assign a data element or a domain of type LRAW or LCHR to a field, you must insert a field of type INT2 in front of this field. The database interface can enter the actual length of the field here. Fields of type LRAW or LCHR must be stored at the end of the table. Only one such field is allowed per table.

You can define a table as client-dependent by assigning a domain of data type CLNT to the first field of the table.

The maximum length of the key of a table is 251 less the number of key fields of the table. The maximum key length allowed is therefore 240 places for a table with 11 key fields. If the key length is greater than 120, there are restrictions when transporting table entries. The key can only be specified up to a maximum of 120 places in a transport. If the key is larger than 120, table entries must be transported generically.

See also:

Tables

Moving Fields

Search Helps

Linking a Search Help with a Screen Field