SAP MASTERIDOC_CREATE_PRICAT Function Module for PRICAT outbound processing









MASTERIDOC_CREATE_PRICAT is a standard masteridoc create pricat SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for PRICAT outbound processing processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for masteridoc create pricat FM, simply by entering the name MASTERIDOC_CREATE_PRICAT into the relevant SAP transaction such as SE37 or SE38.

Function Group: VPRE
Program Name: SAPLVPRE
Main Program: SAPLVPRE
Appliation area: V
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function MASTERIDOC_CREATE_PRICAT pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'MASTERIDOC_CREATE_PRICAT'"PRICAT outbound processing
EXPORTING
PI_MESTYP = "
* PI_PROTOCOLL = 'X' "
PI_PROFIL = "
PI_SELECTION = "
* PI_ILNNR = 0 "
* PI_PARTYP = ' ' "
* PI_PARNUM = ' ' "
* PI_LOGSYS = ' ' "
* PI_PARROL = ' ' "
* PI_VARIAN = ' ' "
* PI_FUNCTI = ' ' "
* PI_TEST = ' ' "
* PI_PORT = ' ' "

TABLES
PIT_WSOF = "
PIT_WSOP = "
PIT_WRSZ = "

EXCEPTIONS
IDOC_COULD_NOT_BE_CREATED = 1 PARTNER_NOT_FOUND = 2 LOGSYS_NOT_FOUND = 3
.




Customer Function user exits

Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.
EXIT_SAPLVPRE_001 PRICAT Outbound Processing (MAMT AUSP MAW1 derivation)
EXIT_SAPLVPRE_002 PRICAT Outbound Processing (Control Record)
EXIT_SAPLVPRE_003 PRICAT Outbound Processing (IDoc Segments)

IMPORTING Parameters details for MASTERIDOC_CREATE_PRICAT

PI_MESTYP -

Data type: TBDME-MESTYP
Optional: No
Call by Reference: No ( called with pass by value option)

PI_PROTOCOLL -

Data type:
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_PROFIL -

Data type: PRICAT_PRO
Optional: No
Call by Reference: No ( called with pass by value option)

PI_SELECTION -

Data type: PRICAT_STR
Optional: No
Call by Reference: No ( called with pass by value option)

PI_ILNNR -

Data type: ILNNR_STRU-ILNNR
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_PARTYP -

Data type: EDPP1-PARTYP
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_PARNUM -

Data type: EDPP1-PARNUM
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_LOGSYS -

Data type: TBDLS-LOGSYS
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_PARROL -

Data type: EDUNIX-SNDPFC
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_VARIAN -

Data type: EDUNIX-MESCOD
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_FUNCTI -

Data type: EDUNIX-MESFCT
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_TEST -

Data type: EDUNIX-TEST
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

PI_PORT -

Data type: EDUNIX-SNDPOR
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for MASTERIDOC_CREATE_PRICAT

PIT_WSOF -

Data type: WSOF
Optional: No
Call by Reference: No ( called with pass by value option)

PIT_WSOP -

Data type: WSOP
Optional: No
Call by Reference: No ( called with pass by value option)

PIT_WRSZ -

Data type: WRSZ
Optional: No
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

IDOC_COULD_NOT_BE_CREATED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

PARTNER_NOT_FOUND -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

LOGSYS_NOT_FOUND -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for MASTERIDOC_CREATE_PRICAT Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.

DATA:
lt_pit_wsof  TYPE STANDARD TABLE OF WSOF, "   
lv_pi_mestyp  TYPE TBDME-MESTYP, "   
lv_idoc_could_not_be_created  TYPE TBDME, "   
lv_pi_protocoll  TYPE TBDME, "   'X'
lv_pi_profil  TYPE PRICAT_PRO, "   
lv_pi_selection  TYPE PRICAT_STR, "   
lv_pi_ilnnr  TYPE ILNNR_STRU-ILNNR, "   0
lt_pit_wsop  TYPE STANDARD TABLE OF WSOP, "   
lv_pi_partyp  TYPE EDPP1-PARTYP, "   SPACE
lv_partner_not_found  TYPE EDPP1, "   
lt_pit_wrsz  TYPE STANDARD TABLE OF WRSZ, "   
lv_pi_parnum  TYPE EDPP1-PARNUM, "   SPACE
lv_logsys_not_found  TYPE EDPP1, "   
lv_pi_logsys  TYPE TBDLS-LOGSYS, "   SPACE
lv_pi_parrol  TYPE EDUNIX-SNDPFC, "   SPACE
lv_pi_varian  TYPE EDUNIX-MESCOD, "   SPACE
lv_pi_functi  TYPE EDUNIX-MESFCT, "   SPACE
lv_pi_test  TYPE EDUNIX-TEST, "   SPACE
lv_pi_port  TYPE EDUNIX-SNDPOR. "   SPACE

  CALL FUNCTION 'MASTERIDOC_CREATE_PRICAT'  "PRICAT outbound processing
    EXPORTING
         PI_MESTYP = lv_pi_mestyp
         PI_PROTOCOLL = lv_pi_protocoll
         PI_PROFIL = lv_pi_profil
         PI_SELECTION = lv_pi_selection
         PI_ILNNR = lv_pi_ilnnr
         PI_PARTYP = lv_pi_partyp
         PI_PARNUM = lv_pi_parnum
         PI_LOGSYS = lv_pi_logsys
         PI_PARROL = lv_pi_parrol
         PI_VARIAN = lv_pi_varian
         PI_FUNCTI = lv_pi_functi
         PI_TEST = lv_pi_test
         PI_PORT = lv_pi_port
    TABLES
         PIT_WSOF = lt_pit_wsof
         PIT_WSOP = lt_pit_wsop
         PIT_WRSZ = lt_pit_wrsz
    EXCEPTIONS
        IDOC_COULD_NOT_BE_CREATED = 1
        PARTNER_NOT_FOUND = 2
        LOGSYS_NOT_FOUND = 3
. " MASTERIDOC_CREATE_PRICAT




ABAP code using 7.40 inline data declarations to call FM MASTERIDOC_CREATE_PRICAT

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

 
"SELECT single MESTYP FROM TBDME INTO @DATA(ld_pi_mestyp).
 
 
DATA(ld_pi_protocoll) = 'X'.
 
 
 
"SELECT single ILNNR FROM ILNNR_STRU INTO @DATA(ld_pi_ilnnr).
 
 
"SELECT single PARTYP FROM EDPP1 INTO @DATA(ld_pi_partyp).
DATA(ld_pi_partyp) = ' '.
 
 
 
"SELECT single PARNUM FROM EDPP1 INTO @DATA(ld_pi_parnum).
DATA(ld_pi_parnum) = ' '.
 
 
"SELECT single LOGSYS FROM TBDLS INTO @DATA(ld_pi_logsys).
DATA(ld_pi_logsys) = ' '.
 
"SELECT single SNDPFC FROM EDUNIX INTO @DATA(ld_pi_parrol).
DATA(ld_pi_parrol) = ' '.
 
"SELECT single MESCOD FROM EDUNIX INTO @DATA(ld_pi_varian).
DATA(ld_pi_varian) = ' '.
 
"SELECT single MESFCT FROM EDUNIX INTO @DATA(ld_pi_functi).
DATA(ld_pi_functi) = ' '.
 
"SELECT single TEST FROM EDUNIX INTO @DATA(ld_pi_test).
DATA(ld_pi_test) = ' '.
 
"SELECT single SNDPOR FROM EDUNIX INTO @DATA(ld_pi_port).
DATA(ld_pi_port) = ' '.
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!