FM_READ_DATA 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 FM_READ_DATA into the relevant SAP transaction such as SE37 or SE80.
Associated Function Group:
FMES
Released Date:
Not Released
Processing type: Normal fucntion module
CALL FUNCTION 'FM_READ_DATA' "
EXPORTING
rkb1x = " rkb1x List of application-dependent sort features
s_form_name = " dd27v-eform Transfer name of FORM to data
s_program_name = " rs38m-programm Program name being transferred to data
* i_rkb1r = " rkb1r
IMPORTING
sel_date = " rkb1d-selda
sel_time = " rkb1d-selti
TABLES
selection_table = " cedst Selection condition table
* add_sel_tab = " cedst
* selected_fields = " cfbsf01
* selected_hieras = " cfbsh01
EXCEPTIONS
NO_RECORD_FOUND = 1 " No record found
. " FM_READ_DATA
The ABAP code below is a full code listing to execute function module FM_READ_DATA 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_sel_date | TYPE RKB1D-SELDA , |
| ld_sel_time | TYPE RKB1D-SELTI , |
| it_selection_table | TYPE STANDARD TABLE OF CEDST,"TABLES PARAM |
| wa_selection_table | LIKE LINE OF it_selection_table , |
| it_add_sel_tab | TYPE STANDARD TABLE OF CEDST,"TABLES PARAM |
| wa_add_sel_tab | LIKE LINE OF it_add_sel_tab , |
| it_selected_fields | TYPE STANDARD TABLE OF CFBSF01,"TABLES PARAM |
| wa_selected_fields | LIKE LINE OF it_selected_fields , |
| it_selected_hieras | TYPE STANDARD TABLE OF CFBSH01,"TABLES PARAM |
| wa_selected_hieras | LIKE LINE OF it_selected_hieras . |
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_sel_date | TYPE RKB1D-SELDA , |
| ld_rkb1x | TYPE RKB1X , |
| it_selection_table | TYPE STANDARD TABLE OF CEDST , |
| wa_selection_table | LIKE LINE OF it_selection_table, |
| ld_sel_time | TYPE RKB1D-SELTI , |
| ld_s_form_name | TYPE DD27V-EFORM , |
| it_add_sel_tab | TYPE STANDARD TABLE OF CEDST , |
| wa_add_sel_tab | LIKE LINE OF it_add_sel_tab, |
| ld_s_program_name | TYPE RS38M-PROGRAMM , |
| it_selected_fields | TYPE STANDARD TABLE OF CFBSF01 , |
| wa_selected_fields | LIKE LINE OF it_selected_fields, |
| ld_i_rkb1r | TYPE RKB1R , |
| it_selected_hieras | TYPE STANDARD TABLE OF CFBSH01 , |
| wa_selected_hieras | LIKE LINE OF it_selected_hieras. |
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 FM_READ_DATA or its description.