SAP Function Modules

CNV_CDMC_CTS_USAGE_ANALYSIS SAP Function module - CDMC: CTS: Gets the usage info for the object set







CNV_CDMC_CTS_USAGE_ANALYSIS 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 CNV_CDMC_CTS_USAGE_ANALYSIS into the relevant SAP transaction such as SE37 or SE80.

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


Pattern for FM CNV_CDMC_CTS_USAGE_ANALYSIS - CNV CDMC CTS USAGE ANALYSIS





CALL FUNCTION 'CNV_CDMC_CTS_USAGE_ANALYSIS' "CDMC: CTS: Gets the usage info for the object set
  EXPORTING
    iv_anal_sys =               " rfcdes-rfcdest  Logical destination (specified in function call)
    iv_start_anal =             " cnvcdmccts_analstdate  CDMC: CTS Analysis Start Date
    iv_end_anal =               " cnvcdmccts_analenddate  CDMC: CTS Analysis End Date
*   iv_iter_cnt = 3             " int4          Natural number
*   iv_proj_id =                " cnvcdmc_project_id  CDMC - Project ID
  TABLES
*   it_reqs =                   " e070          Change & Transport System: Header of Requests/Tasks
*   it_objs =                   " cnvcdmccts_objects_set  Structure for objects set information
    it_objs_output =            " cnvcdmccts_used_objs  Structure for used objects
*   et_ref_objs =               " cnvcdmccts_robjs  CDMC:CTS : Table to strore the environment objects
  EXCEPTIONS
    NO_STATISTICS_DATA = 1      "               There was no statistics data found in the system
    NO_INPUT_DATA = 2           "               No data found for analysis
    .  "  CNV_CDMC_CTS_USAGE_ANALYSIS

ABAP code example for Function Module CNV_CDMC_CTS_USAGE_ANALYSIS





The ABAP code below is a full code listing to execute function module CNV_CDMC_CTS_USAGE_ANALYSIS 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_it_reqs  TYPE STANDARD TABLE OF E070,"TABLES PARAM
wa_it_reqs  LIKE LINE OF it_it_reqs ,
it_it_objs  TYPE STANDARD TABLE OF CNVCDMCCTS_OBJECTS_SET,"TABLES PARAM
wa_it_objs  LIKE LINE OF it_it_objs ,
it_it_objs_output  TYPE STANDARD TABLE OF CNVCDMCCTS_USED_OBJS,"TABLES PARAM
wa_it_objs_output  LIKE LINE OF it_it_objs_output ,
it_et_ref_objs  TYPE STANDARD TABLE OF CNVCDMCCTS_ROBJS,"TABLES PARAM
wa_et_ref_objs  LIKE LINE OF it_et_ref_objs .


SELECT single RFCDEST
FROM RFCDES
INTO @DATA(ld_iv_anal_sys).

DATA(ld_iv_start_anal) = 'Check type of data required'.
DATA(ld_iv_end_anal) = 'Check type of data required'.
DATA(ld_iv_iter_cnt) = 'Check type of data required'.
DATA(ld_iv_proj_id) = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_it_reqs to it_it_reqs.

"populate fields of struture and append to itab
append wa_it_objs to it_it_objs.

"populate fields of struture and append to itab
append wa_it_objs_output to it_it_objs_output.

"populate fields of struture and append to itab
append wa_et_ref_objs to it_et_ref_objs. . CALL FUNCTION 'CNV_CDMC_CTS_USAGE_ANALYSIS' EXPORTING iv_anal_sys = ld_iv_anal_sys iv_start_anal = ld_iv_start_anal iv_end_anal = ld_iv_end_anal * iv_iter_cnt = ld_iv_iter_cnt * iv_proj_id = ld_iv_proj_id TABLES * it_reqs = it_it_reqs * it_objs = it_it_objs it_objs_output = it_it_objs_output * et_ref_objs = it_et_ref_objs EXCEPTIONS NO_STATISTICS_DATA = 1 NO_INPUT_DATA = 2 . " CNV_CDMC_CTS_USAGE_ANALYSIS
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "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_iv_anal_sys  TYPE RFCDES-RFCDEST ,
it_it_reqs  TYPE STANDARD TABLE OF E070 ,
wa_it_reqs  LIKE LINE OF it_it_reqs,
ld_iv_start_anal  TYPE CNVCDMCCTS_ANALSTDATE ,
it_it_objs  TYPE STANDARD TABLE OF CNVCDMCCTS_OBJECTS_SET ,
wa_it_objs  LIKE LINE OF it_it_objs,
ld_iv_end_anal  TYPE CNVCDMCCTS_ANALENDDATE ,
it_it_objs_output  TYPE STANDARD TABLE OF CNVCDMCCTS_USED_OBJS ,
wa_it_objs_output  LIKE LINE OF it_it_objs_output,
ld_iv_iter_cnt  TYPE INT4 ,
it_et_ref_objs  TYPE STANDARD TABLE OF CNVCDMCCTS_ROBJS ,
wa_et_ref_objs  LIKE LINE OF it_et_ref_objs,
ld_iv_proj_id  TYPE CNVCDMC_PROJECT_ID .


SELECT single RFCDEST
FROM RFCDES
INTO ld_iv_anal_sys.


"populate fields of struture and append to itab
append wa_it_reqs to it_it_reqs.
ld_iv_start_anal = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_it_objs to it_it_objs.
ld_iv_end_anal = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_it_objs_output to it_it_objs_output.
ld_iv_iter_cnt = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_et_ref_objs to it_et_ref_objs.
ld_iv_proj_id = 'Check type of data required'.

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 CNV_CDMC_CTS_USAGE_ANALYSIS or its description.