PGI for returns using WS_DELIVERY_UPDATE
Hi Friends,
I'm using the FM WS_DELIVERY_UPDATE to do PGI for outbound deliveries. It is not doing the PGI for returns delivery. Can someone help me on how to use this FM for returns delivery PGI or is there any other FM to do this. I do not want to use BDC.
Appreciate your <removed by moderator> response.
Thanks,
Dikshitha G
Edited by: Thomas Zloch on Jul 7, 2011 12:49 PM
Use FM WS_LM_GOODS_MOVEMENT, pass the parameter IF_BITYPE = 'N'. Pass the table parameter CT_WORKTAB of type LIPOV. You can get the data from LIKP. The picking has to be complete on delivery. Use FM WS_DELIVERY_UPDATE to complete picking.
Similar Messages
-
Problem with pgi for returns delivery
Hi,
I'm trying to do PGI for returns delivery through BAPI_GOODSMVT_CREATE.
The when the delivery is opened through VL02N, the Post Goods Issue button has Post Goods Receipt text written on it. When the GI is done, the material document has movement type 651.
However I'm not able to create the same through the BAPI. I have tried various combinations of GM_CODE and all other variables. Have anybody of you tried doing movement type 651 for a returns delivery using the same BAPI?
Please reply if you've come across some similar situation. I know how to use the BAPI, I've been using it successfully for other movement codes etc. It's only in this case that I'm stuck up.
Regards,
VijayHi Vijay,
can u pls tell me how did u do it....i am also having the same requirement....
Developed a custom program for creating and updating Goods Movement Document by using BAPI_GOODSMVT_CREATE & WS_DELIVERY_UPDATE_2.
thanks, Ankita. -
Unable to do the PGI for Returnable Packing Goods
Dear Guru's
I have posted a Returnable packing goods in MB1C with movement type 561, Stock indicator is V But it was posted in
Returnable Packing Cust Unrestricted .
while i am raising the Delivery with Reference to order i am unable to do the PGI. It is getting with Deficit of SL Unrestricted is nil .
How to go further . pls help me
Thanks in Advance.
suribabuDear Guru's
I have completed the PGI for material with Returnable Packing Goods
while in MB1C with Movement Type 561 & With out mention the Special Stock ' V ' .
But in which case we use the SPECIAL STOCK Indicator . can anybody Brief me.
Thank you in Advance.
Regards
suribabu -
Problem while doing PGI for Returns Delivery
Hi,
We are facing some problem which doing PGI for a returns delivery. Our scenario is HU and WM managed. After creation of delivery I have created a TO and has two different valuation type of same material. Total quantity in TO is 2, 1 of each valuation type. So, automatically, batch split happened for the line item in delivery.
Now when I am trying to do PGI for this delivery, I get en error message saying "Enter Valuation Type". The movement type used here is 161 (Vendor Returns)
Same thing is happening successfully for movement type 643 (Transfer inter company code). What I can gather is that while creating 161 document against delivery system is not automatically taking the valuation types mentioned in line item of delivery.
Let me know possible reasons for this error and resolution.
Regards,
VishalImplement the OSS note 965985
-
Error while doing PGI for Outbound delivery using BAPI BAPI_GOODSMVT_CREATE
Hi All,
I am getting an below error while doing PGI for outbound delivery using the BAPI BAPI BAPI_GOODSMVT_CREATE:
Goods movement not possible with mvmt type 601
Can anyone suggest me what will be the solution for it?
Regards,
Raghuraman.kI tried with the above BAPI but it is not working.
In my case a delivery has one line item with batch split and other line item without batch split.
Below is my code :
DATA : gwa_header_data TYPE bapiobdlvhdrcon,
gwa_header_ctrl TYPE bapiobdlvhdrctrlcon,
lv_delivery TYPE bapiobdlvhdrcon-deliv_numb,
git_item_data TYPE STANDARD TABLE OF bapiobdlvitemcon,
gwa_item_data TYPE bapiobdlvitemcon,
git_item_ctrl TYPE STANDARD TABLE OF bapiobdlvitemctrlcon,
gwa_item_ctrl TYPE bapiobdlvitemctrlcon,
git_return TYPE STANDARD TABLE OF bapiret2,
gwa_return TYPE bapiret2.
*Header data
gwa_header_data-deliv_numb = '0808000002'.
*Header Control data
gwa_header_ctrl-deliv_numb = '0808000002'.
gwa_header_ctrl-post_gi_flg = 'X'.
*Delivery Number
lv_delivery = '0808000002'.
*Item data and its corresponding control data
gwa_item_data-deliv_numb = '0808000002'.
gwa_item_data-deliv_item = '900002'.
gwa_item_data-dlv_qty = 4.
gwa_item_data-dlv_qty_imunit = 4.
gwa_item_data-fact_unit_nom = 1.
gwa_item_data-fact_unit_denom = 1.
APPEND gwa_item_data TO git_item_data.
gwa_item_ctrl-deliv_numb = '0808000002'.
gwa_item_ctrl-deliv_item = '900002'.
gwa_item_ctrl-chg_delqty = 'X'.
APPEND gwa_item_ctrl TO git_item_ctrl.
gwa_item_data-deliv_numb = '0808000002'.
gwa_item_data-deliv_item = '900003'.
gwa_item_data-dlv_qty = 6.
gwa_item_data-dlv_qty_imunit = 6.
gwa_item_data-fact_unit_nom = 1.
gwa_item_data-fact_unit_denom = 1.
APPEND gwa_item_data TO git_item_data.
gwa_item_ctrl-deliv_numb = '0808000002'.
gwa_item_ctrl-deliv_item = '900003'.
gwa_item_ctrl-chg_delqty = 'X'.
APPEND gwa_item_ctrl TO git_item_ctrl.
gwa_item_data-deliv_numb = '0808000002'.
gwa_item_data-deliv_item = '000020'.
gwa_item_data-dlv_qty = 10.
gwa_item_data-dlv_qty_imunit = 10.
gwa_item_data-fact_unit_nom = 1.
gwa_item_data-fact_unit_denom = 1.
APPEND gwa_item_data TO git_item_data.
gwa_item_ctrl-deliv_numb = '0808000002'.
gwa_item_ctrl-deliv_item = '000020'.
gwa_item_ctrl-chg_delqty = 'X'.
APPEND gwa_item_ctrl TO git_item_ctrl.
BREAK-POINT.
CALL FUNCTION 'BAPI_OUTB_DELIVERY_CONFIRM_DEC'
EXPORTING
header_data = gwa_header_data
header_control = gwa_header_ctrl
delivery = lv_delivery
TABLES
item_data = git_item_data
item_control = git_item_ctrl
return = git_return.
BREAK-POINT.
IF git_return IS INITIAL.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
ENDIF. -
Reg : PGI delivery using ws_delivery_update
Hi All,
I want to PGI delivery using function module ws_delivery_update .
What are the mandatory fields to be supplied and in what way to PGI delivery successfully using the above FM
Or is there any other function module specifically suited to PGI delivery
urgent help needed.
if any sample code is there , most welcome.
Thanks in advance.
Regards
JawaharJawahar,
it is very easy to go with this code i think rather than going with fm.
DATA: I_VBELN LIKE LIKP-VBELN,
I_VBKOK LIKE VBKOK,
I_PROTT LIKE PROTT OCCURS 0 WITH HEADER LINE.
L_VBKOK-VBELN_VL = L_VBELN. <- Delivery number
L_VBKOK-WABUC = 'X'. <- Automatic PGI * Perform Pick and PGICALL FUNCTION 'WS_DELIVERY_UPDATE'
EXPORTING
VBKOK_WA = I_VBKOK
SYNCHRON = 'X'
NO_MESSAGES_UPDATE = ' '
UPDATE_PICKING = 'X'
COMMIT = ' '
DELIVERY = I_VBELN
NICHT_SPERREN = 'X'
IF_ERROR_MESSAGES_SEND_0 = 'X' TABLES
PROT = I_PROTT
EXCEPTIONS
ERROR_MESSAGE = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
Or I_PROTT has type E errors in it
ROLLBACK WORK.
ELSE.
COMMIT WORK AND WAIT.
ENDIF.
othere wise
For PGI you can use SD_DELIVERY_UPDATE_PICKING_1
Regards,
Naveen -
\What command keys do i use to fill data. I need this for return address labels
What command keys do i use to fill data.I need this for return address labels
Here's an overly chatty example that will show you what's happening:
$strContacts = 'Tony Stark', 'Anthony Edward Stark'
Write-Host 'User names:'
$strContacts
Write-Host
foreach ($strContact in $strContacts ) {
Write-Host "Start of loop. Processing $strContact now."
$arrContact = $strContact.Split(' ')
Write-Host
Write-Host "$strContact has been split apart into individual array elements based on a space character. The elements are below:"
$arrContact
Write-Host
Write-Host 'Start building filterName variable. Index of -1 gets the last element in the array.'
$filterName = "$($arrContact[-1]), "
$filterName
Write-Host
Write-Host "Loop through the remaining names in the contact. Need to process $($arrContact.Count-1) names."
for ($i = 0 ; $i -lt $arrContact.Count - 1 ; $i++ ) {
$filterName += "$($arrContact[$i]) "
Write-Host "filterName variable is now $filterName"
Write-Host
Write-Host "Now we need to trim off the trailing space character."
$filterName = $filterName.Trim()
Write-Host "The final value of filterName is $filterName"
Write-Host
Write-Host 'Attempting to get the user object via Get-ADUser now:'
Write-Host
Get-ADUser -Filter "Name -eq '$filterName'"
Write-Host 'End of loop.'
Write-Host
Don't retire TechNet! -
(Don't give up yet - 12,575+ strong and growing) -
Event Used For Return Processing Through Transaction Code-FP09
Hi Experts,
I am facing the following problem in FP09:- After creating a return lot, when i provide return reason code for returning payments, event 1073 is not getting triggered.
So, can you please provide the event that will be used for return processing after supplying the reason code for return.
Else, could you please tell me the event which will be triggered by transaction FP09... so that i will catch return reason code in its parameter.
Regards,
SumitHi Experts,
Thanks for your valuable replies .
But my exact requirement is like:- i need to first check the flag for "Inform Accounting Clerk" in SPRO configuration :customizing (financial accounting)-> contract account receivables and payable -> business transactions -> returns -> configure reason codes.
Field for this flag check is V_TFK045E-BSNTE for the Reason Code-02 , now there is dependency mentioned in SAP like "You can only use this option if event 1073 has a function module defined".
After attaching my Z-function module in FQEVENTS , when i run transaction FP09, it doesn't stop at the set breakpoint of my function module, so what i suppose is that may be event 1073 is not the suited event or transaction FP09 is not the required transaction.
please help me in this regard.
Regards,
Sumit -
Hi Experts,
I have coded the following successfully.
1. Create a delivery from a production order
2. Create TO from delivery created
3. Pick/Pack and Confirm TO
Now, I need to create a PGI based from the delivery i created. I used FM BAPI_GOODSMVT_CREATE, however it only creates another delivery. Code is below:
LOOP AT i_itemhu INTO wa_itemhu.
wa_goodsmvt_item-plant = wa_itemhu-plant.
wa_goodsmvt_item-stge_loc = wa_itemhu-stge_loc.
wa_goodsmvt_item-batch = wa_itemhu-batch.
wa_goodsmvt_item-move_type = '261'.
wa_goodsmvt_item-entry_qnt = wa_itemhu-entry_qnt.
wa_goodsmvt_item-entry_uom = wa_itemhu-entry_uom.
wa_goodsmvt_item-orderid = wa_itemhu-orderid.
wa_goodsmvt_item-deliv_numb = wa_itemhu-deliv_numb.
wa_goodsmvt_item-deliv_item = wa_itemhu-deliv_item.
APPEND wa_goodsmvt_item TO i_goodsmvt_item.
CLEAR wa_goodsmvt_item.
ENDLOOP.
CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
EXPORTING
goodsmvt_header = wa_header
goodsmvt_code = '03'
IMPORTING
materialdocument = ws_doc_gihu
TABLES
goodsmvt_item = i_goodsmvt_item.
Is it really possible to do PGI using this FM? If yes, please help in coding.. Many many thanks!!!Hi,
I am using WS_DELIVERY_UPDATE to perform PGI of delivery. I am testing first the FM by in SE37 and PGI is correctly done for a delivery, however, when I had coded it (same way as the testing) I am getting error Delivery XXXXXXXXXX created. On which the delivery XXXXXXXXXX is the delivery I want to perform PGI. I am also trying do some changes in my code like passing the items to vbpok_tab; enabling synchon FM parameter; enabling nicht_sperren; etc., but still same error is being produced. My code is as below:
wa_vbkok-vbeln_vl = ws_delivery_doc.
wa_vbkok-vbtyp_vl = 'J'.
wa_vbkok-wabuc = 'X'.
CALL FUNCTION 'WS_DELIVERY_UPDATE'
EXPORTING
vbkok_wa = wa_vbkok
commit = 'X'
delivery = ws_delivery_doc
IMPORTING
ef_error_any_0 = ws_xfeld
TABLES
prot = wa_prot.
Please help. -
Amount on Goods receipt for return orders is wrong with movement type 653
Hi All, I am sorry if it is a simple question because i am an abap'er.
My requirement is to create return sales order (with ref.to Billing document) and deliver and PGI for the return orders. This should go to sales order stock. Accounting document should be generated for material document and the amount should be picked up from condition type (if man.cond. type exist) else from material master.
1) Created a sales order (Bought in item cat) - Create PO (Non stock) - Receive goods (MIGO) - Create Delivery (VL01N) - PGI (Movement type 601 and special stock indic. 'E') - Create billing document (F2 type from VF01)
So far it is good. The account document is created (PGI - cost of goods) with correct amount as desired
The next scenario is if the material is returned? This is where we are having issues
Created sales order with ref.to billing doc. (S.O: RE. Item.Cat. Return Bought in (YRBI)... this is pretty much same as bought in except few things which are YRBI - Delivered - PGI (Goods returns. unrestricted) Movement type 653 - Problem comes here.
a) If i put special stock indic 'E' in 'Return bought in item.cat - There is no accounting document generated for 653 movement type.
b) if i maintain space instead of 'E' in return bought in item.cat - there is an accounting document but the manual cost is not copied to accounting document and it is picking up from material master which we dont want and The stock is not showing up in sales order.
I did my research (forum, OSS, google, and in help.sap.com) before posting here but no help.
I have checked account assignment categories for 'A' - (some post explained this) I tried changing values but no help.
I even tried changing the schedule line category to DN but no help.
I dont know what i forgot to change or check but i have tried everything what i know and from help from different sources ... still couldnt get it.
Original requirement is to make the return stock as sales order stock and this can also be returned to vendor. If there is a manual cost in return sales order, the PGI accounting document should be created with this condition value else from material master.
My pricing settings are good.
It would be really helpful if any one guide me to configure the process or atleast if anyone tells me what am i missing... .Have a look at any of the following notes:-
1) Note 171989 - Sales-order-related productn: Custmr exit COPCP002
2) Note 520000 - FAQ: Valuated special stocks
3) Note 557582 - User exit and valuated sales order stock
4) Note 580228 - Incorrect prices for materials procured externally
5) Note 983193 - Docu:Externally procurd material in valtd sales order stock
thanks
G. Lakshmipathi -
BAPIs to create sales orders for Returns and Debit Memo Request
Hi,
I have to create a sales order for document type Returns as well as a debit memo request.The BAPI 'BAPI_SALESORDER_CREATEFROMDAT2' is giving the following error message for Debit Memo Request document creation as well as for Returns.
761 Unpermitted combination of business object BUS2032 and sales doc. category L
I found BAPIs:
BAPI_CUSTOMERRETURN_CREATE for creating sales document of type ZDRE and SD document category H.
BAPI_DEBITREQUEST_PROXY_CREATE for creating sales document of type ZDDR and SD document category L.
please let me know if anybody have used them. If so what values need to be passed to I_UPLOAD_ID,I_DESTIN,I_SFA_REL parameters of BAPI_DEBITREQUEST_PROXY_CREATE. Are there any alternative solutions using the Salesorder bapi.
I have to create documents based on the flat file data no reference sales document numbers are available.
Appreciate your help..
Good Day
Regards
BhargaviLook at the code done by me
Program Name: *
SAP Name : ZAXXXXXX Version : *
Programmer : Chris Dong of ITDC *
Description : *
Includes : *
Function Modules: XX_XXXXXX *
Transactions : *
Programs : *
REPORT XXXXXXXX LINE-SIZE 80
LINE-COUNT 65
MESSAGE-ID ZA
NO STANDARD PAGE HEADING.
CLEAR l_order_partners.
l_order_partners-partn_role = 'AG'.
l_order_partners-partn_numb = '0001202491'.
APPEND l_order_partners TO li_order_partners.
CLEAR l_order_partners.
l_order_partners-partn_role = 'WE'.
l_order_partners-partn_numb = '0001202491'.
APPEND l_order_partners TO li_order_partners.
Sales document type
l_order_header_in-doc_type = 'ZDR'.
Sales organization
l_order_header_in-sales_org = '1000'.
Distribution channel
l_order_header_in-distr_chan = '01'.
Division
l_order_header_in-division = '04'.
REF DOCUMENT
l_order_header_in-REF_DOC = '9100000144'.
order reason
l_order_header_in-ord_reason = '925'.
item number
l_order_items_in-itm_number = '000001'.
material no
l_order_items_in-material = '000000000007000012'.
Qty
l_order_items_in-target_qty = '0000000000100.000'.
APPEND l_order_items_in TO li_order_items_in.
*BUS2094 Credit memo request " OSS NOTE 93091
*BUS2096 Debit memo request " OSS NOTE 93091
CALL FUNCTION 'BAPI_SALESDOCU_CREATEFROMDATA'
EXPORTING
ORDER_HEADER_IN = l_order_header_in
BUSINESS_OBJECT = 'BUS2096'
WITHOUT_COMMIT = ' '
CONVERT_PARVW_AUART = ' '
IMPORTING
SALESDOCUMENT = l_vbeln
RETURN = li_return
TABLES
ORDER_ITEMS_IN = li_order_items_in
ORDER_PARTNERS = li_order_partners
Message was edited by:
Chris Dong
null -
Hi,
I've created a PO with two items. One normal item and one return item and posted the GR and IR. The invoices was paid also.
Due to some reasons I want to reverse the originally posted invoice. Since it's paid and cleared, system would not allowing me to cancel the invoice using MR8M.
The next option I've is to post a credit memo. Here system is not allowing me to post the credit memo in any manner. I've tried in below methods
a) Credit Memo for both normal and return item. - Here system is adding the value of returns item twice and crediting the vendor instead of debiting.
b) Individual Credit memo for normal item and Invoice for return item. - Here normal item is ok, but while posting Invoice for returns item, system throwing error saying amount is negative.
What ever the way system is not allowing me to post the document.
Can anybody help me in this matter.
Thanks in advance,
MallikUsually there is a functional different between the normal PO and return PO. When you combine together
the following questions are popped up im my head.
Q1. How to distinguish your doc type while creating PO?
Q2. When you perform GR, did you do it for both normal and return items?
Q3. When you perform GI (for returns), How did you perform?
Q4. How the invoice identify whether it is meant for normal PO or return PO (Ofcourse - return PO, we ususally do credit memo)
If you get the answer for above questions, you will get answer for your questions.
Regards, -
Return PO box ticked for return PO document type
HI All,
There is a help need for Badi. While creating a return PO in T Code ME21N, i want to get return PO field ( EKPO-RETPO) box ticked for Return PO document type. I found one BADI for ME_COMMITMENT_RETURN. I need help to use this badi.
Regards,
Madhu.Hi
Why don't use the BADI ME_PROCESS_PO_CUST, method PROCESS_ITEM? You have a demo. The idea is:
data: ls_mepoitem type mepoitem,
ls_header type ref to if_purchase_order_mm,
ls_data_header type mepoheader.
ls_mepoitem = im_item->get_data( ).
ls_header = im_item->get_header( ).
ls_data_header = ls_header->get_data( ).
IF condition IS TRUE. "with LS_MEPOITEM, LS_DATA_HEADER
ls_mepoitem-retpo = 'X'.
ENDIF.
im_item->set_data( ls_mepoitem ).
I hope this helps you
Regards
Eduardo -
Output type for Proforma Invoice for return delivery from delivery type RLN
Client require Output type Proforma Invoice for return delivery to vendor. As such return item category is not relevant for pricing so from delivery to proforma invoice can not have with p-ricing. I got quantity correct but pricing is coming Zero.
Client have ZPAC as packing list output type from delivery which shows quantity and pricing. So decided to use the same logic to pull pricing for proforma invoice from delivery.
Here delivery has standard output ZPAC as packing list with access sequence Z002 as Delivery Type.
I want to pop up output type for all return delivery so using access sequence with delivery type/vendor.
Vendor filed does not exist in delivery output type so brought that firld LIFNR.
It is assigned to procedure and maintained ZPRO output type for Proforma invoice. Asigned VV21 on front end.
Problem Still automatic output type ZPRO is not poping up. What type of access sequence will help me to pop up or what in configuration am I miising?
Appreciate help for solution at earliest.Hi Padamsree,
I know Pricing & output very well. I need profomra invoice to be printed with quantity & value for return goods to the vendor. Pricing is associated with Item category RLLN for delivery type RLL which is return type delivery.
I need to have pricing in my Proforma invoice which is copied from delivery to billing document VTFL. Just check well how it is working in the system & if you know please answer so that it should be workable on the system. As theoretical answer may not be helpful. Appreciate for your time.
Thanks -
Goods Receipt for Inbound HU - WS_DELIVERY_UPDATE
Hi All,
I have a requirement to automate transaction VL60p to do GR for
an inbound delivery with HU.
Since this is a SAP enjoy transaction I can't use BDC and there doesn't seem to
be a BAPI for this.
I plan to use WS_DELIVERY_UPDATE, filling tables VERKO and VERPO.
Is my approach correct?
If not can you point me in the right direction?
Thanks,
MiguelAnyone?
I've also added IT_OBJECTS as one of the tables I'm passing.
Its of type PGR_OBJECTS which is described as Objects for Partial Goods Receipt.
However Posting is still not happening.
Thanks,
Miguel
Maybe you are looking for
-
Why does Powerbook freeze when attaching files?
I am working an a friends Powerbook G4 1.5 GHz 15", running Leopard 10.5.8. Whenever I attempt to attach a file, located in applications, downloads, desktop, and when composing an email (any mail application, Yahoo!, etc), the Powerbook will begin wi
-
no matter what i do in system prefs, date and time in menubar always displays GMT time, all files (when info is displayed) display GMT time I am in LA and this problem happened before when set to "Los Angeles PST" but disappeared when set to "Vancouv
-
Image Metadata number to appear on print?
I want to set up so an image shows automatically the image number when I save it/print it. For example I want img_1022.jpeg to appear on the image for ease of identification. I am a wedding photographer and at the moment have to go to each image and
-
Table header not visible on all pages
I have created a table, which have the following subforms. MaterialBody ( Type -Flow Content & Flow direction - Table ) - Header ( Type - Flow Content & Flow direction - Table row ) - Data ( Type - Flow Content & Flow direction - Tabl
-
[solved] xfce keyboard shortcuts won't work, tried arch wiki solution
Keyboard shortcuts defined in the xfce's keyboard settings don't work, as described in the wiki: http://wiki.archlinux.org/index.php/Xfc - 7t_working When I kill xfce4-settings-helper the shortcuts work again. After restarting X the problem returns.