SAP Function Modules

SD_PARTNER_DETERMINATION SAP Function module







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

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


Pattern for FM SD_PARTNER_DETERMINATION - SD PARTNER DETERMINATION





CALL FUNCTION 'SD_PARTNER_DETERMINATION' "
  EXPORTING
    fic_objecttype =            " swo_objtyp    Object Type
    fic_objectkey =             " swo_typeid    Object Key
    fif_pargr =                 " pargr         Partner Determination Procedure
    fif_destination_posnr =     " posnr
    fis_sdorgdata =             " sdorgdata     SD Organizational Data
*   fif_parvw = SPACE           " parvw_4
*   fif_posnr =                 " posnr
*   fif_partner = SPACE         " sd_partner_parnr
*   fif_hityp = SPACE           " knvh-hityp    Cust. Hierarchy Type
*   fif_hi_date = SY-DATLO      " sy-datlo      Date and Time, Current (Application Server) Date
*   fif_partners_of_parvw_only = SPACE  " parvw_4
*   fif_complete_determination = 'X'  " xflag
*   fif_partial_determination = SPACE  " xflag
*   fif_check_remove_and_find = SPACE  " xflag
*   fif_just_check_and_remove = SPACE  " xflag
*   fif_just_check = SPACE      " xflag
*   fif_new_time_relevant_par = SPACE  " xflag
*   fif_no_log = SPACE          " xflag
*   fif_clear_appl_log = 'X'    " xflag
*   fif_no_dialog = SPACE       " xflag
*   fif_listprocessing = SPACE  " xfeld
  IMPORTING
    fet_xvbpa =                 " lv09a_ty_xvbpa  Partner Table
    fef_log_count =             " i
* TABLES
*   fet_kupav =                 " lv09a_ty_kupav_table
  EXCEPTIONS
    PARAMETER_INCOMPLETE = 1    "
    OBJECT_NOT_FOUND = 2        "
    GIVEN_PARTNER_NOT_FOUND = 3  "
    MANDATORY_PARTNER_NOT_POSSIBLE = 4  "
    .  "  SD_PARTNER_DETERMINATION

ABAP code example for Function Module SD_PARTNER_DETERMINATION





The ABAP code below is a full code listing to execute function module SD_PARTNER_DETERMINATION 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:
ld_fet_xvbpa  TYPE LV09A_TY_XVBPA ,
ld_fef_log_count  TYPE I ,
it_fet_kupav  TYPE STANDARD TABLE OF LV09A_TY_KUPAV_TABLE,"TABLES PARAM
wa_fet_kupav  LIKE LINE OF it_fet_kupav .

DATA(ld_fic_objecttype) = 'Check type of data required'.
DATA(ld_fic_objectkey) = 'Check type of data required'.
DATA(ld_fif_pargr) = 'Check type of data required'.
DATA(ld_fif_destination_posnr) = 'Check type of data required'.
DATA(ld_fis_sdorgdata) = 'Check type of data required'.
DATA(ld_fif_parvw) = 'Check type of data required'.
DATA(ld_fif_posnr) = 'Check type of data required'.
DATA(ld_fif_partner) = 'Check type of data required'.

SELECT single HITYP
FROM KNVH
INTO @DATA(ld_fif_hityp).

DATA(ld_fif_hi_date) = '20210129'.
DATA(ld_fif_partners_of_parvw_only) = '20210129'.
DATA(ld_fif_complete_determination) = '20210129'.
DATA(ld_fif_partial_determination) = '20210129'.
DATA(ld_fif_check_remove_and_find) = '20210129'.
DATA(ld_fif_just_check_and_remove) = '20210129'.
DATA(ld_fif_just_check) = '20210129'.
DATA(ld_fif_new_time_relevant_par) = '20210129'.
DATA(ld_fif_no_log) = '20210129'.
DATA(ld_fif_clear_appl_log) = '20210129'.
DATA(ld_fif_no_dialog) = '20210129'.
DATA(ld_fif_listprocessing) = '20210129'.

