2008 Jul 14 5:26 PM
How to chnage the IDOC status from 53 to 51, wantendly? am using the FM-IDOC_STATUS_WRITE_TO_DATABASE, but, not getting!! am doing any mistake?
thanq
Edited by: Julius Bussche on Jul 14, 2008 5:02 PM
2008 Jul 14 6:02 PM
Hi,
No..you don't have to refresh the IDOC_DATA internal table...(and not a good practice)...Just update the internal table PROCESSING_PROTOCOL with the error message..
Thanks
Naren
2008 Jul 14 5:28 PM
Changing status from 53 (success) to 51 (failure ) is not advisable.
Do you really want to change the status of a successful idoc ?
2008 Jul 14 5:38 PM
2008 Jul 14 5:30 PM
Hi,
You can use the IDOC to re-create the scenario in WE19..Is that what you are trying to do...please clarify..
Thanks
Naren
2008 Jul 14 5:39 PM
in one peculiar case, I need to make it FAIL, wantedly!!!
thanq
2008 Jul 14 5:41 PM
Hi,
are you trying to update the status in a user exit of the IDOC posting function module?
Thanks
Naren
2008 Jul 14 5:46 PM
yes,
am using th FM - IDOC_INPUT_DELVRY
using exit is ZXTRKU13
my code is
if chnage_status = 'X'.
CALL FUNCTION 'IDOC_STATUS_WRITE_TO_DATABASE'
EXPORTING
idoc_number = delivery_idoc_num
IDOC_OPENED_FLAG = ' '--->commmnet
NO_DEQUEUE_FLAG = 'X'
IMPORTING
IDOC_CONTROL =
tables
idoc_status = BDIDOCSTAT
endif.
do am passing paras correctly?
thanq
2008 Jul 14 5:50 PM
Hi,
Try this..
In your user exit EXIT_SAPLV55K_005...populate the parameter PROCESSING_PROTOCOL with the error message along with the message type as 'E'...check if sap automatically updating the IDOC with 51 status records..
Thanks
Naren
2008 Jul 14 5:59 PM
now, I used, REFRESH idoc_data table, then am getting status as 51.
but, i dont know that, is it safer & recommended practice, but, am in urgent need.
anyways, will try ur idea.
thanq
2008 Jul 14 6:02 PM
http://dictionary.reference.com/browse/wantedly ?
Nice touch though
2008 Jul 14 6:02 PM
Hi,
No..you don't have to refresh the IDOC_DATA internal table...(and not a good practice)...Just update the internal table PROCESSING_PROTOCOL with the error message..
Thanks
Naren
2008 Jul 14 6:45 PM
2008 Jul 14 6:49 PM
thanq
so, How Can I know that, there is processing_protocol table for use in exit?
bcoz, i did not see in export/import for exit FM.
so, is it comes by experience? or any other alternative to find out that, wht the wa itbas variables r available at the point in the exit?
bcoz, same thing was happened to me in another case, like in exit, ZXVEDU11 of there is NOT mentioned anywhere that, the DXVBAK structure is availbale for use!! actually, its available, we can use it, for looking data like BUKRS, VKORG etc.!!
thanq
2008 Jul 14 6:52 PM
Hi,
The include ZXTRKU13 is available in the user exit FM EXIT_SAPLV55K_005 ...And the function module is having one of the exporting parameter as PROCESSING_PROTOCOL.
Thanks
Naren
2008 Jul 14 7:10 PM