cancel
Showing results for 
Search instead for 
Did you mean: 

Download of production orders from SAP

Former Member
0 Kudos

Hi All,

I am working on MII v12.

The functionality is to download the production orders from SAP by passing finish date range and status. Customized BAPI is used for this.

I want to download those production orders with status 'created' or 'partially released'.

Can I do this with one BAPI call by passing both the status

or

should I call the BAPI twice with one status at a time?

Thanks,

Nalini

Accepted Solutions (1)

Accepted Solutions (1)

agentry_src
Active Contributor
0 Kudos

Hi Nalini,

That depends upon the BAPI coding. There are BAPIs which can take multiple filter criteria using fairly basic query logic. See RFC_READ_TABLE for an example. Some of the RSAQ* queries also allow filtering on multiple values. I am not an ABAP programmer, so I can't give you specific details. Since you have a custom BAPI to begin with, you should be able to modify it appropriately. Certainly, MII can present both statuses in whatever BAPI call you build, either through query logic or through multiple item segments. You can do it with two calls, but if you can do it with one, you should.

Hope this helps,

Mike

Answers (2)

Answers (2)

Former Member
0 Kudos

The solution is adapted at the BAPI side. We are passing both status together as a string. The ABAPer will parse it and send the production orders with created or partially released status.

Former Member
0 Kudos

Hi,

One of the alternative idea would be

Call BAPI_PRODORD_GET_LIST this BAPI. It has a exporting table order_header . It contains system status. From here you can get all the relevant orders and delete other orders. It is one of the work around in case of custom BAPI you have to contact the correct developer or documentation for that BAPI.

Thanks and regards,

Pradip

Edited by: Pradip Ray on Sep 26, 2008 5:48 PM

Edited by: Pradip Ray on Sep 26, 2008 5:49 PM

Former Member
0 Kudos

Nalini,

There can be multiple ways of doing this.

1. Within your transaction, set up two JCO action block and pass the filter condition 'Created' and 'PREL' seperately and map the output to two seperate XML and you can append them later.

2. Assign some Local variable and using a repeater pass the values 'Created' and 'PREL' in the JCO action block.

3. Pass the status as a string seperated by special character i.e. 'Created,PREL' and ask the ABAP developer to parse the inputs.

Hope this helps.

Raman

Raman