SAP CORRESPONDENCE_REQUEST Function Module for









CORRESPONDENCE_REQUEST is a standard correspondence request SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 correspondence request FM, simply by entering the name CORRESPONDENCE_REQUEST into the relevant SAP transaction such as SE37 or SE38.

Function Group: F022
Program Name: SAPLF022
Main Program: SAPLF022
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function CORRESPONDENCE_REQUEST 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 'CORRESPONDENCE_REQUEST'"
EXPORTING
* I_ACCOUNT = ' ' "Proposal for correspondence: Accou
* I_YEAR = 0000 "
* I_EVENT = ' ' "
* I_ACCOUNT_TYPE = ' ' "Proposal for correspondence: Accou
* I_COMPANY_CODE = ' ' "Proposal for correspondence: Compa
* I_DBUPDATE = ' ' "Indicator: Update table BKORR imme
* I_DOCUMENT = ' ' "Proposal for correspondence: Docum
* I_MESSAGE = ' ' "Indicator: Acknowledgement message
* I_OVERWRITE_ACC = ' ' "Indicator: Account from proposal c
* I_OVERWRITE_DOC = ' ' "Indicator: Document from proposal
I_PROCESS = "Process ID for selecting possible

IMPORTING
E_BKORM = "
E_TEXT = "

EXCEPTIONS
NO_EVENT_FOUND = 1 NO_EVENT_SELECTED = 2
.



IMPORTING Parameters details for CORRESPONDENCE_REQUEST

I_ACCOUNT - Proposal for correspondence: Accou

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

I_YEAR -

Data type: BKPF-GJAHR
Default: 0000
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_EVENT -

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

I_ACCOUNT_TYPE - Proposal for correspondence: Accou

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

I_COMPANY_CODE - Proposal for correspondence: Compa

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

I_DBUPDATE - Indicator: Update table BKORR imme

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

I_DOCUMENT - Proposal for correspondence: Docum

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

I_MESSAGE - Indicator: Acknowledgement message

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

I_OVERWRITE_ACC - Indicator: Account from proposal c

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

I_OVERWRITE_DOC - Indicator: Document from proposal

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

I_PROCESS - Process ID for selecting possible

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

EXPORTING Parameters details for CORRESPONDENCE_REQUEST

E_BKORM -

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

E_TEXT -

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

EXCEPTIONS details

NO_EVENT_FOUND - No allowed correspondence type ava

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

NO_EVENT_SELECTED - No correspondence type selected

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

Copy and paste ABAP code example for CORRESPONDENCE_REQUEST 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:
lv_e_bkorm  TYPE BKORM, "   
lv_i_account  TYPE RF05A-KONTO, "   SPACE
lv_no_event_found  TYPE RF05A, "   
lv_i_year  TYPE BKPF-GJAHR, "   0000
lv_i_event  TYPE T048-EVENT, "   SPACE
lv_e_text  TYPE T048T-LTEXT, "   
lv_i_account_type  TYPE BSEG-XUMSW, "   SPACE
lv_no_event_selected  TYPE BSEG, "   
lv_i_company_code  TYPE BKPF-BUKRS, "   SPACE
lv_i_dbupdate  TYPE BSEG-XUMSW, "   SPACE
lv_i_document  TYPE BKPF-BELNR, "   SPACE
lv_i_message  TYPE BSEG-XUMSW, "   SPACE
lv_i_overwrite_acc  TYPE BSEG-XUMSW, "   SPACE
lv_i_overwrite_doc  TYPE BSEG-XUMSW, "   SPACE
lv_i_process  TYPE BSEG. "   

  CALL FUNCTION 'CORRESPONDENCE_REQUEST'  "
    EXPORTING
         I_ACCOUNT = lv_i_account
         I_YEAR = lv_i_year
         I_EVENT = lv_i_event
         I_ACCOUNT_TYPE = lv_i_account_type
         I_COMPANY_CODE = lv_i_company_code
         I_DBUPDATE = lv_i_dbupdate
         I_DOCUMENT = lv_i_document
         I_MESSAGE = lv_i_message
         I_OVERWRITE_ACC = lv_i_overwrite_acc
         I_OVERWRITE_DOC = lv_i_overwrite_doc
         I_PROCESS = lv_i_process
    IMPORTING
         E_BKORM = lv_e_bkorm
         E_TEXT = lv_e_text
    EXCEPTIONS
        NO_EVENT_FOUND = 1
        NO_EVENT_SELECTED = 2
. " CORRESPONDENCE_REQUEST




ABAP code using 7.40 inline data declarations to call FM CORRESPONDENCE_REQUEST

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 KONTO FROM RF05A INTO @DATA(ld_i_account).
DATA(ld_i_account) = ' '.
 
 
"SELECT single GJAHR FROM BKPF INTO @DATA(ld_i_year).
DATA(ld_i_year) = 0000.
 
"SELECT single EVENT FROM T048 INTO @DATA(ld_i_event).
DATA(ld_i_event) = ' '.
 
"SELECT single LTEXT FROM T048T INTO @DATA(ld_e_text).
 
"SELECT single XUMSW FROM BSEG INTO @DATA(ld_i_account_type).
DATA(ld_i_account_type) = ' '.
 
 
"SELECT single BUKRS FROM BKPF INTO @DATA(ld_i_company_code).
DATA(ld_i_company_code) = ' '.
 
"SELECT single XUMSW FROM BSEG INTO @DATA(ld_i_dbupdate).
DATA(ld_i_dbupdate) = ' '.
 
"SELECT single BELNR FROM BKPF INTO @DATA(ld_i_document).
DATA(ld_i_document) = ' '.
 
"SELECT single XUMSW FROM BSEG INTO @DATA(ld_i_message).
DATA(ld_i_message) = ' '.
 
"SELECT single XUMSW FROM BSEG INTO @DATA(ld_i_overwrite_acc).
DATA(ld_i_overwrite_acc) = ' '.
 
"SELECT single XUMSW FROM BSEG INTO @DATA(ld_i_overwrite_doc).
DATA(ld_i_overwrite_doc) = ' '.
 
 


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!