Sales order with reference to quotation

How to use BAPI_SALESORDER_CREATEFROMDAT2 to create a sales order with reference to quotation? what parameters I need to fill in?

Hi,
I've also had this problem.
In the past when faces with this requirement I have used
BAPI_READ_SALES_DOCUMENT (Note:  I am away from a system today so that may not be the EXACT name of the funciton module but it's close ) to read in the document data from the quote, then transfer that data to the input structures of BAPI_SALESORDER_CREATEFROMDAT2.  Seems to work reasonably well although it doesn't offer much in the way of automatic error handling.
Hope this helps,
Regards,
Brent

Similar Messages

  • G/L Account is missing in item data in sales order with reference to quotation

    Dear SAP Guru,
    I have a problem in accordance with G/L Account missing sales order. Initially, please find the below lines.
    1. If I do the sales order without reference to quotation there is no error in G/L Account missing.
    2. If I do the sales order with reference to quotation there is an error that G/L account is missing in item data.
    I have checked the VKOA, the settings are fine.
    Kindly anyone of you resolve this issue.
    Warm Regards
    Vidya Sagar

    G/L account is missing in item data.
    Many times, it has been discussed on this issue in SCN and please search with the same text so that you will find many threads asking various areas to check.  Take the inputs from there and post here still if you have issue.
    G. Lakshmipathi

  • Creating Sales Order with reference to Quotation from different Sales Area

    Hi,
    I would like to inform you that our customer (GE ENERGY OC) from Europe have a requirement where they want to create sales orders with reference to quotation that is from different sales area. Standard SAP functionality doesn't allow this feature, hence requesting your help to give me an update in this regard.
    Please treat this as urgent as they have to do business cutover where they are in the process of completing open sales orders.
    Thanks
    Ashfaq
    Mobile: +91-98857-07558
    E-Mail: [email protected]

    Hi RadhaKrishna,
    In standard system it is not possible to create sales order from a quotation whose sales are is different.
    However I think this is possible by using some user exit in sales order. I have never tried this.
    Regards
    srini

  • Creation of sales order with reference to Quotation using BAPI

    Hi All,
    I am using BAPI "BAPI_SALESORDER_CREATEFROMDAT2" for creating sales order. Can you please tell how can I create a sales order with reference to a Quotation.

    Vinit,
    In your header structure, set like this:
      hdr-REF_DOC = i_order-vbeln.  "assign quotation # to sales order
      hdr-REFDOC_CAT = 'B'.         "assign Quotation to VBTYP_N.
    For each line item, set as follows:
    Assigning ref doc to create line item entries in VBFA.
        itm-REF_DOC    = i_order-vbeln.  "quote number
        itm-REF_DOC_IT = i_vbap-posnr.   "quote line item #
        itm-REF_DOC_CA = 'B'.
      data: ret_text type BAPIRET2.
      CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
        EXPORTING
          ORDER_HEADER_IN           = hdr
          convert                   = 'X'
        IMPORTING
          SALESDOCUMENT             = salesdoc
        TABLES
          return                    = ret_tbl
          ORDER_ITEMS_IN            = itm
          ORDER_PARTNERS            = prtnr
          ORDER_ITEMS_inx           = itmx
          ORDER_CONDITIONS_IN       = conds
          ORDER_CONDITIONS_INX      = condsx
          order_schedules_in        = schd_lin.
    Don't forget those points.

  • COPY CONTROL: SALES ORDER WITH REFERENCE TO QUOTATION

    Hi.
    We are creating a sales orders with reference to a quotation. When copying, we'd like to be able to include another new position type in the sales orders.
    For example:
    QUOTATION:
    POSITION 10: TYPE ZTAB
    SALES ORDERS:
    POSITION 10: TYPE ZTAB
    POSITION 20: TYPE IRSS.
    Where could we place this change?. We suppose when saving the sales orders. Does anybody know how could we make this change?.
    Thank you very much!.
    Raú

    What do you mean by position type?
    Please use the language used by SAP so that it could be easily understood.
    What is ZTAB & IRSS. Are they materials?
    Regarding copying, this is a brief theory
    In copy control, you define control data for the document flow of sales documents.
    You can specify for a particular sales document type, which document type is to be assigned to copied reference documents, and which item categories or schedule line categories are to be copied.
    You must also make specifications for copying requirements and data transfer, as well as quantity and value updates in document flow.
    In precise, you are telling the system what data to copy from QT to sales order. It copies data from Quotation order type to Standard order type basing on settings you indicated in copying control.
    System won't do anything more than copying from preceding documents and it would transfer data based on copying rules in copy control.

  • Sales order with reference to quotations.

    Hello Experts ,
    I want to know how can a sales order be created with reference to more than one quotation??
    Is there a transaction to do this ?? or else its a process?? Please guide. points will be rewarded to the answers.
    Thanks,
    Arathi

    Hi Arathi Rajan,  ALL ARE GIVEN WRONG ANSWERS TO YOU : SORRY TO SAY THAT ....
    YES YOU CAN CREATE ONE SALES ORDER WITHR EFERENCE TO MULTIPLE QUOTATIONS:
    FOLLOW ME:
    1). GO TO VA01 SCREEN ENTER ORDER TYPE : OR
    ENTER SALES AREA
    2). SELECT THE ICON " WITH REFERENCE TO QUOTATION"
    AND THEN COPY THE 1 QUOTATION DETAILS, THEN IT WILL TAKE YOU TO SALES ORDER SCREEN, THERE U WILL FIND ONE LINE ITEM . OK
    3). THEN, IF U WANT TO ENTER MULTIPLE QUOTATIONS:
    SALES DOCUMENT- SELECT CREATE WITH REFERENCE AND SELECT THE MULTIPLE QUOTATIONS LIKE THIS:
    4). NOW U CAN ABLE TO CREATE THE SALES ORDER WITH REFERENCE TO MULTIPLE QUOTATIONS.
    HOPE IT HELPS YOU ,
    Thanks&Regards
    Venkat.Dhanemkula

  • BAPI: Create Sales order with reference to Quotation

    Hi ...
    I am using bapi BAPI_SALESOREDER_CREATEFROMDATA2  and
    i want to create sales order with reference Quotation... All quotation data like Materials prices and conditions must be copied from reference quotaion which is allready created .....
    ..Thanks..
    ..Ashish

    Hello,
    nice to see that this has already been solved.
    But it actually doesnt work in my scenario. Do you have an example coding which will explain your solution.
    Mine looks like this:
    * Update Flag
      ls_header_inx-updateflag = 'I'.
    * Angebotskopf einlesen
      SELECT SINGLE * FROM vbak INTO ls_vbak
        WHERE vbeln = iv_vbeln
          AND vbtyp = lc_vbtyp.
      IF sy-subrc <> 0.
        EXIT.
      ENDIF.
    * Auftragskopf setzen
      ls_header_in-doc_type      =  ls_vbak-auart.
      ls_header_in-sales_org     = ls_vbak-vkorg.
      ls_header_in-distr_chan    = ls_vbak-vtweg.
      ls_header_in-division         = ls_vbak-spart.
      ls_header_in-req_date_h   = ls_vbak-VDATU.
      ls_header_in-ref_doc        = ls_vbak-vbeln.
      ls_header_in-refdoc_cat   = 'B'.
    * Angebots-Partner einlesen (Nur AG und WE)
    * Auftrag anlegen
      CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
        EXPORTING
    *   SALESDOCUMENTIN               =
          order_header_in               =  ls_header_in
    *      order_header_inx              = ls_header_inx
    *   SENDER                        =
    *   BINARY_RELATIONSHIPTYPE       =
    *   INT_NUMBER_ASSIGNMENT         =
    *   BEHAVE_WHEN_ERROR             =
    *   LOGIC_SWITCH                  =
    *   testrun                       = 'X'
    *   CONVERT                       = ' '
       IMPORTING
          salesdocument                 = ev_vbeln
        TABLES
          return                        = et_return
    *      order_items_in                = lt_items_in
    *      order_items_inx               = lt_items_inx
          order_partners                = lt_partners
    *   ORDER_SCHEDULES_IN            =
    *   ORDER_SCHEDULES_INX           =
    *   ORDER_CONDITIONS_IN           =
    *   ORDER_CONDITIONS_INX          =
    *   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_KEYS                    =
    *   EXTENSIONIN                   =
    *   PARTNERADDRESSES              =  .
      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
        EXPORTING
          wait = 'X'.
    Unfortunatly this just makes the reference to the quotation but does not takeover ALL data from header and pos level.
    Thanks and regards
    Markus Armbruster

  • Create Sales Order with Reference from Quotation

    Hi All,
    Is there any bapi or function to create sales order with reference from a quotation?
    I know BDC is possible but any other methods?
    Thanks
    Dyl

    You can use - BAPI_SALESDOCUMENT_COPY.
    Prerequisite is Copy control should exist in customizaiton.
    -Alpesh

  • Changing quantities in sales order with reference to quotation

    Hi,
    Quotation has been created for Product -- A, 10 quantities.
    Sales order created with reference to quotation, system copies 10 quantity in sales order.
    How do you restrict in sales order end user should not change quantities, system should not allow for changes by end user. If end user changes Qty system should give an "Error message", so that sales can not be saved.
    Could you suggest solution ASAP.
    Thanks in Advance.
    Regards,
    vamsi.

    Normally You will have a warning message set for this. under class V1. if you want the error to be hard error then you would have to hard code it in a user exit under mv45afzz "userexit_save_document_prepare" where u can check if the quantities in the quote and sales order are different and create a hard error.
    the other option which I am not sure if it is possible is to propose the eror in message class v4 which you can control thru customisation under SPRO>SD>message settings
    reward points if it helps
    regards
    Biju

  • Inbound Files Create Sales Order With Reference To Quotation

    Dear All,
    I am working one Assignments For Sales Order Creation Through Inbound Files and Its working fine.
    But I have one Issue during creation of Sales Order through inbound files ( Which Contains Quotation Number Which Already Exist in SAP ) and Quotation Number updated in PO Number (BSTKD) filed in Sales Order.
    And My Problem is How we can update Quotation in Document Flow during creation of Sales Order through inbound files..
    Any Help or Suggestion will very helpful for me.
    Thanx in Advance.
    Regards
    Vijay Maurya

    Dear All,
    I am working one Assignments For Sales Order Creation Through Inbound Files and Its working fine.
    But I have one Issue during creation of Sales Order through inbound files ( Which Contains Quotation Number Which Already Exist in SAP ) and Quotation Number updated in PO Number (BSTKD) filed in Sales Order.
    And My Problem is How we can update Quotation in Document Flow during creation of Sales Order through inbound files..
    Any Help or Suggestion will very helpful for me.
    Thanx in Advance.
    Regards
    Vijay Maurya

  • Create sales order with reference to 10 quotation

    Create sales order with reference to 10 quotation I want to put all quotation means take reference in one sales order how I can do it because when tried va01 and taken reference of question it allow to put only one question number how can I do it for multiple question
    Ahmed

    Hi Raj,
    If you come back to initial screen after coping the first quotation ,then system will ask you whetehr to save or cancel the data,if we select save then it will be saved immediately,else it will cancel.So ,it is not possible to copy more than one quaotation in standard SAP.The only option is to deveop a BDC with the help of abaper.
    We can only create this when header data is same in all the quotations.
    Regards,
    Pasapula.
    Edited by: Pasapula on Jul 24, 2009 9:48 AM

  • Sales order with reference to a quotation

    Hi
    When we are creating a sales order with reference to a quotation, the sales order must contain the shipping condition from the quotation, not from the soldto.How we can configure with copy controls.
    Thanks

    Hi Mr. Rao,
    See system take shipping condition from sales document first then customer master. it never copy shipping condition from sales document to document.
    But you can achieve the requirement through configuration in VOV8, Use T-Code VOV8 double click the quotation document and mainatin the Shipping condition same as u want to be in sales order then maintain same shipping condition in sales order configuration screen (by double clicking)
    Hope it will solve your problem
    Rgds
    Shambhu Sarkar

  • Creation of sales order with reference to inquiry no.

    Hi gurus!
    Im having trouble in creation of sales order with reference to inquiry no. The scenario is like this one. In va11(creation of inquiry no.), in the field of <b>SERVICE LEVEL</b>, i indicated a value. after the creation of inquiry no, i want to create a sales order with reference to inquiry no. But the problem is, the <b>SERVICE LEVEL</b> field does not have any value. What is the main problem to this scenario? is it the VARIANT CONFIG or the program itself? please help its urgent
    Regards,
    Mackoy

    Dear Machoy,
    In IMG under
    Sales and Distribution -> Sales -> Sales Documents -> Maintain Copy Control for Sales Documents -> Copying Control: Sales Document to Sales Document
    or Transaction VTAA
    http://help.sap.com/erp2005_ehp_02/helpdata/en/70/a7853478616434e10000009b38f83b/frameset.htm
    If you create a sales document with reference to a preceding document, the system copies nearly all the data from the preceding document. The data in the preceding document originally comes from the customer and material master records. Because the data is copied from the preceding documents into the sales document, any changes that have been made to the master data records since the preceding document was created are not included in the sales document. If, when you create with reference, you add another item to the document that was not in the preceding document, the system determines the data for it from the master records, such as the material master or info record.
    You have created an inquiry and a quotation with reference to this inquiry. Before you created the quotation, you changed some data in the material and customer master records.
    You have changed the material description in the material master record. This description is stored in the sales document at item level.
    You have changed the terms of payment in the customer master record from ZB01 to ZB03. These are stored in the sales document at header level.
    When you created the inquiry, the system copies the original material description to the item. If you enter another item in the quotation for the same material, the system displays the new material description for the new item.
    However, the system continues to propose the original term of payment, that is, ZB01, for all items including the new one. This is because it is copied from the header of the preceding document into the header of the quotation, and the change in the customer master record has no affect on the quotation.
    Regards,
    Naveen.

  • Doubt in creating a sales order with reference to contract

    Hi all,
    when I create the sales order with reference to contract, in the table VBFA, the field PLMIN is set to zero some times and set to '+' some times. May I know whats the functionality behind this. Any pointers on this will be helpful.
    Regards,
    A.Rathinaprakash

    Hello A.Rathinaprakash,
    This is an Indicator which indicates the quantity or value in the target document(means Sales order) has a negative effect, positive effect, or no effect at all on the quantity still to be completed in the source document(means contract).
    Example from the Help file..
    In sales documents, for example, you can expect the following results:
    Quotation   -> Sales order: positive effect
    Contract    -> Return: negative effect
    Sales order -> Sales order: no effect
    In billing documents, for example, you can expect the following results:
    Delivery    -> Invoice: positive effect
    Delivery    -> Cancellation: negative effect
    Delivery    -> Pro-forma invoice: no effect
    Hope it helps..
    Regards,
    HP

  • Sales order with reference to sales order

    Hi,
       I need to create a sales order with reference another sales order using bapi CreateFromDat2.  Please note, Sales Ord. Dist. channel, Div, sold-to to of the new order are different from original order.   I gave reference order in field order_header_in-REFDOCTYPE .  I am getting following error when I perform single test " FB Call: insufficient parameters.  Can any of you tell me how to overcome this issue.  And is it possible to create an order refering to another Saler order with different Sales Ord, Dist. channel, Division, sold-to ?
    <b><REMOVED BY MODERATOR></b>
    Cheers
    Sudhaker
    Message was edited by:
            Alvaro Tejada Galindo

    There is an OSS note <a href="https://service.sap.com/sap/support/notes/370988">Note 370988 - BAPIs in SD: Creation with reference</a>
    <i><b>Symptom</b>
    This note describes the problems of the 'Create with reference' function when using BAPIs to create sales documents.
    If you are working online, you can use this function module to create a sales document with reference to an existing sales document or a billing document (for example, a debit or credit memo request) according to fixed rules. The rules for transferring information from the source document to the target document are defined in the copying control on header and item level. The creation with reference permits an item selection.
    When you use BAPIs in SD, a function of this type is not fully available. A reference is only possible for a quantity contract, so that the target quantity of the contract can be reduced by the order quantity of the sales document. Furthermore, the document flow is also updated.
    As an alternative to 'Create with reference' in Transaction VA01, two variants are provided for solving the 'Create with reference' problem in the BAPI.
          1. Create a '1:1 ' - that is, a document copy of a sales document (customer quotation, order) with 'BAPI_SALESDOCUMENT_COPY'. At this point, you cannot create the 1:1 copy of either a billing document or a delivery.
          2. Create a sales document that refers to an existing document with 'BAPISDORDER_GETDETAILEDLIST' and 'BAPI_SALESORDER_CREATEFROMDAT2'.
    <b>Other terms</b>
    BAPI_SALESDOCUMENT_COPY, BAPI_SALESORDER_CHANGE, BAPI_CUSTOMERINQUIRY_CHANGE, BAPI_CUSTOMERQUOTATION_CHANGE, BAPI_SALESORDER_CREATEFROMDAT1, BAPI_SALESORDER_CREATEFROMDAT2, BAPI_SALESORDER_CREATEFROMDATA, BAPISDORDER_GETDETAILEDLIST
    <b>Reason and Prerequisites</b>
    As of yet, no method exists for creating a sales document that refers to an existing document.
    Solution
    For solution No. 1
          1. Create the documents using the BAPI_SALESDOCUMENT_COPY function module. However, this only permits a 1:1 copy without factoring out individual items.
          2. After you have created the document copy, you can use a change BAPI to edit this copy.
    For solution No. 2
          1. Collect the data for the reference document (for example a customer quotation) with the 'BAPISDORDER_GETDETAILEDLIST' function module. In the example code, focus exclusively on the partners, items, schedule lines and conditions.
          2. Prepare the Data. Execute the 'copying control' manually. This way, you decide which values are to be transferred.
          3. Create the sales document using the 'BAPI_SALESORDER_CREATEFROMDAT2' function module by transferring the prepared data.
          4. Finally, you must remove a COMMIT WORK so that the sales document can be written into the database.
    An example of solution 2 is attached as a text file. You are allowed to select items and quantities for example, if you use input parameters. If there are no entries, then transfer 1:1 from the reference document. When you enter the 'condition type' parameter, you can determine whether conditions are copied or recalculated ('G' for transferring from the preceding document; 'B' or ' ' for re-determining, and 'C' for re-determining with transfer of the manual elements).</i>
    Sample : <a href="https://websmp108.sap-ag.de/~sapidb/012003146900000486112004E/BAPI_COPY_WITH_REF.txt">ZZ_MS_BAPI_COPY</a>
    Regards

Maybe you are looking for

  • Upgrade fee not refunded

    On 5th July I chose to upgrade 3 days early and pay a £53 fee. After doing so the store was unable to give me my phone. They contacted EE who spoke to me and said they had refunded the fee there and then. I upgraded 3 days later when it was free but

  • Help with faulty monitor

    Hi all I have a 19" CRT monitor which I use with my G5. The monitor has developed a fault and I wonder if anyone might be able to help diagnose what the problem is. Whenever there is a large area of white on the screen the picture develops a high fre

  • Return delivery to import vendor

    Hi all, I have Created an 1.) Import PO. 2.)custom Miro done 2.) GRN done at Port Plant 3.) Created a STO and recived material at working Plant 4.) Invoice verification done Now,I want to return a material to import vendor, what will be the steps to

  • Finder issue-Font always bold in list view

    In icon view and column view, the font comes out perfectly normally, but when I switch to list view, the font is bold!!! For some reason, it bugs the heck out of me! Anyone have any suggestions?

  • 2.1 Autogenerate GROUP BY and anlaytic functions

    I love the auto-generate group by feature, but I use analytic functions more frequently these days and that makes the feature a little less usable. Would it be possible for SQLDeveloper to remove a group by that is automatically added if when the OVE