SAP Function Modules

AIPA_CP_REQ_PLAN_TO_MEAS_PLAN SAP Function module







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

Associated Function Group: AIPA_COPY_VALUES
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM AIPA_CP_REQ_PLAN_TO_MEAS_PLAN - AIPA CP REQ PLAN TO MEAS PLAN





CALL FUNCTION 'AIPA_CP_REQ_PLAN_TO_MEAS_PLAN' "
  EXPORTING
*   id_versn_from = '000'       " bpge-versn
    id_gnjhr_from =             " imtp-gjahr
*   id_versn = '000'            " bpge-versn
*   iflg_or = 'X'               " xfeld
*   iflg_pr = 'X'               " xfeld
*   iflg_cons_only = ' '        " xfeld
*   iflg_cons_check = ' '       " im_conscheck_coarea
*   iflg_cons_check_obj = ' '   " im_conscheck_obj
*   iflg_cons_check_def = ' '   " im_conscheck_def
*   iflg_cons_adjust = ' '      " xfeld
*   id_cons_severity = 'E'      " symsgty
*   iflg_test_run = 'X'         " xfeld
*   id_sgtxt = ' '              " sgtxt
* TABLES
*   it_obj =                    " raip_obj
*   et_return =                 " bapiret2
  EXCEPTIONS
    ABEND_OCCURED = 1           "
    .  "  AIPA_CP_REQ_PLAN_TO_MEAS_PLAN

ABAP code example for Function Module AIPA_CP_REQ_PLAN_TO_MEAS_PLAN





The ABAP code below is a full code listing to execute function module AIPA_CP_REQ_PLAN_TO_MEAS_PLAN 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_obj  TYPE STANDARD TABLE OF RAIP_OBJ,"TABLES PARAM
wa_it_obj  LIKE LINE OF it_it_obj ,
it_et_return  TYPE STANDARD TABLE OF BAPIRET2,"TABLES PARAM
wa_et_return  LIKE LINE OF it_et_return .


SELECT single VERSN
FROM BPGE
INTO @DATA(ld_id_versn_from).


SELECT single GJAHR
FROM IMTP
INTO @DATA(ld_id_gnjhr_from).


SELECT single VERSN
FROM BPGE
INTO @DATA(ld_id_versn).

DATA(ld_iflg_or) = 'Check type of data required'.
DATA(ld_iflg_pr) = 'Check type of data required'.
DATA(ld_iflg_cons_only) = 'Check type of data required'.
DATA(ld_iflg_cons_check) = 'Check type of data required'.
DATA(ld_iflg_cons_check_obj) = 'Check type of data required'.
DATA(ld_iflg_cons_check_def) = 'Check type of data required'.
DATA(ld_iflg_cons_adjust) = 'Check type of data required'.
DATA(ld_id_cons_severity) = 'some text here'.
DATA(ld_iflg_test_run) = 'some text here'.
DATA(ld_id_sgtxt) = 'some text here'.

"populate fields of struture and append to itab
append wa_it_obj to it_it_obj.

"populate fields of struture and append to itab
append wa_et_return to it_et_return. . CALL FUNCTION 'AIPA_CP_REQ_PLAN_TO_MEAS_PLAN' EXPORTING * id_versn_from = ld_id_versn_from id_gnjhr_from = ld_id_gnjhr_from * id_versn = ld_id_versn * iflg_or = ld_iflg_or * iflg_pr = ld_iflg_pr * iflg_cons_only = ld_iflg_cons_only * iflg_cons_check = ld_iflg_cons_check * iflg_cons_check_obj = ld_iflg_cons_check_obj * iflg_cons_check_def = ld_iflg_cons_check_def * iflg_cons_adjust = ld_iflg_cons_adjust * id_cons_severity = ld_id_cons_severity * iflg_test_run = ld_iflg_test_run * id_sgtxt = ld_id_sgtxt * TABLES * it_obj = it_it_obj * et_return = it_et_return EXCEPTIONS ABEND_OCCURED = 1 . " AIPA_CP_REQ_PLAN_TO_MEAS_PLAN
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_id_versn_from  TYPE BPGE-VERSN ,
it_it_obj  TYPE STANDARD TABLE OF RAIP_OBJ ,
wa_it_obj  LIKE LINE OF it_it_obj,
ld_id_gnjhr_from  TYPE IMTP-GJAHR ,
it_et_return  TYPE STANDARD TABLE OF BAPIRET2 ,
wa_et_return  LIKE LINE OF it_et_return,
ld_id_versn  TYPE BPGE-VERSN ,
ld_iflg_or  TYPE XFELD ,
ld_iflg_pr  TYPE XFELD ,
ld_iflg_cons_only  TYPE XFELD ,
ld_iflg_cons_check  TYPE IM_CONSCHECK_COAREA ,
ld_iflg_cons_check_obj  TYPE IM_CONSCHECK_OBJ ,
ld_iflg_cons_check_def  TYPE IM_CONSCHECK_DEF ,
ld_iflg_cons_adjust  TYPE XFELD ,
ld_id_cons_severity  TYPE SYMSGTY ,
ld_iflg_test_run  TYPE XFELD ,
ld_id_sgtxt  TYPE SGTXT .


SELECT single VERSN
FROM BPGE
INTO ld_id_versn_from.


"populate fields of struture and append to itab
append wa_it_obj to it_it_obj.

SELECT single GJAHR
FROM IMTP
INTO ld_id_gnjhr_from.


"populate fields of struture and append to itab
append wa_et_return to it_et_return.

SELECT single VERSN
FROM BPGE
INTO ld_id_versn.

ld_iflg_or = 'some text here'.
ld_iflg_pr = 'some text here'.
ld_iflg_cons_only = 'some text here'.
ld_iflg_cons_check = 'some text here'.
ld_iflg_cons_check_obj = 'some text here'.
ld_iflg_cons_check_def = 'some text here'.
ld_iflg_cons_adjust = 'some text here'.
ld_id_cons_severity = 'some text here'.
ld_iflg_test_run = 'some text here'.
ld_id_sgtxt = '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 AIPA_CP_REQ_PLAN_TO_MEAS_PLAN or its description.