Copyright 2020 - BV TallVision IT

In many cases the system holds possible values for a certain field, which can be set on the domain of the field. Linked to a check table or linked to Domain values Have a look at domain EBSTYP as an example, this is the domain behind EKKO-BSTYP, a single character field which holds the type of purchasing document. SAP only supports a predefined set of values for this field, making the way to store short descriptions with the possible field values very suitable for domain values. Go to transaction SE11 and fill in EBSTYP for the field Domain. On the tab Value range the possible values are listed, or (potentially) a check table is displayed.


So how to get domain values ? Use function module GET_DOMAIN_VALUES or HELP_VALUES_GET_WITH_TABLE.

For example, you want to fetch the description of an address type for an Idoc:

data: lt_DD07V type STANDARD TABLE OF DD07V,
      lw_DD07V type DD07V.

* What text goes with address type "2" ?
    DOMNAME               = 'EDI_ADRTYP'
    VALUES_TAB            = lt_DD07V
    OTHERS                = 0.

read table lt_DD07V into lw_DD07V
  with key domvalue_l = '2'. 
* lw_DD07V-ddtext will hold "Natural person"