cancel
Showing results for 
Search instead for 
Did you mean: 

Inbound Idoc processing

Former Member
0 Kudos

Hi EDI Gurus,

I have a requirement for inbound idoc processing for 830 and 862 and 850. We are not using Immediate processing.

We want to have executable program for processing the idoc received, and result "SALES ORDER" created.

could any body have a code for this interface program,

please give me the code.

Any quick suggestion will be higly appreciated.

Thanks for the help,

Praveen

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Looks like you are not planning to set the status of iDoc to posted at all though you use that iDoc to create the Sales order.

I that case simply call the FM IDoc_input_orders with the Control record and IDoc data internal table and put a commit statement after the function call. Do not save the control record & status records returned by FM into DB (this set the status accordingly based on success or failure of Sales order creation).

For setting the future date in any of the date field, change the corresponding segment in the iDoc_data internal table before the FM call. That should work for you.

Regards,

Nagaraju Chidurupalli

Message was edited by: Nagaraju Chidurupalli

Former Member
0 Kudos

HI Nagaraju,

I really appreciate if you provide some code regarding using the function module "IDOC_INPUT_ORDERS".

Could you please help me.

Regards,

Praveen

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Instead of re-inventing the wheel, I would suggest you that you call RBDAPP01 for processing the iDoc to creating the IDoc from your Z-program when ever you want (using submit statement and pass the iDoc number as parameter).

Hope this helps.

Regards,

Nagaraju Chidurupalli.

Former Member
0 Kudos

Hi,

There is already a standard sap transaction for this. Use BD20 transaction or RBDAPP01 program.

If this is not what you are looking for then give full details of requirement.

Regards,

Nagaraju Chidurupalli

Former Member
0 Kudos

Thanks for your quick reply. But we dont want to do the standard processing. we want to have z-program which reads the Idoc data and creates a sales order using the idoc data. We using this because we have some more processing before creating the sales order.

Former Member
0 Kudos

Then you want to have a Z-function module for your idoc processing, if I understand correctly.The steps should be:

1. Create a z function module for idoc inbound posting (copy from a function module idoc_input_*).

2. Set Function Modules as Inbound: - Transaction BD51

3. Assign Function Modules to Logical Messages and Idoc types:- Transaction WE57

4. Create process codes : Transaction WE42, and link the z-function module.

5. Create partner profile: transaction WE20 and attach the message type and process code.

6. In the Z- function module, extract data from the idoc segments, do whatever processing you want to do, and then call BAPI_CREATE_SALES_ORDER_FROMDAT2.

nablan_umar
Active Contributor
0 Kudos

Hi Preveen,

Try looking at the idoc user exits instead of creating a custom program.

Former Member
0 Kudos

Thanks Sandeep, its really helpful. But we are not planning for automatic posting. The requirement is like that customer will send the purchase orders for the same sales request multiple times with future date.

we have to cut the sales order only for one purchase order, even if we have multiple inbound idocs.

my z-program includes steps 1)select the idoc data from tables using the selection screen data.

2) display a report with check box so that end user can selct one among the list to cut the sales order.

So for creating a sales order i can use the "BAPI_CREATE_SALES_ORDER_FROMDAT2".

could you give me some code if u have with multiple items.

We have some z-fields i hope this function module can handle those fields.

We have to create salesorder against quantity contract, we have some userexits, does the userexits will be executed with this function module???

Please give me some details for the above.

Thanks & Regards,

Praveen

Former Member
0 Kudos

Praveen,

1. The FM can handle Z-fields.no problem. Only you have to pass it correctly in EXTENSIONIN sturcture.

2. There are a few user exits which are covered by this FM, I am not sure which ones are you talking about. But to know specifically, put a brk-pt in the exit and try to run the BAPI in SE37 and see if it gets triggered.

Former Member
0 Kudos

Sandip,

If i use the function module which you mentioned,wht is the procedure for creating salesorder reference to a contract.

Please help me, i am bit confused which functionmodules suites my requirement.

I am breaking the INBOUND IDOC to display a alv report with check box so user can select some line items (with same material) from across the idocs to create a sales order.

Please suggest me which one is the best option.

Regards.

Praveen