Show TOC

 Named IncludesLocate this document in the navigation structure


If an include is used to define a database table or structure, a name can be assigned to the included substructure. You can address the group of fields in the include as a whole in ABAP programs with this name.


In ABAP programs, you can either access the fields directly with <Table/structure name>-<Field name> or analogously with <Table/structure name>-<Group name>-<Field name>. You can access the fields of the group as a whole with <Table/structure name>-<Group name>.


Structure PERSON includes structure ADDRESS with the name ADR. ADDRESS has a field CITY. With PERSON-ADR you can access all the fields in structure ADDRESS. The included field CITY can also be accessed with PERSON-CITY or PERSON-ADR-CITY.

You can include a structure more than once (for example in a period group). Since direct access by field name must be permitted here, the included field names must be renamed to ensure that they are unique.

A suffix can be assigned to each group, extending the names of the group fields. The fields can then be addressed in ABAP programs with <Table/structure name>-<Field name (with suffix)> or <Table/structure name>-<Group name>-<Field name (with suffix)>.


Structure PERSON includes structure ADDRESS twice. The first address is the private address with suffix H and name ADRH. The other address is the business address with suffix W and name ADRW. You can access field CITY in the private address with PERSON-CITYH or PERSON-ADRH-CITY.

The functionality of the named includes in the ABAP Dictionary corresponds to the ABAP construction INCLUDE TYPE ... AS ... RENAMING ... .


As long as you do not assign a suffix to the components of an included structure, no renaming takes place. The assigned name can only be used for an alternative addressing of the components. Possible naming conflicts between the components of included structures are not resolved and the assigned name is not considered in statements like MOVE-CORRESPONDING or SELECT INTO CORRESPONDING . In order to achieve a real renaming, you have to assign a suffix.