Automatically referring Quotation by the given Sales order material

Hi,
While creating Sales Order through VA01, based on the material entered in Sales Order it should refer back the available Quotations for customer and material and create Sales order w.r.t Quotation. Sales order should get created as if it is created w.r.t Quotation.(This is only 1 Quotation-1 Sales Order scenario )
We tried to provide the solution with the available User exits SAVE_DOCUMENT_PREPARE and MOVE_FIELD_TO_VBAP located in MV45AFZZ program.
and also SAVE_DOCUMENT. By forcibly maintaining XVBFA[] we could able to achieve only u201CSales order is referring the Quotation and Quotation is referring Sale order in document flowu201D, But we need Quantity consumption of material in quotation for created Sales orders should get reflect in quotation.
Solution is not complete till the consumed quantity of quotation is not getting reduced in Quotation Header and is not getting referenced.
We tried other options below too, any pointers would be of great help.
Approach 1:-
Implementation of BAdI  u201CBADI_SD_SALES_ITEMu201D and corresponding interface method.
u201CIF_SD_REF_DOC_CUST~SEARCH_FOR_REF_DOCu201D BAdI documentation shows no further implementation is required but tried the option.
But could not found the proper u201Cchanging/Export parametersu201D for the interface method. By observation BAdI triggers for similar kind of configuration made in approach 2 mentioned below.
Approach 2:-
Tried changing with the configuration settings of Quotation messages for u2018Z001u2019 order type in VOV8 transaction.
This gives us the popup at run time with the available Quotations for each item.
We tried to suppress this pop up and repeat the same process programmatically and call the same perform u201CBELEG_POS_KOPIEREN_AUS_LISTEu201D of program u201CMV45AF0B_BELEG_POS_KOPIEREN_AUu201D from exit u201CUSEREXIT_MOVE_FIELD_TO_VBAPu201D. Unfortunately this calls copy control and falls into infinite loop.
Open approach still requires investigation:-
Instead of calling the perform directly in approach 2, we need to populate the fields/tables in debug mode and check.
Thanks much,
Vishnu.

Hi VIshnu,
We have got a similar requirement in our project. Can you please let me know if you were able to get the solution for this?
Would you please help me with the approach that you have taken.
Regards,
Aparna Alashe.

