FI_DOCUMENT_READ 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 FI_DOCUMENT_READ into the relevant SAP transaction such as SE37 or SE80.
Associated Function Group:
FACI
Released Date:
Not Released
Processing type: Remote-Enabled
CALL FUNCTION 'FI_DOCUMENT_READ' "
* EXPORTING
* i_awtyp = " acchd-awtyp Organizational type in calling application
* i_awref = " acchd-awref Reference document number in calling application
* i_aworg = SPACE " acchd-aworg Reference organizations in calling application
* i_awsys = SPACE " acchd-awsys Logical system
* i_xnbkl = SPACE " accit-xauto Read document header only
* i_bukrs = " accit-bukrs Company code
* i_belnr = " bseg-belnr FI document number
* i_gjahr = " bseg-gjahr Fiscal year
* i_bstat = SPACE " bstat_d Document Status
* i_xblnr = SPACE " xblnr1 Reference Document Number
* i_budat = " budat Posting Date in the Document
* i_blart = SPACE " blart Document Type
IMPORTING
e_awtyp = " acchd-awtyp
e_awref = " acchd-awref
e_aworg = " acchd-aworg
e_awsys = " acchd-awsys
* TABLES
* t_abuz = " abuz
* t_acchd = " acchd
* t_accit = " accit
* t_acccr = " acccr
* t_bkpf = " bkpf
* t_bseg = " bseg
EXCEPTIONS
WRONG_INPUT = 1 "
NOT_FOUND = 2 "
. " FI_DOCUMENT_READ
The ABAP code below is a full code listing to execute function module FI_DOCUMENT_READ 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).
| ld_e_awtyp | TYPE ACCHD-AWTYP , |
| ld_e_awref | TYPE ACCHD-AWREF , |
| ld_e_aworg | TYPE ACCHD-AWORG , |
| ld_e_awsys | TYPE ACCHD-AWSYS , |
| it_t_abuz | TYPE STANDARD TABLE OF ABUZ,"TABLES PARAM |
| wa_t_abuz | LIKE LINE OF it_t_abuz , |
| it_t_acchd | TYPE STANDARD TABLE OF ACCHD,"TABLES PARAM |
| wa_t_acchd | LIKE LINE OF it_t_acchd , |
| it_t_accit | TYPE STANDARD TABLE OF ACCIT,"TABLES PARAM |
| wa_t_accit | LIKE LINE OF it_t_accit , |
| it_t_acccr | TYPE STANDARD TABLE OF ACCCR,"TABLES PARAM |
| wa_t_acccr | LIKE LINE OF it_t_acccr , |
| it_t_bkpf | TYPE STANDARD TABLE OF BKPF,"TABLES PARAM |
| wa_t_bkpf | LIKE LINE OF it_t_bkpf , |
| it_t_bseg | TYPE STANDARD TABLE OF BSEG,"TABLES PARAM |
| wa_t_bseg | LIKE LINE OF it_t_bseg . |
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_e_awtyp | TYPE ACCHD-AWTYP , |
| ld_i_awtyp | TYPE ACCHD-AWTYP , |
| it_t_abuz | TYPE STANDARD TABLE OF ABUZ , |
| wa_t_abuz | LIKE LINE OF it_t_abuz, |
| ld_e_awref | TYPE ACCHD-AWREF , |
| ld_i_awref | TYPE ACCHD-AWREF , |
| it_t_acchd | TYPE STANDARD TABLE OF ACCHD , |
| wa_t_acchd | LIKE LINE OF it_t_acchd, |
| ld_e_aworg | TYPE ACCHD-AWORG , |
| ld_i_aworg | TYPE ACCHD-AWORG , |
| it_t_accit | TYPE STANDARD TABLE OF ACCIT , |
| wa_t_accit | LIKE LINE OF it_t_accit, |
| ld_e_awsys | TYPE ACCHD-AWSYS , |
| ld_i_awsys | TYPE ACCHD-AWSYS , |
| it_t_acccr | TYPE STANDARD TABLE OF ACCCR , |
| wa_t_acccr | LIKE LINE OF it_t_acccr, |
| ld_i_xnbkl | TYPE ACCIT-XAUTO , |
| it_t_bkpf | TYPE STANDARD TABLE OF BKPF , |
| wa_t_bkpf | LIKE LINE OF it_t_bkpf, |
| ld_i_bukrs | TYPE ACCIT-BUKRS , |
| it_t_bseg | TYPE STANDARD TABLE OF BSEG , |
| wa_t_bseg | LIKE LINE OF it_t_bseg, |
| ld_i_belnr | TYPE BSEG-BELNR , |
| ld_i_gjahr | TYPE BSEG-GJAHR , |
| ld_i_bstat | TYPE BSTAT_D , |
| ld_i_xblnr | TYPE XBLNR1 , |
| ld_i_budat | TYPE BUDAT , |
| ld_i_blart | TYPE BLART . |
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 FI_DOCUMENT_READ or its description.