FM/BAPI to create Transfer Order(TO) with reference to TR or Material Doc.
Hi,
I am in need of Function module or BAPI to Create Transfer Order(TO) with reference to Transfer Requirement(TR) or Material Document.
Hi,
Please try any of the below,
1.Look at function group L03B (Transfer order processing)
2.Use L_TO_CREATE_TR
3.BAPI_GOODSMVT_CREATE set:
GOODSMVT_ITEM-STGE_TYPE_PC = destination storage type or GOODSMVT_ITEM-STGE_TYPE_ST = destination storage type
4.Look at fm L_TB_VERAENDERN. This isn't RFC, but you might copy fm into ZL_TB_VERAENDERN and set RFC on.
Hope this helps.
Thanks,
Harini
Similar Messages
-
BAPI to create a billing document with reference to delivery or sales order
Hi,
Does anyone know any BAPI or function module that allows the creation of a billing document with reference to a sales order or to a delivery.
Maybe the BAPI_BILLINGDOC_CREATEFROMDATA may be used to create a billing document with reference to a sales document, but i'm looking for a solution where I only need to indicate the number of the reference sales order or the reference delivery and maybe some few data more without the need of transfer all the items and conditions information.
Thanks.
Kind regards,
Paulo SousaHello Paulo,
To create a billing document based on a delivery use BAPI_BILLINGDOC_CREATEMULTIPLE. In table BILLINGDATAIN insert one line with the following data:
REF_DOC = Delivery number
REF_DOC_CA = 'J'
If it runs fine, table SUCCESS will bring back useful data, like BILL_DOC (Billing document number).
Regards,
Joã -
Creating sales order document with reference to billing document
I have to create sales order with reference to existing billing document. I have tried to following bapis.
1. BAPI_SALESORDER_CREATEed
I have successfully created document with following details.
-->ORDER_HEADER_IN:
DOC_TYPE = ZRK
SALES_ORG = 3000
DISTR_CHAN = 00
DIVISION = 00
ORD_REASON = 100
SD_DOC_CAT = L
CURRENCY = EUR
REF_DOC = 100000028
REF_DOC_CA = M
-->ORDER_ITEMS_IN:
ITM_NUMBER = 000010
MATERIAL = 701791
TARGET_QTY = 0000000001000
CURRENCY = EUR
REF_DOC = 100000028
REF_DOC_CA = M
-->ORDER_PARTNERS:
PARTN_ROLE = SP
PARTN_NUMB = W12001
COUNTRY = NL
by providing this input i am able to create the document but it is not picking up the net value. so i have passed some extra paramters in ORDER_ITEMS_IN
COND_TYPE = PNET
COND_VALUE = 14,56
COND_D_UNT = PC.
folowing error is occured: Condition PNET is missing in pricing procedure A V Z0000.
is it something related to configuration problem?
2.BAPI_SALESORDER_CREATEFROMDAT1 or BAPI_SALESORDER_CREATEFROMDAT2
I have used same test data that is used for BAPI_SALESORDER_CREATEFROMDATA (where in i coudl succefully create doc). but here i encounterd following error.
Unpermitted combination of business object BUS2032 and sales doc. category L.
When i created manually using transaction : VA01
I could do the same by passing following inputs:
DOC_TYPE = ZRK
SALES_ORG = 3000
DISTR_CHAN = 00
DIVISION = 00
Reference document number.
Please suggest me right way of approach.Hi,
In SAP, when the sub-sequent document is existing , we can not cancel the preceeding document. Therefore if you want to cancel the billing document you need to calcel the documents which are created with reference to that.
Check and confirm.
Regards,
Ravi Duggirala -
Create sales order (return) with reference - PO number not copied
Hello all,
I have a question regarding creating a sales order (return, VA01) with the option "create with reference" where a sales order number can be added as reference.
The system will copy values from the sales order into the return document like the item, the sold-to-party etc.
The PO Number (customer PO number) is not being copied in our system, so I was wondering if there is a way to tell the system to copy the PO number from the sales order?
Thanks,
AnneHi,
In the transaction code VTAA, select the target and source document types (return order <- sales order) and click on the details button. Check the data transfer routine (the first one for VBAK) assigned here. You may need to clone this routine (in transaction VOFM -> Data transfers -> orders) and create a new routine to add field VBAK-BSTNK into it.
Check with an ABAP'er for further details.
Regards, -
Is there any BAPI available for sales order creation with reference?
Hi Experts,
My requirement is to create sales order with reference for order type.
Now my billing document number already contains the two items
one is correct and another is zero quantity.
I want to create order with reference of billing document but not with zero quantity item.
Which BAPI I should use and what to pass to ignore zero quantity item?
Regards,
RHHi Ronny,
Try using BAPI_SALESORDER_CREATEFROMDAT2
Regards,
Shraddha -
How to create sales order Automatically with reference to contract?
how to create sales order automatically through batch or online? can anyone please suggest what needs to be change in SAPMV45A program?
Hi,
Wt am able to understand from the above question is, you want to create automatic sales order against contract on a day to day basis by doing batch program, hope am wright.
See you can do it in two ways.
1. By using BDC, in SHDB T code record how exactly you will do transaction and then give it to your abaper rest he will do. he will write a program and he will schedule that program every day night.
2. By using BAPI. Just check in there are many threads are there which gives sales order bapi. Tell your abaper to map that bapi and tell them to schedule back ground job.
Hope this will help out in solving your problem.
Regards,
Nagesh -
BAPI to create Transfer order(WMS) from Material document
Dears,
We have activited WMS and we have not found any BAPI to generate TO in WMS from Material document to post GR to a specific bin. Is there any BAPI available for particular operation?
Can anyone tell me about name of BAPI?
Regards,
FRTry with Function Module L_TO_CREATE_TR
also try
Use this function module to create TO (transaction LT01) L_TO_CREATE_SINGLE
CALL FUNCTION 'L_TO_CREATE_SINGLE'
EXPORTING
i_lgnum = ti_lqua-lgnum
i_bwlvs = l_bwlvs
i_matnr = zwwmugeori-matnr
i_werks = ti_lqua-werks
i_lgort = ti_lqua-lgort
i_bestq = l_bestq
i_letyp = l_letyp
i_anfme = l_anfme
i_altme = l_altme
i_vlpla = l_vlpla
i_vlenr = l_vlenr
i_nlpla = l_nlpla
i_nlenr = l_nlenr
i_commit_work = space
IMPORTING
e_tanum = l_tanum.
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Feb 13, 2008 11:33 AM -
How to create Transfer order from material document uFF08Move type is 101uFF09
Hi all,
is there any function module, BAPI to create transfer order from a material document number?
I want to use FM L_TO_CREATE_SINGLE,but the result is "Movement type 101 for manual transfer orders does not exist".
Is the parameters error?
Thank you in advance
RegardsThe error message you get is number 196 from message class L3, do a where-used on it from transaction SE91 and then put a break-point on each line result. Afterwards, re-execute your function call and see which break-point is hit and investigate from there.
With that said, you really should be using Bapi BAPI_GOODSMVT_CREATE for all goods movement operations. It shares code with MIGO and executes the same Badi's and user-exits, so data integrity is not broken. Don't forget Bapi BAPI_TRANSACTION_COMMIT to commit changes in the database after a successful call.
cheers -
BAPI SALES ORDER & Copy with reference
Hello,
I'm creating sales order copied with reference to an invoice. My problem is that the data item is empty. When I create the sales order manually and use the option 'Create with reference' and choose an invoice, the sales order is created with all data item. I don't know how I can get to copy the data item from the invoice in the new sales order. The code that I'm using is the following:
DATA: order_header_in LIKE bapisdhd1,
order_partners LIKE bapiparnr OCCURS 0 WITH HEADER LINE,
order_text LIKE bapisdtext OCCURS 0 WITH HEADER LINE,
order_header_inx LIKE bapisdhd1x,
order_item_in LIKE bapisditm OCCURS 0 WITH HEADER LINE,
order_schedules_in LIKE bapischdl OCCURS 0 WITH HEADER LINE,
order_conditions_in LIKE bapicond OCCURS 0 WITH HEADER LINE,
extensionin LIKE bapiparex OCCURS 0 WITH HEADER LINE,
partneraddresses LIKE bapiaddr1 OCCURS 0 WITH HEADER LINE,
order_cfgs_ref like BAPICUCFG occurs 0 with header line.
DATA: salesdocument LIKE bapivbeln-vbeln.
DATA: return LIKE bapiret2 OCCURS 0 WITH HEADER LINE.
order_header_in-doc_type = 'ZA09'.
order_header_in-sales_org = '1700'.
order_header_in-distr_chan = '01'.
order_header_in-division = '01'.
order_header_in-BILL_DATE = '20060701'.
order_header_in-ref_doc = '0900000019'.
order_header_in-refdoc_cat = 'M'.
*order_header_in-REF_DOC_L_LONG = '0900000019'.
order_header_in-purch_no_c ='prueba'.
*order_header_in-ord_reason = '003'.
*order_header_in-pmnttrms = '0002'.
*order_header_in-sales_off = '2800'.
order_header_in-ref_doc_l = 'FACTURA ES'.
*order_header_in-fix_val_dy = '20060701'.
*order_header_in-currency = 'USD'.
*order_header_in-exchg_rate = '1.2'.
order_partners-partn_role = 'AG'.
order_partners-partn_numb = '0000000001'.
order_partners-langu = 'EN'.
order_partners-name = 'El corte aleman'.
order_partners-country = 'ES'.
APPEND order_partners.
order_partners-partn_role = 'RE'.
order_partners-partn_numb = 'ARR000'.
order_partners-addr_link = '0000030044'.
APPEND order_partners.
CALL FUNCTION 'ADDR_GET_COMPLETE_ALL_TYPES'
EXPORTING
addrnumber = order_partners-addr_link
PERSNUMBER =
address_object_type = '1'
IV_CURRENT_COMM_DATA = 'X'
IMPORTING
ADDR1_COMPLETE =
ADDR2_COMPLETE =
ADDR3_COMPLETE =
ADDR1_COMPLETE_BAPI = partneraddresses
ADDR2_COMPLETE_BAPI =
ADDR3_COMPLETE_BAPI =
EXCEPTIONS
PARAMETER_ERROR = 1
ADDRESS_NOT_EXIST = 2
PERSON_NOT_EXIST = 3
INTERNAL_ERROR = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
data: vl_texto(40) value 'NUEVOOOOO'.
partneraddresses-name = vl_texto. clear vl_texto.
partneraddresses-name_2 = vl_texto.
partneraddresses-name_3 = vl_texto.
partneraddresses-name_4 = vl_texto.
partneraddresses-langu = 'E'.
APPEND partneraddresses.
DATA: vl_cantidad LIKE bapisditm-target_qty.
vl_cantidad = 1.
order_item_in-itm_number = 10.
order_item_in-material = 'HONORARIOS'.
order_item_in-ref_doc = '0900000019'.
order_item_in-ref_doc_it = 10.
order_item_in-ref_doc_ca = 'M'.
APPEND order_item_in.
order_schedules_in-itm_number = 10.
order_schedules_in-req_qty = vl_cantidad.
APPEND order_schedules_in.
order_text-text_id = 'Z001'.
order_text-ITM_NUMBER = ''.
order_text-langu = 'EN'.
order_text-text_line = 'Hola, CARACOLAcola'.
APPEND order_text.
order_text-text_id = 'Z001'.
order_text-langu = 'EN'.
order_text-text_line = 'Adios caracol'.
APPEND order_text.
order_text-itm_number = '000010'.
order_text-text_id = '0001'.
order_text-langu = 'EN'.
order_text-text_line = 'Hola, POSICIÓN'.
APPEND order_text.
extensionin-structure = 'BAPE_VBAK'.
extensionin-valuepart1 = ' BCL 7'.
APPEND extensionin.
order_cfgs_ref-posex = '10'.
order_cfgs_ref-config_id = '10'.
order_cfgs_ref-root_id = '00000001'.
append order_cfgs_ref.
CALL FUNCTION 'ZBAPI_SALESORDER_CREATEFROMDT2'
EXPORTING
SALESDOCUMENTIN = salesdocument
order_header_in = order_header_in
ORDER_HEADER_INX = order_header_inx
SENDER =
BINARY_RELATIONSHIPTYPE =
INT_NUMBER_ASSIGNMENT =
BEHAVE_WHEN_ERROR =
LOGIC_SWITCH =
TESTRUN =
CONVERT = ' '
IMPORTING
salesdocument = salesdocument
TABLES
return = return
order_items_in = order_item_in
ORDER_ITEMS_INX =
order_partners = order_partners
order_schedules_in = order_schedules_in
ORDER_SCHEDULES_INX =
order_conditions_in = order_conditions_in
ORDER_CONDITIONS_INX =
ORDER_CFGS_REF = order_cfgs_ref
ORDER_CFGS_INST =
ORDER_CFGS_PART_OF =
ORDER_CFGS_VALUE =
ORDER_CFGS_BLOB =
ORDER_CFGS_VK =
ORDER_CFGS_REFINST =
ORDER_CCARD =
order_text = order_text
ORDER_KEYS =
extensionin = extensionin
partneraddresses = partneraddresses
PERFORM report TABLES return.
*DATA: salesdocument LIKE bapivbeln-vbeln.
*DATA: return LIKE bapiret2 OCCURS 0 WITH HEADER LINE.
*refresh return.
*CALL FUNCTION 'BAPI_SALESDOCUMENT_COPY'
EXPORTING
salesdocument = '0400000191'
documenttype = 'ZA04'
TESTRUN = ' '
IMPORTING
SALESDOCUMENT_EX = salesdocument
TABLES
RETURN = return
*PERFORM report TABLES return.
*write: / salesdocument.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
EXPORTING
WAIT =
IMPORTING
RETURN =
*& Form report
text
-->P_MENSAJE text
FORM report TABLES p_mensaje STRUCTURE bapiret2.
DATA: vl_mensaje TYPE string.
LOOP AT return.
CLEAR vl_mensaje.
MESSAGE ID return-id
TYPE return-type
NUMBER return-number
INTO vl_mensaje
WITH return-message_v1
return-message_v2
return-message_v3
return-message_v4.
WRITE: / vl_mensaje.
ENDLOOP.
ENDFORM. " reportHi Manuel,
There are some function modules which is there to copy the order details. I am not sure about the function module name. But you can search in SE37. But bapi for creating the sales order does not have the functionality of copying the data from one document to another document.
You can try using this function module.
BAPI_SALESDOCUMENT_COPY
Data will be copied based on the copy control routines that is set between the two document types.
Thanks,
Arun -
How to create Transfer order from material document
Hi gurus,
is there any function module, BAPI to create transfer order from a material document number.
waiting for positive reply.
thanks
vinodHi,
The FM L_TO_CREATE_SINGLE or L_TO_CREATE_MULTIPLE could solve your problem.
Hope it helps.
Chang -
How to pick additional delivery quantity after creating Transfer Order .
Hi
Sales order has been created for 30 pc of material , with reference to this sales order , delivery has been created .Afterwards I created transfer order in lt03 and got it confirmed in LT12. However , PGI has not been carried out .
Afterwards , I went to VL02N and manually increased the materialsu2019 quantity to 60 pc in delivery .
In delivery packing status is partially picked .
I request you to help me how can I pick another 30pc as already transfer order has been created and confirmed for this delivery .
Either system is not allowing me to cancel transfer order in order to create fresh transfer order to with reference to this delivery . Otherwise , I could have done it .
Could you please suggest me , how to go about it .Hi
There is an excellent way to handle your issue
While creating TO in t code LT03 in the initial screen control tab if you give pick quantity as 2 after the TO creation the system will simultaneouslely do PGI also in a single shot
This means the delivery quantity cant be changed in the VL02N
The whole VL02N will be display mode fully greyed out
That means after TO you cant change the delivery
If extra qty has to be added then it has to be a separate order only
I have practised this only and for the past two hrs i was breaking my head how come you are changing delivery after TO creation and for me it was in display mode(fully greyed out) even in VL02N and i found out i am using adopt pick qty as 2 in the initial screen of LT03 which does PGI in a single shot
This should be a good solution for you
Even the solution suggested by Mr.Raj Malhotra you will face the same problem
Regards
Raja -
BAPI - Goods receipt and then create transfer order for a production order
Hello Everyone
We need to do goods receipt and then create transfer order for a production order (Material for WM scenario)
We are using BAPI 'BAPI_GOODSMVT_CREATE'
i_items-orderid = wa_afpo-aufnr .
i_items-order_itno = wa_afpo-posnr.
i_items-mvt_ind = 'F'.
i_items-stge_loc = wa_afpo-lgort.
i_items-stge_type = '901'. "wf_styp.
i_items-stge_bin = wf_sbin.
i_items-entry_qnt = wf_qty.
i_items-entry_uom = wa_afpo-meins.
i_items-entry_uom_iso = wa_afpo-meins.
i_items-batch = wa_zmobtag-charg.
i_items-move_type = '101'.
i_items-move_reas = wl_3131.
We are passing i_items (like line of goodsmvt_item) along with other parameters to BAPI and its creating material document and Transfer order automatically. Problem is the TO created is showing destination storage bin as default storage bin( from material master).
The field goodsmvt_item-stge_bin is just changing the Source bin details. There is no field for bin in the BAPI so that we can change the Destination storage bin as per our requirement.
My requirement : Creating material doc and then TO. Material should move to specified storage bin.
Please let me know any alternate way( No BDC) so that my requirement is achieved.
Regards
SwetabhHi ,
can u check these fields ,
STGE_TYPE_PC UBTYP CHAR 3 0 Storage type for transfer posting
STGE_BIN_PC UBPLA CHAR 10 0 Storage bin for transfer posting
Regards
Prabhu -
Need RFC/BAPI to create Delivery Order with respect to Sales Order
Hi Gurus ,I'm new to AB AP Language to be working in company
so can anyone tel me FM/BAPI to create Delivery order with respect to sales order(va01,vl01n)
Any sugg.. will appreciate u.........
Thanks in Advance...........Hi,
Try this BAPI
BAPI_SALESORDER_CONFIRMDELVRY
Regards
Bala Krishna -
Anyone used BAPI/FM for LT03 create transfer order
Hi all,
Has anyone used BAPI/FM for <b>LT03</b> create transfer order based on delivery.
the BAPI/FM should accept <b>multiple line items for individual storage units</b>.
thanks,
Subbathanks Amit....
But it would be helpful to know the usage of this FM....and if anyone has used in their program....
thanks,
Subba -
Can u tell me any bapi to create the purchase req with sales order as refer
can u tell me any bapi to create the purchase req with sales order as reference?
Hi Mukesh,
You can use 'BAPI_REQUISITION_CREATE' for the purchase requisition creation if through transaction, you use transaction ME51N for creating the purchase requisition.
Cheers,
Sujay
Maybe you are looking for
-
Making separate iTunes accounts on the same computer
My brother just got an iPod, and he keeps using my downloads so I can't put them on a second device. Is there a way to make it so you have to log in to start doing anything with iTunes?
-
MAC On Windows - Virtual Machine
Before installation of the MAC on Windows, i would like to know if i can install MAC on a PC running a Windows XP SP 2 ! Regards
-
How to store Payment Advices Directly in Folder
Hi, Can the payment run program store the payment advices directly into folder after the actual payment run? If yes, what are the steps? Thanks, teo
-
How much space does OS 6 require ?
Hello again, Friends do let me know how much space is require for OS 6 in 9300. and does is it true that OS 6 make 9300 very slow in processing anything ?? Thank you in advance. Regards, Anwar A Solved! Go to Solution.
-
4S: How do I keep camera in regular mode with "Invert Colors" to on?
On an iPhone 4S w OS7.1, how do I keep the camera in regular mode (not negative image) and keep the "Invert Colors" swith to active or pink or (1).