Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Change IDOC status from 53 to 51 <removed_by_moderator>

Former Member
0 Kudos

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

1 ACCEPTED SOLUTION

Former Member
0 Kudos

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

14 REPLIES 14

Former Member
0 Kudos

Changing status from 53 (success) to 51 (failure ) is not advisable.

Do you really want to change the status of a successful idoc ?

0 Kudos

yes

Former Member
0 Kudos

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

0 Kudos

in one peculiar case, I need to make it FAIL, wantedly!!!

thanq

Former Member
0 Kudos

Hi,

are you trying to update the status in a user exit of the IDOC posting function module?

Thanks

Naren

0 Kudos

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

Former Member
0 Kudos

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

0 Kudos

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

0 Kudos

Former Member
0 Kudos

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

0 Kudos

thanq worked out.

0 Kudos

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

Former Member
0 Kudos

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

0 Kudos

oops, sorry!! thanq.