cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI_MATERIAL_STOCK_REQ_LIST

Former Member
0 Kudos

Hello, i am new to ABAP and i need your help.

I have requirement to read all open purchase orders, open deliveries and open purchase requisitions for some specific plant and material.

i think that all of this could be achieved over FM BAPI_MATERIAL_STOCK_REQ_LIST, but i am not completely sure how.

Open purchase order should be retrieved form structure type bapi_mrp_stock_detail - field rec_reqd_qty.

I am not sure how open deliveries and open purchase requisitions should be retrieved and i need your help with this.

Thank you in advance

Accepted Solutions (1)

Accepted Solutions (1)

Caetano
Product and Topic Expert
Product and Topic Expert
0 Kudos

Yes, you can use the mentioned BAPI to read these MRP elements.

Just run the BAPI using the material and plant as input parameters and you will find all the open MRP elements on the return table MRP_IND_LINES.

Here, you should filter the desired MRP elements using the field MRP_ELEMENT_IND. You can check the possible values for this field opening the domain DELKZ on transaction SE11 and checking the value range.

Regards

Caetano

Former Member
0 Kudos

Hi Caetano.

First of all - thank you for your reply.

Actually i am already using this BAPI and i have filtered desired MRP elements (i need values 'BE' and 'BA').

I have already successfully pulled value of open purchase order from field  mrp_ind_lines-rec_reqd_qty.

Now i need to pull value of open deliveries but i don't know from which field (or more fields should be combined for this) - that is the main problem.

Best regards,

Tomislav

marianoc
Active Contributor
0 Kudos

Hi,

The open delivery quantity is seen in field: MRP_IND_LINES-REC_REQD_QTY and the delivery orders are the MRP element. VJ.

Kind Regards,

Mariano

Former Member
0 Kudos

Hi Mariano,

Thank you very much, this was helpful answer.

Can the open purchase requisitions be calculated on the same way maybe?

From which field and which MRP element?

Best regards,

Tomislav

marianoc
Active Contributor
0 Kudos

Hi,

Yes this can be done for purchase requisitions too.

You can see MRP elements in table: V457T.

Kind Regards,

Mariano

Answers (1)

Answers (1)

solomon_macwan
Active Contributor
0 Kudos

hi Tomislav,

once you create purchase order from open purchase req, the purchase req will be replaced by the purchase order in stock req list.

for purchase req status check table. - EBAN

for delivery header status - VBUK

for delivery item status - VBUP

if you want bapi - then check.

BAPI_REQUISITION_GETDETAIL     Display Purchase Requisition Details

regards,

Solomon

Former Member
0 Kudos

Hi Salomon,

Thank you for clarification.

For purchase requisition i have solved that with select on tables.

I still cannot find open deliveries (i need quantity), and i have only WERKS and MATNR.

I believe that this value can be found through BAPI_MATERIAL_STOCK_REQ_LIST (Tables mrp_ind_lines) but I'm not sure which field refers to opened deliveries.

Best regards,

Tomislav

solomon_macwan
Active Contributor
0 Kudos

hi Tomislav,

same as purchase requisition, when you do the post goods issue for the delivery..it will no more display in the stock requirement list.

you can check the status in  Table VBUP -  WBSTA where A=not processed and C=completed.

regards,

Solomon