Hello,
I have a requirement where I need to update the BKTXT field of table BKPF, to do this I have written the following but when I execute it I am getting the error and looks like this is not the way to do it. Do you know any other BAPI/FM that I can use to update the BXTXT field of table BKPF based on the document number.
data: i_accchg TYPE STANDARD TABLE OF accchg, wa_accchg LIKE LINE OF i_accchg, wa_belnr TYPE bkpf-belnr. wa_accchg-fdname = 'BKTXT'. " field that need to be updated wa_accchg-oldval = ' '. " old value in that field if any wa_accchg-newval = 'TEST'. " value that need to be updated APPEND wa_accchg to i_accchg. wa_belnr = '0990883998'. CALL FUNCTION 'FI_DOCUMENT_CHANGE' EXPORTING i_awtyp = 'BKPF' i_awref = wa_belnr * I_AWORG = ' ' * I_AWSYS = ' ' * I_KUNNR = ' ' * I_LIFNR = ' ' * I_OBZEI = ' ' * I_BUZEI = * I_BSEGC = * X_LOCK = 'X' TABLES t_accchg = i_accchg * EXCEPTIONS * NO_REFERENCE = 1 * NO_DOCUMENT = 2 * MANY_DOCUMENTS = 3 * WRONG_INPUT = 4 * OVERWRITE_CREDITCARD = 5 * OTHERS = 6 . IF sy-subrc <> 0. * Implement suitable error handling here ENDIF.
to byu
b