Message type: E = Error
Message class: DT - Table activation (incl. indexes)
Message number: 277
Message text: Structure with '-' in field name cannot contain a structured type
According to the SAP naming convention, the character '-' is not
allowed within an object name. Existing fields that already contain
this character are accepted nevertheless.
With the introduction of type definitions in the ABAP Dictionary, the
use of '-' in field names can result in ambiguities. Example:
X and Y are structures:
X Fields Type Y Fields Type
B Y C DTEL3
B-C DTEL1 E DTEL4
D DTEL2
X-B-C is ambiguous. It can be either the field B-C of structure X or
component C of structure B of X.
Structures with '-' in field names can only be accessed in ABAP
programs with LIKE, but not with TYPE. Structures in which fields also
contain structures as type cannot be used only with TYPE.
You therefore cannot use a new field with structured type in this
structure.
Do not use the field(s) with structured type or replace the fields
containing '-' with fields without this character.
Error message extract from SAP system. Copyright SAP SE.
DT277
- Structure with '-' in field name cannot contain a structured type ?The SAP error message DT277 indicates that there is an issue with the naming convention of a field in a structure. Specifically, it states that a structure cannot contain a field name that includes a hyphen ('-'). This is a restriction in SAP's data dictionary, as hyphens are not allowed in field names.
Cause: The error occurs when you attempt to define a structure in the ABAP Dictionary (SE11) or when you are working with data types that include field names with hyphens. This can happen during the creation of a new structure or when modifying an existing one.
Solution: To resolve this error, you need to rename the field that contains the hyphen. Here are the steps you can follow: Identify the Structure: Determine which structure is causing the error. This can usually be found in the error message details or by checking the code where the structure is being used. Modify the Field Name: Go
Get instant SAP help. Sign up for our Free Essentials Plan.
DT276
Field name &: define a namespace between '/'
What causes this issue? In a field name you used the namespace identifier '/*/', but did not insert a namespace between these characters.Ho...
DT275
Field name & may not only consist of a namespace prefix
What causes this issue? You used a field name that only contains a namespace prefix. This is not allowed.How to fix this error? Add further characte...
DT278
Only use types whose component fields do not contain '-'
What causes this issue? According to the SAP naming convention, the character '-' is not allowed within an object name. Existing fields con...
DT279
Field &: Reference & to class w/o interface cannot be used in DB table &
What causes this issue? In the definition for a database table, you used a reference to a class or an interface. This is not possible because the dat...
Click on this link to search all SAP messages.