Create a Z extractor writing a code in SE37 calling FM READ_TEXT
Could you please help me in the following case?
I need to extract the material sales text.
I have created a structure in SE 11 using the fields VKORG, MATNR, VTWEG, ZSTXT.
Then I am in SE37 building a Z function module, but I do not know how to write in the source code something that calls READ_TEXT properly. What I have for the moment is writen below. Also in the tabs of FM in SE37: Import, Export, Changing, Tables and Exception I am not sure what to fill.
Could you please help?
Thanks & Regards,
FORM first_call TABLES P_I_T_SELECT STRUCTURE ZZSALES_TEXT P_I_T_FIELDS STRUCTURE I_T_FIELDS USING P_I_REQUNR P_I_INITFLAG P_I_DSOURCE P_I_MAXSIZE CHANGING P_S_S_IF. DATA : git_memo1 TYPE STANDARD TABLE OF tline, g_name1 LIKE thead-tdname, gwa_memo1 TYPE tline. loop at s_matnr. CONCATENATE s_matnr-low g_vkorg c_00 INTO g_name1. CALL FUNCTION 'READ_TEXT' EXPORTING id = '0001' language = PT name = g_name1 object = 'MVKE' TABLES lines = git_memo1 EXCEPTIONS id = 1 language = 2 name = 3 not_found = 4 object = 5 reference_check = 6 wrong_access_to_archive = 7 OTHERS = 8. loop at git_memo1 into gwa_memo1. write :/0(20) s_matnr-low,25(60) gwa_memo1-TDLINE. endloop. endloop.