Field "Open Quantity" is empty on ME23N
Hello,
I am running the BAPI_GOODSMVT_CREAT for "Purchase Order", and when i go to ME23N, the field "Open Quantity" of item is empty.
I'm usind this parameters:
t_bapiitem-material = v_ematn.
t_bapiitem-plant = t_ba-werks.
t_bapiitem-stge_loc = t_ba-lgort.
t_bapiitem-move_type = t_ba-bwart.
t_bapiitem-entry_qnt = t_ba-erfmg.
t_bapiitem-entry_uom = v_meins.
t_bapiitem-po_number = t_ba-po_number.
t_bapiitem-po_item = t_ba-ebelp.
t_bapiitem-shipping = '01'.
t_bapiitem-comp_ship = t_ba-norm_exp.
t_bapiitem-no_more_gr = 'X'.
t_bapiitem-mvt_ind = 'B'.
t_bapiitem-unload_pt = t_ba-unload_pt.
t_bapiheader-ref_doc_no = t_ba-nota_de_remessa.
t_bapiheader-header_txt = t_ba-txt_cab.
t_bapiheader-pstng_date = t_ba-dtlanc.
t_bapiheader-doc_date = t_ba-dtdoc.
Anyone Help me ?
With regards,
Reginaldo Borges
Hi,
Try use:
t_bapiitem-no_more_gr = ' '.
Best regards,
Leandro Mengue
Similar Messages
-
BAPI for PURCHASE ORDER with OPEN QUANTITY field
Hi All,
I wanted to use the BAPI_PO_GETDETAIL to get the Purchase Order details upon triggering from Warehouse management system,
But the details required contains a field called OPEN QUANTITY...which is not used in this BAPI.
I request to let me know if any BAPI exits for PO details having the structure for this field:Open Quantity.
Am using SAP version 4.0B.
If not exists please advise how to customize the existing BAPI to meet the requirement.
thanks
mahiHi,
Open quantity is a calculated field. I guess the BAPI gives the details of the delivery, so take the ordered qty and substract the delivered qty from that.
Delivery data is EKET table.
Regards,
Ravi -
Hi,
could any one let me know if there is any table and field that stores teh value of the open quantity in deliery.suppose say for a partcular sales order there were N number of delivery made and when N+1 th delivery is done i want to make validation say want to compare teh delivery quantity entered with the open item(the items tht are pending to be delivered as per the sales order).For this i want to know the field and the table in which the open item(the pending delivery item for the sales order ) is stored.
Cn any on ehelp me iwth this.Hi Sudha,
If partial delievry is allowed in the system, then multiple deliveries may exist for each sales order.
Using the sales order and item number as the key, you can get the delivery quiantities for each of those partial deliveries.
select vbeln vbelp LFIMG
from lips into table it_lips
for all entries in it_vbap
where KDAUF = it_vbap-vbeln
and KDPOS = it_vbap-POSNR.
loop at it_vbap.
lv_index = sy-index.
clear quant_delivered.
loop at it_lips where KDAUF = it_vbap-vbeln
and KDPOS = it_vbap-POSNR.
quant_delivered = quant_delivered + it_lips-LFIMG.
endloop.
it_vbap-openqty = it_vbap-KWMENG - quant_delivered.
modify it_vbap index lv_index.
endloop.
Regards,
Ravi -
GR Quantity/ Open Quantity
Transaction Code - ME23n
Purchase order item details.
Which SAP tables store GR quantity and Open quantity?
Thanks,
Pratibha.Hi,
All the GRd materials in the PO are stored in EKBE table. BPMNG is field which will have the GR qty. then you can calculate the open qty by taking the actual qty and the GRd qty. -
Purchase Order Open quantity calculation.
Hi All..
I would like your help in finding out the logic behind calculating the open quantity for a given line item of a purchase order.
Iam aware that i should go to the EKBE table to see purchase order history. Can someone tell me what are all the conditions i need to consider to calculate the Open quantity.
Iam able to give a value E to field BEWTP (Purchase Order History Category) in EKBE and for all the recieved records iam adding the quantity for movement type 101 and removing the quantity for movement type 102 that finally gives my total GR qty. Then iam doing Original PO qty - GR qty to get the Open qty.
Let me know if this logic is wrong or else is there any other conditions to consider.
Appreciate your help and will reward.
THanks.subtract the PO quantity EKPO-MENGE with the delivery quantity field EKET-GLMNG
Thanks
Seshu -
Hi,
I am making one report for open purchase order quntity.But there is some problem
In delivery shedule tab of purchase order,If delivery date is in future, that purchase order quantity
also shown by system as open quantity. So whether this open quantity is taken into account or not.
So please guide me.
Thanks and Regards
AnilHi,
You can also user other transaction for open purchase order quantity.
Enter ME2M t-code.
Then select WE101 in selection parameter option and click on execute button.
Then go in change layout option and take To Be Delivery quantity field in display mode.
You can see open purchase order quantity.
I hope it is useful for u.
Regards,
Mahesh Wagh -
Hi,
I need to get open quantity for each sales order in my Z report. Is there any field to store it or i need to calculate it. How can i do that, Thanks!Hi..
check the below code to get the open quantity.
open quantity = ordered quantity - delivered quantity
Fetch delivery information
SELECT vbeln posnr vgbel vgpos lfimg
FROM lips
INTO TABLE gt_lips
FOR ALL ENTRIES IN gt_vbap
WHERE vgbel = gt_vbap-vbeln AND
vgpos = gt_vbap-posnr.
*Compute delivered qty
LOOP AT gt_lips INTO st_lips WHERE vgbel = st_details-vbeln AND
vgpos = st_details-posnr.
gv_lfimg = gv_lfimg + st_lips-lfimg.
CLEAR st_lips.
ENDLOOP.
st_details-open_qty = st_details-ord_qty - gv_lfimg.
i guess you know how to get the ordered quantity for the sales order item.
Award points if found useful.
Regards
Divakar -
Material Confirmed quantity and Open quantity
Hi All,
I am working on a report where the user wants the material confirmed quantity and open quantity at the batch level. I know for open quantity VBBE-OMENG can work. Just need confirmation that this is the correct field. However for confirmed quantity I am not able to narrow it down to one field. I have the following fields as possibilities but not sure which is the right one.
1) VBBE-VMENG
2) VBEP-BMENG (This is the at the sales order level though. We need it at the batch level)
Can you please let me know if i have the right approach here? The report has Material, plant, sloc and batch along with a bunch of other fields.
Regards.
SidHello,
you should extract the quantities from all the deliveries selected for material and batch, and selecting only open deliveries.
Use a selection like this:
SELECT lips~MATNR lips~WERKS
lips~CHARG lips~LFIMG
INTO TABLE lt_lips
from lips as lips
INNER JOIN vbup as vbup
on lips~VBELN = vbup~VBELN AND
lips~POSNR = vbup~POSNR
WHERE lips~MATNR = p_matnr
AND lips~WERKS = P_WERKS
AND lips~CHARG = P_CHARG
AND ( vbup~WBSTA eq 'A' or
vbup~WBSTA eq 'B' ).
Best regards,
Andrea -
Hi Guys,
I have PO quantity(EKPO-MENGE) and goods receipt quantity(MSEG-ERFMG). Here i want to calculate the open PO quantity which is EKPO-MENGE - MSEG-ERFMG .But here if multiple material docements r getting created for the same for one PO and partial goods receipt quantity is done thru these multiple material documents. then how to net the open quantity.
For example :
PO no PO quantity material documents GR quantity
10 10 100 1
200 2
300 -2
400 3
Now i need the open quantity as 9
7
9
6.
Even i tried with At new Ebeln.but i am not getting it.
Can anybody help me in this.Hi,
Open PO Line Item Qty = PO Line Item Qty - ( Sum(All GR Qty for PO Line Item ) -
Sum(All GR Return Qty for PO Line Item) ).
PO Line Item Qty = EKPO-MENGE.
GR QTY for PO Line Item = EKBE-MENGE with Movement Type = '101'.
GR Return QTY for PO Line Item = EKBE-MENGE with Movement Type = '102'.
SELECT EKPOMENGE EKPOMEINS
FROM EKKO INNER JOIN EKPO ON EKKOEBELN = EKPOEBELN
INNER JOIN EKET ON EKETEBELN = EKPOEBELN AND
EKETEBELP = EKPOEBELP
INNER JOIN LFA1 ON LFA1LIFNR = EKKOLIFNR
INTO CORRESPONDING FIELDS OF TABLE I_PO
WHERE EKKO~BUKRS = P_BUKRS AND
EKPO~WERKS = P_WERKS AND
EKKO~LIFNR IN S_LIFNR AND
EKPO~MEINS IN S_MEINS AND
EKET~EINDT IN S_EINDT AND
EKKO~BSTYP = 'F' AND "Select PO Only"
EKKO~LOEKZ = ' ' AND "PO should not be deleted"
EKPO~LOEKZ = ' ' . "Line Item Should not be DEL
Fetch the PO History Details for the Records of the Internal Table i_po.
LOOP AT I_PO.
SELECT EBELN EBELP BWART MENGE WRBTR
FROM EKBE
APPENDING CORRESPONDING FIELDS OF TABLE I_EKBE
WHERE EBELN = I_PO-EBELN AND
EBELP = I_PO-EBELP AND
BEWTP IN ('E','F').
ENDLOOP.
Edited by: AJAY TIWARI on Oct 19, 2008 5:00 PM -
How to change the open quantity of PO / STO using BAPI_PO_CHANGE
Hi Friends,
How can I change the open quantity in ME22 using the BAPI BAPI_PO_CHANGE...
I am getting some errors..The values I am passing to the BAPI are:-
*-- Purchase Order document
lv_purchaseorder = tbl_join-ebeln.
*-- Calculate Open quantity
lv_quantity = ( tbl_join-menge - tbl_join-wemng ).
*-- Fills Schedule quantity to be processed.
tbl_poschedule-po_item = tbl_join-ebelp.
tbl_poschedule-sched_line = tbl_join-etenr.
tbl_poschedule-quantity = lv_quantity.
APPEND tbl_poschedule.
*-- Marks the Schedule quantity to be processed.
tbl_poschedulex-po_item = tbl_join-ebelp.
tbl_poschedulex-sched_line = tbl_join-etenr.
tbl_poschedulex-po_itemx = c_true.
tbl_poschedulex-sched_linex = c_true.
tbl_poschedulex-quantity = c_true.
APPEND tbl_poschedulex.
CALL FUNCTION 'BAPI_PO_CHANGE'
EXPORTING
PURCHASEORDER = lv_purchaseorder
POHEADER =
POHEADERX =
POADDRVENDOR =
TESTRUN = 'X'
IMPORTING
EXPHEADER =
EXPPOEXPIMPHEADER =
TABLES
RETURN = tbl_return
POSCHEDULE = tbl_poschedule
POSCHEDULEX = tbl_poschedulex.
Is there any other required fields needs to be passed to change the open quantity..
I am checking in ME22...
The scheduled quantity is 20.
Delivered quantity is 15.
Open quantity is 5 and ( this field is in non-editable display )
Delivery date is 10.10.2002 ( which is in past )
Now using this BAPI ..I want to post the remaining open quantity which is " 5 "
How can i do this ?? Please help.Hi Hari
Please check after making the following changes:
*-- Marks the Schedule quantity to be processed.
tbl_poschedulex-po_item = tbl_join-ebelp.
tbl_poschedulex-sched_line = tbl_join-etenr.
<b>tbl_poschedulex-po_itemx = 'U'. "c_true.
*tbl_poschedulex-sched_linex = c_true.</b>
tbl_poschedulex-quantity = c_true.
APPEND tbl_poschedulex.
If still you do not get the desired function working add the below code:
tbl_poitem-po_item = tbl_join-ebelp.
tbl_poitem-quantity = lv_quantity.
append tbl_poitem.
tbl_poitemx-po_item = tbl_join-ebelp.
tbl_poitemx-po_itemx = 'U'.
tbl_poitemx-quantity = c_true.
append tbl_poitemx.
Hope this helps.
Kind Regards
Eswar -
Hi..
I would appreciate your help on how i can derive the open quantity for a given PO at the line item level. I cannot find any field in the EKPO table.
Also if there is batch specified for the material at the line item level on the PO , how i can retrieve the Batch number.
I would like if someone can explain what tables are linked and how it can be extracted.
Thanks and will reward the helpful answers.Look for the goods receipts and invoice receipts in table EKBE.
Rob -
Open quantity in credit memo and debit memo
Dear Friends,
I am facing one problem in billing cycle. I am creating credit memo directly with ref to invoice(With out cr memo request). I am describing scenario below.
I have created Invoice 8012003 with one item with 10 quantity, after that I am creating credit note with ref to Invoice no 8012003, here I am creating credit note with 3 qty. Sub subsequently when i create credit note with ref to invoice number 8012003, in open billing quantity system is showing 10 quantity instead of 7.
I have used copy requirements 027 and billing quantity field is disabled.
Kindly advice.
KaushalHello ,
you could check the field VBRP-POSAR in your credit note .
If it's 'A' , it's only a value position.
That could come from table TVAU , field VAUNA -
the last part in copy requirement 027 .
Regards Wolfgang
Dear Wolfgag,
Thanks a lot for your kind reply, k've checked, VBRP-POSAR is 'A' in and VBRP - AUGRU AUFT is blank. Please let me know whether order reason is affecting open quantity field or i've modify routine 27 for passing value ' '(Standard Item) instead of 'A'(Value item).
Please note that i am creating credit memo direct ref to invoices.
Thanks a lot in advance.
Kaushal -
2LIS_11_V_SCL: Open Quantity to be delivered wrong
Hi,
I have a problem with the field OLFMNG _ Open Quantity to be delivered of the 2LIS_11_V_SCL datasource.
In particular, when upload data into an OSD Object the field OLFMNG is not correct,
Data are loaded in Overwrite role.
Any help would be greatly appreciated.
Thanks,
ValeriaIn same cases the field OLFMNG is not update. For example in R/3 I have 400 PZ order Qty and 400 PZ delivered Qty, so the Open quantity to be delivered should be 0, while in BW the field OLFMNG is 400 PZ.
I believe that the problem is in BW update Rules, which it should be in additional mode and not in overwrite, but I'm not sure. -
Updating oOrders open quantity
Hi Experts,
I am creating a Delivery Receipt based on a specific Sales Order thru DIAPI. My problem is my Sales Order open quantity per line is not updating when its reference DR quantity is less than on the Sales Order document. Is there a property I am missing?
Please help.
Regards,
RogerHi Gordon,
Here is my sub procedure that creates a Delivery from a Sales Order with its Draft - Delivery document.
- The Delivery document's lines will depend on the Draft-Delivery lines versus the Sales Order document's lines.
Please help me on how will my Sales Order remaining open quantity will be updated depending on its matched item on the Draft-Delivery document's lines.
public SAPbobsCOM.Documents PostDeliveryReceipts(SAPbobsCOM.Company company, SAPbobsCOM.Documents draft, SAPbobsCOM.Documents salesOrder, BusinessObjects.Shipment shipment, ref int result)
SAPbobsCOM.Documents delivery = (SAPbobsCOM.Documents)company.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oDeliveryNotes);
delivery.HandWritten = SAPbobsCOM.BoYesNoEnum.tYES;
delivery.DocNum = draft.DocNum;
delivery.CardCode = salesOrder.CardCode;
delivery.DocDate = shipment.ShipmentDate;
delivery.UserFields.Fields.Item("U_smc_shipNo").Value = shipment.ShipmentNumber;
int tmp_baseline = 0;
for (int i = 0; i <= salesOrder.Lines.Count - 1; i++)
salesOrder.Lines.SetCurrentLine(i);
draft.Lines.SetCurrentLine(i);
if (salesOrder.Lines.TreeType != SAPbobsCOM.BoItemTreeTypes.iIngredient)
delivery.Lines.ItemCode = draft.Lines.ItemCode;
delivery.Lines.Quantity = draft.Lines.Quantity;
delivery.Lines.BaseEntry = salesOrder.DocEntry;
delivery.Lines.BaseLine = tmp_baseline;
delivery.Lines.BaseType = Convert.ToInt32(SAPbobsCOM.BoObjectTypes.oOrders);
delivery.Lines.Add();
tmp_baseline++;
result = delivery.Add();
return delivery;
Edited by: Roger Arce on Jan 19, 2011 8:53 AM -
Open quantity for scheduling lines
Hi,
I need calculate open quantity from scheduling lines(based on date) for Scheduling Agreement (similar like VL10I works). I noticed that open quantity is not maintain in VBEP. So could you help me?
BR,
ZHi,
For calculating open quantity for scheduling lines ,u need to query the sales order number in table VBUK and check the field GBSTK , it will be an open order .
You can look in table VBAKUK for this .
This is Join of VBAK and VBUK entries. You can eliminate a join if you fetch it from VbakUk
Now once it is confirmed that it is open then fetch the entries from VBAP.
Hope it helps you.
Thanks,
Sarita Singh
Maybe you are looking for
-
Since updating to Firefox 13 it not only runs slow but hangs and becomes non-responsive on all different websites. I was told that the most recent Flash update was known to be incompatible with Ffx 13, so down-dated Flash and uninstalled non-essentia
-
Hi Experts , Is it possbile to stop and start the Sun cluster as like VCS (hastop and hastart). Regards, R.Rajesh Kannan.
-
Flash transparency in Firefox?
I have a flash navigation menu and a flash app right underneath it, but the transparency modes are not working in firefox. They work fine in IE though. You can get a better understanding of what I mean by viewing the page. You'll notice that in Fi
-
MacBook Pro freezes during installation of 10.6.8 supplement
Ran Software Update to install the 10.6.8 supplemental update on my 15 inch MacBook Pro (late 2006), which already had 10.6.8 installed (and the 2 GB factory RAM). After restart, the computer hung at the gray screen with apple logo and spinning cog.
-
Print Crash on Intel Macs but not on PPC Macs
I have two MacBooks exhibiting the same problem. When I try to print from nearly any application over the network, the application quits when I try to print. I restart the application and it usually prints. The printer I try to print to is an HP Desk