2011 Jul 13 10:28 AM
Dear experts,
Now i am facing a problem on change park document in background coding, simulating the function provided by tcode FBV2, i tried many functions which seem to be working, but none succeeded. I also found some posting on SDN which show that some people have the same problem as i do, but till now nobody get resolved. So again i have to ask: is there any BAPI or FM to cover this issue?
2011 Jul 13 10:31 AM
Try using the following fm
PP_CHANGE_DOCUMENT_ENJ..,PP_CHANGE_DOCUMENT_FBV2_ENJ.
For more FM check the function group F040 where you can find all related FM.
Nabheet
2011 Jul 13 11:01 AM
thanks for the reply, i debugged after "SAVE" in FBV2, and also found "PP_CHANGE_DOCUMENT_ENJ", i tried this funtion even with exactly the same parameters while debugging, but it still threw out the exeption "Update was terminated " with error info "SAPSQL_ARRAY_INSERT_DUPREC" ...
2011 Jul 13 11:03 AM
Does it throw the error when you it from the tcode also..? please search for oss notes for the same. Make sure the data passes is the same.
Nabheet
2011 Jul 14 2:46 AM
it is alright using the standard TCODE(FBV2), just failure during the attempt to simulate changing park document...
2015 Jun 02 9:36 AM
Hi Guru's,
We are facing the similar requirement. I have tried so many FM/BAPI to change the Parked FI data but didn't get success yet. We currently using the BDC to update parked document via FBV2 but there are plenty more complication keep on coming because of different screens for different document types and all.
If anyone found any FM/BAPI or Class/method please provide the same for all.
Thanks
2015 Aug 23 2:14 PM
Hi,
Even I have similar requirement. I need to change the posting date of Parked document. Parked document can be created by either FBV1, FB50, FB60 or FB70
I have follwed harry huang and used the FM 'PP_CHANGE_DOCUMENT_ENJ' to change the parked document. Even I have faced similar issue 'Update was terminated " with error info "SAPSQL_ARRAY_INSERT_DUPREC" ...
Issue - Update termination occurs due to parking document already exists and FM 'PRELIMINARY_POSTING_DOC_WRITE' tries to insert same document instead of updating it.
Reason - Table 'XVBSEG' does not have any value for field 'bzalt', this field should have similar value to line item number ' buzei'.
Solution - I came up with a solution to this problem. Call the FM 'PP_CHANGE_DOCUMENT_ENJ' and use a BTE '00002217' to update the value of bzalt with buzei in internal table of XVBSEG. Guess what it worked for me.
Regards,
Siva