on 04-01-2017 10:03 AM
Hi,
I am trying to post physical inventory document using BAPI_MATPHYSINV_POSTDIFF and in alternative call for the bapi i am getting Error : "Material numbers provided in equivalent fields differ".
If i go and post same documents separately through my code it got posted. but in loop the same BAPI gives above error in alternative call.
CL_MATNR_CHK_MAPPER
METHOD : TABLES_CONV_TAB_INTERNAL
* Now do all the assigns of the primary table
IF NOT <lsf_fnames>-seg_fields-long IS INITIAL.
ASSIGN COMPONENT <lsf_fnames>-seg_fields-long OF STRUCTURE <lsf_line> TO <lvf_long>.
ENDIF.
In above code <lvf_long> populated by previous BAPI Call material and due to diff in current BAPI material call it gives me that error.
We are using SAP S/4HANA
I have also cleared buffer data using
CALL FUNCTION 'ISSR_BAPI_BUFFER_REFRESH_ALL'.
Please suggest how to overcome with this error.
Thanks in Advance
Pratik
Dear Pratik Patel,
Got any solution for this?
We are facing the same issue for Sales order creation BAPI BAPI_SALESORDER_CREATEFROMDAT2 (HANA 1511).
Please share the solution for this error.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pratik,
I think you have debugged the scenario and know the root cause. Just to add, you can try using <lvf_long> as a workarea, rather than a field symbol. Then, you can clear that up after every iteration.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pratik,
Ok... You are trying something like this,
LOOP
CL_MATNR_CHK_MAPPER->TABLES_CONV_TAB_INTERNAL // and you are getting the error from this Method right?
(
//
)
CALL FUNCTION 'ISSR_BAPI_BUFFER_REFRESH_ALL'.
ENDLOOP.
If the above flow is right, then , you may try using the FM - BAPI_TRANSACTION_COMMIT. This FM also works to refresh the buffer.
User | Count |
---|---|
98 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.