Create Sales Order for Repair

Hi All,
I want to create a Repair Sales Order using BAPI 'BAPI_SALESORDER_CREATEFROMDAT2'.
When I create the order using tcode VA01 it asks me to enter Material, Servicable Material and the Repair Information.
How can I pass the Servicable Material and the Repair Information to the above BAPI.
Any help will be appreciated.
Regards,
Shubham

Hi
Please refer to the following documentation.
Method
SalesOrder.CreateFromDat2
Sales order: Create Sales Order
Functionality
You can use this method to create sales orders.
You must enter at least sales order header data (via ORDER_HEADER_IN structure) and partner data (via the ORDER_PARTNERS table) as input parameters.
Enter the item data via the ORDER_ITEMS_IN table. You can allocate item numbers manually, by filling in the relevant fields, or the system does it, according to the settings for Customizing, by leaving the relevant fields blank.
If you have configurable items, you must enter the configuration data in the ORDER_CFGS_REF, ORDER_CFGS_INST, ORDER_CFGS_PART_OF and ORDER_CFGS_VALUE tables.
Credit cards can be transferred via the BAPICCARD structure, on the one hand, data for card identification, on the other, data for a transaction which has taken place in an external system.
Once you have created the sales order successfully, you will receive the document number (SALESDOCUMENT field). Any errors that may occur will be announced via the RETURN parameter.
If no sales area has been created in the sales order header, then the system creates the sales area from the sold-to party or ship-to party, who has been entered in the partner table. If a clear sales area cannot be created, you will receive a system message, and the sales order will not be created.
Notes
Mandatory entries:
ORDER_HEADER_IN : DOC_TYPE Sales document type
SALES_ORG Sales organization
DISTR_CHAN Distribution channel
DIVISION Division
ORDER_PARTNERS..: PARTN_ROLE Partner role, SP sold-to party
PARTN_NUMB Customer number
ORDER_ITEMS_IN..: MATERIAL Material number
Ship-to party:
If no ship-to party is entered, use the following: Ship-to party =
sold-to party.
Commit control:
The BAPI does not have a database commit. This means that the relevant application must leave the commit, in order that can be carried out on on the database. The BAPI BAPI_TRANSACTION_COMMIT is available for this.
German key words:
The following key words must be entered in German, independantly of
the logon language:
DOC_TYPE Sales document type, for example: TA for standard order
PARTN_ROLE Partner role, for example: WE for ship-to party
Further Information
You can find further information in the OSS. The note 93091 contains general information on the BAPIs in SD.
Regards
Inder

