‎2009 Oct 22 6:25 PM
Hello everybody,
I got this problem: I need to create a program that changes the value of an IDOC. My question is: is there any function like "IDOC_STATUS_WRITE_TO_DATABASE" that can do something like this?
What I want to do is the same thing that when I do this in tx WE19.
Is this posible with a function?
If you don't understand what do I mean, I'll tell this: I want to change the value of a field from an incoming IDOC (for example, the DATE), and I would like to know if there is any function that can do this or if there is any way to do this in abap and not from tx WE19.
any idea?
‎2009 Oct 22 6:46 PM
Hi,
Your inbound IDOC should be coming to a Inbound Process Code Functional Module. Look if you can use any Enhancement there if it is a SAP Standard FM, and in case you only written this FM then you can definitely do this in the same FM.
‎2009 Oct 22 6:46 PM
Hi,
Your inbound IDOC should be coming to a Inbound Process Code Functional Module. Look if you can use any Enhancement there if it is a SAP Standard FM, and in case you only written this FM then you can definitely do this in the same FM.
‎2009 Oct 22 6:57 PM
Hi,
Use the following func modules:
EDI_DOCUMENT_OPEN_FOR_EDIT
EDI_CHANGE_DATA_SEGMENTS
EDI_DOCUMENT_CLOSE_EDIT
For simplicity you cancreate a func module of your own and call these internally.
Regards,
Subramanian
‎2009 Oct 22 7:03 PM
Hi There,
Its inbound idoc so process code might have been attached and you can check the function module attached to the process code. If its Z function module you can make changes there .Moreover there are whole bunch of enhacment on the message type and function module where you can change the values. Please implement user exit and make changes there.
Regards,
Nirad Pachchigar
‎2009 Oct 22 7:16 PM
Sorry that I didn't tell: the idoc is a Z idoc.
And the idoc was sent to SAP and some of them got a problem because the date wasn't sent ok, so my idea is to change manually this date with a report that I'm doing (or maybe a function, I'll see what's best).
I'm going to review the answers here, and if you got another solution or another idea, please tell it to me.
Thank you all for replying.