"populate fields of struture and append to itab
append wa_fet_kupav to it_fet_kupav. . CALL FUNCTION 'SD_PARTNER_DETERMINATION' EXPORTING fic_objecttype = ld_fic_objecttype fic_objectkey = ld_fic_objectkey fif_pargr = ld_fif_pargr fif_destination_posnr = ld_fif_destination_posnr fis_sdorgdata = ld_fis_sdorgdata * fif_parvw = ld_fif_parvw * fif_posnr = ld_fif_posnr * fif_partner = ld_fif_partner * fif_hityp = ld_fif_hityp * fif_hi_date = ld_fif_hi_date * fif_partners_of_parvw_only = ld_fif_partners_of_parvw_only * fif_complete_determination = ld_fif_complete_determination * fif_partial_determination = ld_fif_partial_determination * fif_check_remove_and_find = ld_fif_check_remove_and_find * fif_just_check_and_remove = ld_fif_just_check_and_remove * fif_just_check = ld_fif_just_check * fif_new_time_relevant_par = ld_fif_new_time_relevant_par * fif_no_log = ld_fif_no_log * fif_clear_appl_log = ld_fif_clear_appl_log * fif_no_dialog = ld_fif_no_dialog * fif_listprocessing = ld_fif_listprocessing IMPORTING fet_xvbpa = ld_fet_xvbpa fef_log_count = ld_fef_log_count * TABLES * fet_kupav = it_fet_kupav EXCEPTIONS PARAMETER_INCOMPLETE = 1 OBJECT_NOT_FOUND = 2 GIVEN_PARTNER_NOT_FOUND = 3 MANDATORY_PARTNER_NOT_POSSIBLE = 4 . " SD_PARTNER_DETERMINATION
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 ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 4. "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_fet_xvbpa  TYPE LV09A_TY_XVBPA ,
ld_fic_objecttype  TYPE SWO_OBJTYP ,
it_fet_kupav  TYPE STANDARD TABLE OF LV09A_TY_KUPAV_TABLE ,
wa_fet_kupav  LIKE LINE OF it_fet_kupav,
ld_fef_log_count  TYPE I ,
ld_fic_objectkey  TYPE SWO_TYPEID ,
ld_fif_pargr  TYPE PARGR ,
ld_fif_destination_posnr  TYPE POSNR ,
ld_fis_sdorgdata  TYPE SDORGDATA ,
ld_fif_parvw  TYPE PARVW_4 ,
ld_fif_posnr  TYPE POSNR ,
ld_fif_partner  TYPE SD_PARTNER_PARNR ,
ld_fif_hityp  TYPE KNVH-HITYP ,
ld_fif_hi_date  TYPE SY-DATLO ,
ld_fif_partners_of_parvw_only  TYPE PARVW_4 ,
ld_fif_complete_determination  TYPE XFLAG ,
ld_fif_partial_determination  TYPE XFLAG ,
ld_fif_check_remove_and_find  TYPE XFLAG ,
ld_fif_just_check_and_remove  TYPE XFLAG ,
ld_fif_just_check  TYPE XFLAG ,
ld_fif_new_time_relevant_par  TYPE XFLAG ,
ld_fif_no_log  TYPE XFLAG ,
ld_fif_clear_appl_log  TYPE XFLAG ,
ld_fif_no_dialog  TYPE XFLAG ,
ld_fif_listprocessing  TYPE XFELD .

ld_fic_objecttype = '20210129'.

"populate fields of struture and append to itab
append wa_fet_kupav to it_fet_kupav.
ld_fic_objectkey = '20210129'.
ld_fif_pargr = '20210129'.
ld_fif_destination_posnr = '20210129'.
ld_fis_sdorgdata = '20210129'.
ld_fif_parvw = '20210129'.
ld_fif_posnr = '20210129'.
ld_fif_partner = '20210129'.

SELECT single HITYP
FROM KNVH
INTO ld_fif_hityp.

ld_fif_hi_date = '20210129'.
ld_fif_partners_of_parvw_only = '20210129'.
ld_fif_complete_determination = '20210129'.
ld_fif_partial_determination = '20210129'.
ld_fif_check_remove_and_find = '20210129'.
ld_fif_just_check_and_remove = '20210129'.
ld_fif_just_check = '20210129'.
ld_fif_new_time_relevant_par = '20210129'.
ld_fif_no_log = '20210129'.
ld_fif_clear_appl_log = '20210129'.
ld_fif_no_dialog = '20210129'.
ld_fif_listprocessing = '20210129'.

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