SAP Function Modules

DMC_ACS_GET_RANGES SAP Function module







DMC_ACS_GET_RANGES is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name DMC_ACS_GET_RANGES into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: CNV2
Released Date: Not Released
Processing type: Remote-Enabled
remote enabled module settings


Pattern for FM DMC_ACS_GET_RANGES - DMC ACS GET RANGES





CALL FUNCTION 'DMC_ACS_GET_RANGES' "
  EXPORTING
    im_tabname =                " dd03l-tabname
    im_depth =                  " dmc_types-int4
*   im_blocksize =              " dmc_types-int4
*   im_count = SPACE            " dmc_types-boolean
*   im_sel_field = 'MANDT'      " dmcwhere-line
    im_client_spec =            " dmc_types-boolean
  TABLES
    im_it_keydef =              " dmckeydef
    im_it_settings =            " dmcstg
    ex_it_ranges =              " dmcrange
  EXCEPTIONS
    GET_TABLE_INFO_FAILED = 1   "
    .  "  DMC_ACS_GET_RANGES

ABAP code example for Function Module DMC_ACS_GET_RANGES





The ABAP code below is a full code listing to execute function module DMC_ACS_GET_RANGES including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
it_im_it_keydef  TYPE STANDARD TABLE OF DMCKEYDEF,"TABLES PARAM
wa_im_it_keydef  LIKE LINE OF it_im_it_keydef ,
it_im_it_settings  TYPE STANDARD TABLE OF DMCSTG,"TABLES PARAM
wa_im_it_settings  LIKE LINE OF it_im_it_settings ,
it_ex_it_ranges  TYPE STANDARD TABLE OF DMCRANGE,"TABLES PARAM
wa_ex_it_ranges  LIKE LINE OF it_ex_it_ranges .


SELECT single TABNAME
FROM DD03L
INTO @DATA(ld_im_tabname).


DATA(ld_im_depth) = 123

DATA(ld_im_blocksize) = 123

DATA(ld_im_count) = some text here

DATA(ld_im_sel_field) = Check type of data required

DATA(ld_im_client_spec) = some text here

"populate fields of struture and append to itab
append wa_im_it_keydef to it_im_it_keydef.

"populate fields of struture and append to itab
append wa_im_it_settings to it_im_it_settings.

"populate fields of struture and append to itab
append wa_ex_it_ranges to it_ex_it_ranges. . CALL FUNCTION 'DMC_ACS_GET_RANGES' EXPORTING im_tabname = ld_im_tabname im_depth = ld_im_depth * im_blocksize = ld_im_blocksize * im_count = ld_im_count * im_sel_field = ld_im_sel_field im_client_spec = ld_im_client_spec TABLES im_it_keydef = it_im_it_keydef im_it_settings = it_im_it_settings ex_it_ranges = it_ex_it_ranges EXCEPTIONS GET_TABLE_INFO_FAILED = 1 . " DMC_ACS_GET_RANGES
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_im_tabname  TYPE DD03L-TABNAME ,
it_im_it_keydef  TYPE STANDARD TABLE OF DMCKEYDEF ,
wa_im_it_keydef  LIKE LINE OF it_im_it_keydef,
ld_im_depth  TYPE DMC_TYPES-INT4 ,
it_im_it_settings  TYPE STANDARD TABLE OF DMCSTG ,
wa_im_it_settings  LIKE LINE OF it_im_it_settings,
ld_im_blocksize  TYPE DMC_TYPES-INT4 ,
it_ex_it_ranges  TYPE STANDARD TABLE OF DMCRANGE ,
wa_ex_it_ranges  LIKE LINE OF it_ex_it_ranges,
ld_im_count  TYPE DMC_TYPES-BOOLEAN ,
ld_im_sel_field  TYPE DMCWHERE-LINE ,
ld_im_client_spec  TYPE DMC_TYPES-BOOLEAN .


SELECT single TABNAME
FROM DD03L
INTO ld_im_tabname.


"populate fields of struture and append to itab
append wa_im_it_keydef to it_im_it_keydef.

ld_im_depth = 123

"populate fields of struture and append to itab
append wa_im_it_settings to it_im_it_settings.

ld_im_blocksize = 123

"populate fields of struture and append to itab
append wa_ex_it_ranges to it_ex_it_ranges.

ld_im_count = some text here

ld_im_sel_field = Check type of data required

ld_im_client_spec = some text here

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name DMC_ACS_GET_RANGES or its description.