Similar Messages

  • Converting the quotation to the different Sales orders- with doc types

    Requirement : My client wants to create the quotation from Lead and Opertunity..
    Company sells the High tech sofware as well Maintanence, customer may buy both together or only hightech products
    But he both the products can go together up to Quotation.
    When the quotation is converting into the sales order,  we want to change the logic and apply new logic- Program has to create High tech products as sales order and Maintanence products as Contact (i.e both of them has to create two different doc types)
    Both the sales order and Contract has to call two different pricing procedures..
    Please explain to help the following
    a. What is the program name / Function module  that we need to modify to split the sales orders based on the products ?
    b, Setting up the two different pricing procedures, so that based on the item category and doc type it should carry the new pricing procedure..
    Can some one help me to provide the steps in sequence..
    Thanks
    Larry
    Edited by: Larry Troy on Nov 8, 2010 4:24 AM

    Hi
    Copying the products from quotation to only sales orders and services to only contracts can be done with the help of copy controls. If we donot maintain the copy controls between quotation and sales order at item level for services (relevant item category), the copying can be controlled. Similarly, copy controls between quotation and contract at item level should control copying the products and should allow only services. System will give information about not copying the items while creating the subsequent documents(contract or sales order).
    Thanks,
    Ravi

  • Quation getting referenced automatically through Sales order material

    Hi,
    Quation  should get referenced automatically through given Sales order material.Assume Quation is fixed for all materials entered in Sale sorder.
    i tried using user_exit_move_field_to_vbap and user_exit_save_document_prepare.And updated XVBFA,XVBAP programatically.
    Sales order and Quation(at item level) are getting referenced but quantity of qutaion is not getting reduced by the quantity consumed and MD04 does not reflect the same.
    Can you please help with the pointers.
    Thanks much,
    Vishnu.

    Hi,
    As per standard SAP the description is copied from the material master but the same can be edited while creating the sales order. Take the help of ABPER to debug it find out the error.
    Regards

  • VA01 - sale order Material Configuration values to be read

    Hi,
    I am trying to read the entered sale order material configuration values in TCode VA01 and update the xvbap in userexit USEREXIT_CHECK_VBAP in program MV45AFZB.
    Kindly let me know to get the material configuration values in this userexit.
    Regards,
    Rajanbabu R

    Dear Rajesh,
    The strategy type 25 has been copied and the following fields are modified as follows for the new strategy type Y5.
    Requirement type of customer requirement YT5 instead of standard entry KEK
    Requirement class YT5 instead of standard entry 046
    Account assignment category -  E instead of standard M
    Settlement profile - SO1
    Configuration field - defined as 'allowed' instead of standard setting ' Mandatory '
    The field PQTY in the procurement  tab page for that particular line item is greyed out and we are unable to key in the value YT5.Unless I entered this value I am not able to procure the component of that line item in that sale order.
    Please suggest me any means to enter this value . Shall I configure the BOM for that line item and fix it again in CU51.
    Thanks and Regards,
    Ram

  • How to  find the Open sale orders till date for  given plant and material ?

    Hi experts,
                     I have a requirement to calculate the open sale orders for a given plant and material. I have tried in VA05 wherein i can get only for the material and sales area combination. From the document nos obtained from VA05 i can then find the plant. But my question is how do i get the output of VA05 into my progra. (can i use submit for a module pool report ).
    Also if ther is some other standard table or Function module to find the open sale orders till a given date ,it will be even more helpful....in which case i can drop the VA05 route.
    Kindly help
    Thanks in advance
    Ashwin

    Hi Ashwin,
        You can use SAP Tables VBAK and VBUP to get to know if the document is complete or not.
       VBUK-GBSTK is the field that will give you the status of the Sales Order .
      VBUK is used at header level , whereas VBUP is used for Item level.
      So in your case what I would do is :
      Get the Sales Orders that satisy the plant and material criteria from VBAP table , take this Sales Document numbers and go to VBUK or VBUP table to get the Sales Order Status. 
       If I need to find the open quantity as well I will link to VBFA table based on the document number.
      Reward if helpful.
    Thanks,
    Imran

  • Automatically generate Delivery No-  after saving the return sales order

    Dear All
    Return sales process-
    When am saving the return sales order that time Delivery should be generated automatically in backend process.
    Tell me the procedure how the delivery should be happened automatically without PGR.
    thanks
    sunil

    Hi sunil
    Do the following customization for the Document type RE in VOV8
    1) Immediate delivery  -  X
    2) Lead time in days   -  Blank
    3) Shipping conditions - 10 (immediately)
    Also check the shipping point days (picking time , packing time etc) in shipping point details .As system will consider those days and give the delivery date after considering all those days also
    Regards
    Srinath

  • How can i get the open sale orders for given material no and plant

    Hi,
    I have to retrieve the open sale orders depending on the material number and plant.
    For only open sale orders at header level and item level.
    I want to use VBUK-GBSTK to find open sale order at header level and
                          VBUP-GBSTA at item level.
    Can any one suggest me the best logic as performance is concerned?           
    Thanks,
    Kumar.

    hi Prasanth,
    select werks matnr from ZVSCHDRUN into table it_plant.
    sort it_plant by matnr werks.
    select
            vbeln
            posnr
            matnr
            werks
            erdat
            kbmeng
            vrkme
            from vbap
            into table it_vbap
            for all entries in it_plant
            where matnr = it_plant-matnr and
                  werks = it_plant-werks.
    and again i have to write one more select query for vbup.
    am i right?

  • BDOC's to update the custom fields in R/3 from the CRM sales order

    Dear All,
    I need a small help.
    My requirement is as follows.
    When ever a sales order is created in CRM, an outbound delivery will be automatically created in the R/3 system.
    There are some fields in the CRM sales order which are not there in the R/3 system.So I have to create these fields in the LIKP and LIPS tables in R/3 which is not a problem.
    But I have to copy these fields from CRM to the LIKP and LIPS tables in R/3 when ever a sales order is created and saved in CRM. (This should happen automatically)
    So could anyone tell me whether there are any BDOC’s available to update the sales order info in the LIKP and LIPS tables and also any BADI which can be trigger for this purpose.
    Thanks in advance.
    Regards
    Shafath

    Hi,
    Thanks a lot. You have given a good solution.
    But a small correction.
    Sales Order is not transferred from CRM to R/3. The system is creating (automatically) a delivery in the r/3 system for the sales order created in CRM (Here we will not have the sales order in R/3), so we don’t have an entry in VBAK and VBAP tables.
    When we create a sales order in CRM and save , the delivery in R/3 is created and the sales order is not transferred to R/3.
    So while saving the sales order itself in CRM, I need to trigger a badi to update the LIKP and LIPS tables by calling a RFC (which needs to be developed in R/3).
    So I need a badi which triggers when the sales order is saved and which tells whether the sales order is saved without errors or not (because delivery in R/3 is created for only those orders which are created and saved without errors in CRM)  and returns the sales order number.
    It will be helpful if you can send some info on this.
    Any how thanks a lot for your quick response.
    Regards
    Shafath

  • How can i find differnet output types for a given sales order ?

    hi all,
    answer my question please........?
    how can i find differnet output types for a given sales order ?

    hi
    check in NACO transaction if you have assigned access sequence to your output ytpes and if you have ticked checkbox "Access to output conditions" - otherwise it will not even try to access condition records.
    From help :
    Access to output conditions
    Indicates whether the system determines the output by searching for valid
    condition records.
    Procedure
    If you want the system to search condition records for the appropriate
    output, mark the field.
    Note
    If you leave the field blank and if you are processing sales, shipping,
    or billing documents, the system automatically determines output from
    information stored in the customer master record.
    regards
    ravish
    <b>plz reward points if helpful</b>

  • Free goods from Quotation to Contract to Sales Order

    Hi SAP Gurus,
    I have questions regarding Free Goods. This is the scenario.
    Doc flow as:
    Quotation 123
         Contract 456
               Sales Order (zmor) 789
               Sales order (zkal) 101
    In the quotation 123 & contract 456, the quantity of the item is 50pcs. However, when creating sales order (zmor), if we input 50 pcs as the quantity, the free goods were not determined. What we did was, we lessen the quantity to 30pcs. From there, Free goods were now shown. And then we created another sales order (zkal) for the remaining 20 pcs.
    Questions:
    1.- why is it on the 1st sales order w/ same quantity(50pcs), free goods were not determined?
    2.- i believe that in standard SAP, free goods were not determined in quotation or in contract. Is there a way to determine the free goods on those doc types?
    3.- how about free goods determination in:
    A. Stock transfer order
    B. Product diversion
    C. Consignments
    D. Virtual return
    I am really hoping for feedback on this. Thanks in advance!
    Erza

    Hi,
    Free goods can only be supported on a 1:1 ratio. This means that an order item can lead to a free goods item. Agreements in the following form are not supported: u2018With material 1, material 2 and material 3 are free of chargeu2018 or u2018If material 1 and material 2 are ordered at the same time, then material 3 is free of chargeu2018.
    - Free goods are not supported in combinations with material structures (for example, product selection, BOM, variants with BOM explosion).
    - Free goods are only supported for sales orders with document category C (for example, not quotations).
    - Free goods are not supported for deliveries without reference to a sales order.
    - Free goods cannot be used in make-to-order production, third-party order processing and scheduling agreements.
    Regards,
    Saju.S

  • Tracking the actual sale order quantity

    Hi Friends,
    How to track the actual sales order quantity given by the customer.
    Ex: we assume the customer has placed an order of 100 units and stock is only 90 so we create the sales order for 90 units only.
    How to find out the difference of 10 units as a report in standard sap system.
    Thanks
    AJ

    Dear AJ,
    This is how normal sales process works.
    You create Sales Order line item for the quantity that customer has requested. (eg: 100)
    Then you do a ATP for that Line item. Let's say you have only 90 in the stock. In that case system will confirm 90 for the sales order line item. (You can see the confirmed quantity in the Schedule line tab)
    Normally we don't change the LI quantity as per the ATP confirmed quantity (i.e 90). Because then we loose the visibility to the customers original requested quantity (i.e 100).
    Say you don't change your Line Item Order quantity to 90. Then your delivery & billing will be for 90.
    So you can see in VA05, Order quantity as 100 and confirmed quantity as 90.
    Your sales reports will show delivery & billing as 90. So that you have a clear visibility to the original order quantity, delivered quantity & billed quantity.
    Further if remaining (open) quantity 10 is appearing your MRP & creating troubles, please use Line Item Rejection Reason as Completed. So that everything is perfect.
    Coming back to your issue.
    Since your changing LI quantity to 90, you cant see 100 in the VA05 report. It always show the existing sales order line item quantity, which is 90 in this example.
    Only way you can find your original sales order quantity is in the Line Item / Change Log.
    This can be view by selecting below Menu option.
    Environment -> Changes
    If you execute it for the relevant Line Item, you can see the Change log. In that by double clicking relevant quantity change line, you  can see the old value & new value. (In this example 100 & 90)
    But that is not a good practice to do as changes will show all quantity changes that you might do based on  customer request. (Imagine if you customer ask to change it later to 95 not 100).
    In that case change log will display 100 to 95, then 95 to 90. So your loosing the required visibility.
    Hope this is helpful to you !

  • Quotation missing error in sales order

    Hi ,
    While saving the Sales.Order in crm  i am getting the error "Mandatory Quotation Missing",  i have preceding document  as Quotaion and billing doc replicated in r/3.
    How to solve this error?? i have checked every thing.
    Kindly help iam i missing anyy thing.

    Hi Shoki
    Did u check  your Quot. Determination has assigned to your  salesorder transaction type
    you  have to assigned following quotation determination to ur sales order transaction type
         No Quotation Determination
    E     Only at Item Level: Assign Immediately if Unique
    F     Only at Item Level: Always With Selection Option
    check Copying Control for Business Transactions
    Hope it answers your Query
    Thanks & Regards,
    srikanth.naga

  • How to put 2 kinds of material prices on the same sales order

    Hello SD Gurus,
    I have a requirement to put a one-time price (e.g. installation price ) and a recurring monthly price on the same sales order.
    I've tried the following but it is not working.
    1. I have a pricing procedure (PSER01) in which I'm using the following price types:PR00 (Defined as a "Discount or Surcharge") and PRSV.  I'm using PR00 to represent my one-time installation price.  I'm using PRSV to represent my monthly+recurring price.
    2. I used it for a material master in a sales order.  I can add PR00 and see the green traffic light.  But as soon as I add PRSV, the traffic light on PR00 turns yellow (Inactive because of subsequent price).
    I've read several posts on the forum regarding this.  Based on my understanding, I'm using two pricing conditions in one pricing procedure which is not allowed. 
    What can I do differently to enable the one-time price and monthly price to appear for my material master on the sales order?
    Thanks so much for your help!

    Hi,
    As per SAP Logic, if the condition type has condition class "C" then only one value is allowed.
    if you want to add two values ( Fixed + Variable) then you can do the following logic.
    1 ) Have one condition type  say ZFIX ( Use this for Fixed Value ) cond class = C
    2 ) another condition type Say ZVAR(Use this for  variable value ) Cond Class = C
    3 ) another condition type say Zxxx ( use this for your Final Value) cond class = C
    now do not assign any access sequence to the third condition type. write a logic in the "Alt Calculation type " routine to get the value of this condition from the sume of ZFIX + ZVAR
    i.e., ZXXX = ZFIX + ZVAR.
    Make sure that the sequence of the codition types are mentioned exactly like the above.
    this is because if you put ZXXX third then the system automatically ignores the value of ZFIX and ZVAR.
    but the values against those condition types will be stores internally. So in future if we want some information also we can trace back..
    let me know if you need further help..
    thanks..

  • Automatic creation of Purchase req form sales order

    What are all the  settings required for automatic creation of purchase requisition  from sales order( from master data and spro)
    Can any one please help me out. Iam new to this topic

    Material master data: purchasing view must be updated with puchasing group and so on.
    sales data: the item categotu group is BANC
    Sales order: the standard customizing determine the TAB item category, in the related schedule line type there is the purchase requisition document.
    have a look to this link
    <a href="http://help.sap.com/saphelp_47x200/helpdata/en/dd/5601d4545a11d1a7020000e829fd11/content.htm">http://help.sap.com/saphelp_47x200/helpdata/en/dd/5601d4545a11d1a7020000e829fd11/content.htm</a>
    Roberto

  • Extracting material classification data for given sales order

    Hi Experts,
    Requirement is I Need to display a report with material and its characteristics values for given sales order. Please let me know if there is any FM/standard tables involved to display the below fields.
    Sales order number, Sales order line item number , Material number , Characteristic Name(ATNAM),Characteristic description(ATBEZ),Characteristic Value(ATWRT),Characteristic value description(ATWTB).
    Thanks & Regards,
    Pavee.
    Moderator message: "spec dumping", please work yourself first on your requirement.
    Edited by: Thomas Zloch on Oct 14, 2011 1:30 PM

    Hi Keshav,
    Thanks for spending your precious time in replying to my thread.
    I did a search before posting, I got an FM which is we cannot use due to performance issue.
    Thanks for letting me know that sales order  has material and material has characteristics,
    But For each characteristics that material has we will have several values, you will be selecting whichever is appropriate based on the requirement.
    If you know the answer pleases post. I have enough patience to wait for answers from other experts.
    Thanks
    Pavee.

Maybe you are looking for