Similar Messages

  • Duplication of Purchase Order while creating sales orders for a customer

    when we try to create sales order for one customer it have to create by picking up the purchase order from the table linearly.
    But the problem is that here when we are trying to create multiple sales orders the same purchase order is being picked.
    for example..when we create sales order 1 the purchase order picked is PO1 and
    for creation of sales order 2 the same purchase order PO1 is being picked up instead of PO2.
    No idocs are being generated in this, even to check them..
    How shall i resolve this...? Please help me out ASAP

    Hi Kumar,
    Thanks for the reply. But actually the problem is that this is related to some customized table in the project. When a EDI Batch job runs in the background then automatically the SO is created and the PO is being picked from the table(custom table) and then posted against the respective SO. we are not aware of that job which is triggering this to debug. Once if we can know that particular batch job or pgm or edi or idoc what ever it is then we can debug.
    Do you have any idea how can we find that particular pgm/edi/idoc/job name which triggers this creation of SO?

  • Creating Sales Order for Item Category TATX (Text)

    How can I create Sales order for text item where no material master has been maintained?
    It does not give me any conditions and no accounting document.
    What I need to do if I want to create that with a value?
    Thanks
    ST

    Hi,
    Its not possible to create an SO w/o material code.
    But you can create an dummy material.
    This dummy material can be just an refer to create an SO.
    Do refer the below help doc which may help you..
    Settings in the Material Master (Dummy-Material) - mySAP Engineering & Construction - SAP Library

  • Creating Sales Order for "Payer" thru VA01 trans.

    Dear All,
    In our project, we have stations which r  <b>Sold-to-party</b> and <b>Credit customers</b> which is a <b>Payer</b>.
    We have to create <b>Sales order</b> for both <b>Stations</b> and <b>Credit customers</b>. Creating Sales order for Station is not a problem but each station has many credit customers, which are maintained in the Station.
    When we are creating Sales Order via <b>VA01</b> for a particular credit customer, we are entering Station as a sold-to-party and it asks for Payer which is the Credit customer for that station.<b>But when we are recording through SHDB transaction it is not asking for payer(credit customer for that station).</b>
    Please let me know  of BAPI or some other method to create sales order for credit customer(Payer). 
    Kindly help at the earliest.
    Thanks and Regards,
    Sudipto.

    Hi,
    There is TABLES parameter where you can pass the PARTNERS information. I am not sure of the parameter name but it would refer to something like BAPIPAR.
    Regards,
    Ravi
    Note : Please mark all the helpful answers.

  • 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
    Bhargavi

    Look 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

  • Error while creating sales order for material with another DIVISION

    Hello Friends,
    I have a problem with my sales order creation.
    I have defined a new sales area 0010 / 10 / 01. I have the sales order type assigned to this sales area. (in VOV8 for the sales order type, in the 'General Control' the 'item division' is flagged.
    Now, I have created the sold to party XYZ with all the partner functions defaulted same as the sold to party for the sales area 0010 / 10 / 01.
    NOW, I have the material ABC with the DIVISION 10 in the basic data. I have extended the material to my sales org & dist. channel & plant.
    Now, while creating the sales order for my sales area 0010 / 10 / 01 , I enter the sold to party XYZ - it is OK. But when I enter the material ABC, I get the error - "SHIP TO PARTY IS NOT DEFINED FOR SALES AREA 0010 / 10 / 10"
    Please help to resolve the issue.
    Edited by: Vivek on Aug 13, 2009 9:04 AM

    Hi
    Common division for Material Master data will not work
    Because in the material master Division is a field not an organizational unit
    Means when you create MMR you will give sales org, DC, Plant  as organizational units and then enter but not division
    Division is a field maintained in basic data and sales org data 1
    This is the reason in t code you will find in t code VOR2 Common division only customer and conditions but not materials
    But in t code VOR1 Common DC ,customer  conditions and materials all there are available (you can check these t codes)
    Coming to your issue Item div is clecked in your order type
    This means the division in MMR has the priority or control for that order type
    Your header division is 01 ( taken from customers sales area) and item division is 10 (taken from MMR as per your post)
    So it differs
    To process this order with Item div is clecked in your order type you need to extend your Sold to party ABC to the sales area 0010/10/10 (the sales area where the division of the material falls)
    or alternatively
    There should be a  customer say DEF created in sales area 0010/10/10 who will be a ship to party ( your error is also the same)
    for your ABC  that is sold to party in sales area 0010/10/01 where the order is registered
    Hope yopu are getting it
    ABC in sales area 0010/10/01 will have  or should have ship to paty DEF  in sales area 0010/10/10 
    or
    ABC should operate in in sales area 0010/10/10  too
    If item division is not ticked then these are not necessary as the header division 01 will be valid for all items and syatem will not look MMR at all for division
    Regards
    Raja

  • Created sales order for one division, for which the material belongs to ano

    Dear All,
    A sales order has been created for a division 10, for which the material belongs to some other division 20 in material master.
    When we are  create a sales order for 10 division ( the one which we give at organzational data) at the item level the material which we select should also belong to the same division, if  the material division  is different as 20 the system will throw an error at sales order  saying "ship-to-party so and so is not created for the sales area so and so.."
    But here it's allowing me to create a sales order for division 10 with 20 Division material without any error. But this should not happen.
    Checked in the document type VOV8 where at the Check division field 2 has been there.
    Please suggest

    Hello,
    Let me explain the concept of Header division and item division...the header division is the one which gets copied from the sales area division that gets determined in the sales doc creation from SP.
    The item division is the division that gets copied from the material master in the line item material.
    In the Sales document type , there is a check box "Item Division". If this is marked, then system takes the division from the Mat master. if this is not marked system the system doesnt find from MMR instead it picks up from header division.
    The check division controls, how the system should behave in case the header and item division differ..
    Rgds,
    Rags.

  • Error while creating sales order for a new company code

    Hello SD Gurus,
    The client wanted us to create a new Company Code, Plant, and Sales Organization. We created them. I extended the customer and material in QAS. Now, I'm trying to create one sales order in QAS but the system is throwing one error: "Maintain Profit Center Value in Custom Table in YSD_PROFIT_CNTR".
    I googled for this error but found nothing. Could you please give me the solution asap. I need to prepare test script.
    Thanks in advance
    Regards,
    Anwar

    Dear Mohammed,
    The error message itself states where is the issue. You need to maintain the profit center in table
    YSD_PROFIT_CNTR. This is not SAP Standard provided solution. I guess during the time of implementation team has suggested to maintain the profit center in custom table.
    If the table is"maintenance view" then you can check through SM30 and maintain the relevant entry. If not check if there is any transaction code with attached to this table. This you can check by going through SE93 and by entering Z* or ZSD* or Y* or YSD* and press F4, If the transaction code is starting with Z or Y it will open all the list of transaction codes. By going through the description of the transaction code. you can pick the right transaction code in case if any exists for this table.
    Hope this information is useful to you.
    Regards
    Murali

  • BAPI for Creating Sales Order For Variant Configuration Materials

    Dear Gurus,
    Before posting this thread, we have referred many SDN threads, OSS notes and other sites for any sort of help..but no success..All threads and other referrals are not much of help as they are kind of incomplete( Perhaps, we are unable to understand them..no offense).
    Few checked threads on this subjects are:
    http://scn.sap.com/thread/34590
    http://scn.sap.com/thread/851070
    http://scn.sap.com/community/abap/blog/2014/04/23/update-vc-variant-configuration-data-using-standard-bapi-in-sales-order
    http://scn.sap.com/community/abap/blog/2014/07/15/creating-orders-with-variant-configured-items-using-bapisalesordercreatefromdat2
    http://scn.sap.com/community/abap/blog/2014/04/23/update-vc-variant-configuration-data-using-standard-bapi-in-sales-order
    http://scn.sap.com/thread/120144
    OSS: 549563
    Well, we're using the BAPI (BAPI_SALESORDER_CREATEFROMDAT2) which creates the sales order successfully but without the characteristic values in line items.
    We're passing data to the following parameters - ORDER_CFGS_REF, ORDER_CFGS_INST, ORDER_CFGS_VALUE to create the variant config but not able to see it getting created.
    Pls find attached BAPI coding document for your reference.
    If you could throw any light on this issue will be of great help for us.
    Thank You in Advance!!!
    Reg,
    Jagan-SD.

    Jagan nath
    Try below.
    you would need miimum of 3 segments to pass variant config data using this bapi
    ORDER_CFGS_REF for each configurable item
    POSEX = ITEM #
    CONFIG_id , root_id - Start with 1 and increment it for each configurable line item
    ORDER_CFGS_INST
    CONFIG_ID - from above
    INST_ID - Start with 1 and increment it for each configurable line item
    OBJ_TYPE = "MARA'
    CLASS_TYPE = '300'
    OBJ_KEY = material #
    ORDER_CFGS_VALUE
    CONFIG_ID for the item, INST_ID for the item
    charc for characteristic value
    VALUE for characteristic value
    Reference thread
    How to Fill Configuration Data in BAPI BAPI_SALESORDER_CREATEFROMDAT2
    Hope it will solve your issue.
    Thanks
    Ritesh

  • How to create service items and sales order for service contracts.

    Hi,
    I have created item using Purchased Item template and one more item(service item) using service /warranty program template. Then I have used these items to create sales order with service item in it and closed that order , but Iam not getting this order in service contracts. Is this right way to create sales order for service items. I
    item name:- personal_computer
    copied from purchased order template. service is enabled and install base is checked and enable service coverage is enabled.
    item name:- service_item
    copied from service /warranty program template
    service is selected to inactive,
    service type: service
    duration: 1 year
    template: Gold
    and saved the item.
    Then I have used these two items in sales order for service contracts. But that sales order is not hitting in service contracts. Is there any error with item creation.
    Thanks,
    Bharat G.

    Following SAP Notes to be referred for Service Tax:
    1.     778976 u2013 Service Tax and Ecess on Service Tax
    2.     1032265 - SEcess on Service Tax
    Regards
    AK

  • Create Sales Order with reference to Quote for different customer

    HI Expert
    Any idea how I may be able to do this?
    Create Sales Order - for Customer B (VA01) with reference to a completed Quote for Customer A. While keeping the line items, quantity and pricing exactly the same.
    Quote - Customer A -
    >  Sales Order - Customer B
    Any suggestion will be greatly appreciated.
    Thanks

    HI
    Go toT-Code VTAA , IN Header Level "Copy Requirements" Field Maintain Routine "002"
    Go to VA01 , Enter the Order Type and press Enter and Enter the Sold to party , after that Sales Documents --> Create with Reference
    Regards,
    Prasanna

  • To release credit check while creating sales order

    Hi,
    I have a requirement of releasing credit check for list of open sales orders of a customer while creating a new order in VA01 for a customer.
    E.g in va01,i'm creating sales order for kunnr ABC
    for kunnr ABC, open sales order existing in database are 1,2,3,4
    So i need to release credit check for 1 2 3 4 while creating a new sales order in VA01.
    If i use FM 'SD_ORDER_CREDIT_RELEASE' in VA01 user exits it again call standard program and gives some error.
    I need to know the exact point to implement the code if someone can help and also if there is another way of releasing credit check other than above FM.

    Hello,
    Why don't you use the include MV45AFZZ, userexit USEREXIT_SAVE_DOCUMENT_PREPARE.
    You can write your code to identity all the sales orders that are due to be released for a customer and then release them.
    Edited by: Kanwardeep Singh Gill on Apr 8, 2010 5:28 AM

  • Creating Sales Order- Item Category TAN is not defined.

    Hello all,
    I am working on Creating sales order for Global Bike Inc case. But when I enter the material and quantity number and click check mark it says "Item category TAN is not defined". Can some body help me how can we define TAN or why it is giving me that error.
    Thanks in advance.
    Sujan

    Hi SujanB,
    As your question is already answered. An indicator that defines the characteristics of a document item.
    For example, the item category controls the type and scope of:
    Pricing
    Billing
    Delivery
    Inventory posting
    Transfer of requirements
    Providing further deatils ;--
    01. How item category is determined :--
    Depending on the item category group that you apply & the sales doc type you are processing the system automatically proposes an item category in the document.
    1.sales document type (source: order type)
    2.item category group (source: material master)
    3.item category of the higher-level item (source: user defined)
    4.item category usage (The usage is defined by SAP and is hard coded in the programs)
    SPRO- IMG- SD- Sales- Sales Document- Sales Document Item- Assign Item Category (VOV4)
    Pls refer following link for furter details ;--
    general item category group
    item category usage  in item category determination
    http://help.sap.com/saphelp_46c/helpdata/en/dd/55fb13545a11d1a7020000e829fd11/content.htm
    http://www.slideshare.net/magnatraining/item-category
    Hope it helps....
    Thanks/Rajesh

  • Delivery date in Sales Order for Make to Order Scenario

    Hello,
    We are creating Sales order for MTO ... In that our requirement is to get the delivery date based on Production planning and not from RLT. ie we have configured RLT as 36 days, system calculates delivery date as 36 days from the date of order what ever be the order quantity but considering our plant capacity  this is not possible. In our Production planning we allocate certain numbers per week. so when we give 100 nos order it plans as per the allocation if we see through MD73 it will give clear picture but in our sales order it shows delivery possible date as 36 days from date of PO. How to correct this.. it should calculate from the date of beginning of the production process.
    Can any one help in finding solution for this
    Thanks in Advance

    Hello,
    We are creating Sales order for MTO ... In that our requirement is to get the delivery date based on Production planning and not from RLT. ie we have configured RLT as 36 days, system calculates delivery date as 36 days from the date of order what ever be the order quantity but considering our plant capacity  this is not possible. In our Production planning we allocate certain numbers per week. so when we give 100 nos order it plans as per the allocation if we see through MD73 it will give clear picture but in our sales order it shows delivery possible date as 36 days from date of PO. How to correct this.. it should calculate from the date of beginning of the production process.
    Can any one help in finding solution for this
    Thanks in Advance

  • Error while creating sales order

    while creating sales order for a particular plant there is error coming
    NO NUMBER RANGE FOR DOC TYPE ZOS1VXBAK-AUARTSILD
    PLANTXVBAK-VKBUR.
    Intailly I have check the no series we have internal no series for all plant,the 
    number series which start 195000001, only one plant the giving the above error, rest all plant it is as applicable above series.
    kindly guide me for the same.

    Hi Sanjay
    This is regarding number ranges defining and assigning tips which you can follow as below:
    Whenever there is a new Sales Org being created, you will be required to maintain Number Ranges for Sales Documents which are allowed for your New Sales Area.
    Number Ranges can be maintained Internally by the system, however it can be maintained externally also if you customize it accordingly.
    In Standard SAP the Transaction code for Maintaiing Number ranges externally is VN01.
    Defining - The same can be reached through in IMG as : Sales & Distribution>Sales>Sales Document Header-->Define Number Ranges for Sales Documents.
    Here you provide the system a specific Number range as follows:
    Number range Key Start Number range End Number Range+Current Number
    For Example: If you want to propose the following Number Range
    *1     9000076000      9000076999      0
    The Current Number field will be kept zero as you are proposing new number range and no sales documents have been created on it , Obviously..
    *1 is a Unique Two digit Alphanumeric Key, while proposing your key, you should ensure that it should not be there in the system as existing.
    If you propose a key that is there in the system or if the Number Range (Start and End Series) is there in the system already, the system will throw a message that Interval already already exists. So choose a key that is unique, and which is not there in the system.
    Here , by making this , you are assigning a Key to a Number Range Series.
    All the symbols can be used along with numbers from 0 to 9 and Alphabets from A to Z and in any order. For example: !1, ^A, BB,Z*,M2.........
    Assigning - In Assigning, you assign the particular Sales Document to the Number Range you have already proposed as above.
    The Assigning Part is done as follows:
    The Two digit Alpha Numeric Key is maintained or Assigned to the respective Sales Document type in V0V8.
    This can also be reached in IMG by:
    Sales & Distribution>Sales>Sales Document Header-->Define Sales Document Types
    Locate the particular Sales Doc Type, and double click on it to display it configuration. Here you put the Two Digit Number key in the Field- "Number range External Assignment"
    Besides this:
    If a new Shipping Point is created then Delivery Number ranges are required to be maintained.
    Similarly,
    If a new Plant is created then Billing Number Ranges are required to be maintained.
    Regards
    Naren

Maybe you are looking for

  • How to find out the maximum value in a Query

    Dear all, Im creating a Query on 0SD_C03 where i have to disply Maximum value of a material.. EX: MATERIAL BILLED VALUE x                   1000 y                   3000 z                   2500 in a analyser i have to display only Y and 3000 We are

  • Why is the iTunes download on XP failing?

    I've tried to download the  iTunes executable file onto my XP numerous times this evening via Firefox. I confirmed that I'm downloading the version for Windows, and I've confirmed that I have Service Pack 2. I direct it to save onto my desktop, but i

  • Uploading Security profiles & Security rights using sourcing Workbook

    I am trying to use workbook to upload Security profiles & Security rights, and finding it difficult to get the "Resource" field mapping attributes in "eso_security_profiles" tab of the workbook. Is there a reference sheet for this, or a place from wh

  • Satellite M70-168 : new HD and OEM license

    Hi, My Satellite is out of garantee ..... Original HD (80 gb) has broken, and it's impossible to find the same HD. I will replace by a HGST Travelstar 5K750 HTS547575A9E384 - HD - 750 Go - SATA-300 . 1 - I think that Sata 2 (sata 300) is compatible,

  • Ruby on rails application problem

    hi, I have installed the ruby on rails architecture. I also have created an application and it is running also..but the problem is when I try to add,edit or delete any record it gives me the error..: ActiveRecord::RecordNotFound in DepartmentsControl