Character-Type and Numeric-Type Operands Locate the document in its SAP Library structure

Up to now, you have been able to use flat structures as arguments of ABAP statements wherever single fields of type C were expected. In a UP this is no longer generally permitted. In a UP, you can use a structured field in a statement expecting a single field only if this structured field consists of character-type elementary types or purely character-type substructures. The structure is treated like a single field of type C.

The main restrictions applying to a UP in contrast to an NUS result from the fact that flat structures are only considered character-type on a limited basis, and fields of type X or STRING are never considered character-type. In addition, flat structures are only considered numeric-type if they are purely character-type. Numeric-type arguments include, for example, offset or index specifications as in READ TABLE ... INDEX i. The following examples show a structure that is character-type and a structure that is not:

Non-character-type:

BEGIN OF struc1,
  a(2) TYPE C,
  b(2) TYPE C,
  x(1) TYPE X,
  i    TYPE I,
END OF struc.

Non-character-type:

BEGIN OF struc2,
  a(2) TYPE C,
  n(6) TYPE N,
  d    TYPE D,
  t    TYPE T,
END OF struc.

Another example is a control break in an internal table, triggered by the AT keyword. In a NUS, fields of type X to the right of the control key are treated as character-type, and are thus filled with an asterisk. In Unicode systems, conversely, the same type is filled with its initial value.

 

Note Use the categories used in the Dictionary when using these types with Structure Enhancements.

Leaving content frame