Function Module to create a Sales Order in CRM

Hi Experts,
I want to create a function module which creates a Sales Order in CRM.
As of now, I'm making use of the function module 'BAPI_BUSPROCESSND_CREATEMULTI'.
I have product ID and Quantity.
Please let me know what all rest of the fields are mandatory to create a Sales Order using this function module.
Thanks in Advance,
lakshman.

Depending upon the configuration many things could be mandatory. Assuming no such things in your system, Process type (order type) is required and it is good to give the Sold-To business partner and the Org Details, for the Header information. For the item information, you need the Product and Quantity.
In theory, in CRM, you can create a transaction and "save" it with lot of errors. So, even if you don't give enough information, you will have a transaction with error. You can later fix it the input to fix the errors.
Best way to know is to use your SAPGUI (CRM Online) version crmd_order and find for your implementation.
Easwar Ram
http://www.parxlns.com

Similar Messages

  • Bapi or function module to create a sales order in CRM 5.1 system

    Hi experts,
    Anyone knows any Bapi or function module to create a Sales order in CRM 5.1 system directly.
    Thanks.
    regards.
    Ruchi.

    hi ruchi,
    sory for the late respond, got a lot works to be done.
    based on my experience, you need several more information such as currency, uom for quantity, sales organization, etc.
    and honestly, i have never tried to create an order by just using 3 information ( sold to party, item, and quantity ),
    but i think it is possible because some of the information can be determined using configuration, but still some information is missing and the order that you create will have an error and you can't do next process of the order unless somebody fix / fill the information needed.
    just an idea, perhaps you need some z-tables to put your certain information needed for order creation and the information is maintained for each sold to party ( sold to party is a key of z-tables ) and each time order is created, all information will be query in this tables.
    and for this tables may be you can create an offline maintainance scenario using an adobe document. by this way, the sold to party can maintained all his/her/their information by them self.
    and by using this scenario, you can still maintain / create the order by programming ( perhaps using function module CRM_ORDER_MAINTAIN or else ).
    actually i want to implement in my company but don't have a chance becuase all has been set up and the management will think twice for implementing this scenario.
    hopes it hels
    cheers

  • Function Module to update the sales order header status

    Hi,
      I am looking for a function module to update the Sales order header status.
      Pls. let me know if anybody has used any FM to update the SO status.
    Thanks,

    By mentioning status do you mean Object status or Document status??
    For Object status you may use FM: STATUS_MAINTAIN
    For document status it changes according to flow.
    Regards
    Eswar

  • Trying to create a sales order in CRM with BAPI_BUSPROCESSND_CREATEMULTI.

    hi all,
    I am trying to create a sales order in CRM using the BAPI BAPI_BUSPROCESSND_CREATEMULTI.
    I need the sales order number as the out put. So I am declaring OBJECT_ID as the export parameter.
    This is my source code, I donu2019t get an error, but the sales order is not generated and I donu2019t get any output for my export parameter OBJECT_ID.
    I am setting the tables HEADER,ITEM ,SALES,PARTNER, ORGANISATION, RETURN and
        SCHEDULELINE in BAPI_BUSPROCESSND_CREATEMULTI. But still unable to display the sales order number. Please help me with information
    This is my code
    ***********************************Define the Internal Tables*************************
    DATA: IT_HEADER TYPE STANDARD TABLE OF BAPIBUS20001_HEADER_INS WITH HEADER LINE.
    DATA: IT_SALES TYPE STANDARD TABLE OF BAPIBUS20001_SALES WITH HEADER LINE.
    DATA: IT_ITEM TYPE STANDARD TABLE OF BAPIBUS20001_ITEM WITH HEADER LINE.
    DATA: IT_SCHEDULELINE TYPE STANDARD TABLE OF BAPIBUS20001_SCHEDLIN WITH HEADER LINE.
    DATA: IT_PARTNER TYPE STANDARD TABLE OF BAPIBUS20001_PARTNER_INS WITH HEADER LINE.
    DATA: IT_ORGANIZATION TYPE STANDARD TABLE OF BAPIBUS20001_ORGMAN_INS WITH HEADER LINE.
    **Values for Internal Table IT_HEADER**
    IT_HEADER-PROCESS_TYPE  =  'YWEB'.
    IT_HEADER-DESCRIPTION   =  'Web Order'.
    IT_HEADER-POSTING_DATE  =  'SY-DATUM'.
    IT_HEADER-CREATED_BY    =  'SY-USER'.
    APPEND IT_HEADER TO IT_HEADER.
    **Values for Internal Table IT_SALES**
    IT_SALES-PO_NUMBER_SOLD = '1'.
    APPEND IT_SALES TO IT_SALES.
    **Values for Internal Table IT_ITEM**
    IT_ITEM-NUMBER_INT  =  '20'.
    IT_ITEM-ORDERED_PROD  =  '50000180'.
    IT_ITEM-ITM_TYPE  =  'ZABC'.
    APPEND IT_ITEM TO IT_ITEM.
    **Values for Internal Table IT_PARTNER**
    IT_PARTNER-REF_PARTNER_NO  =  '100000620'.
    IT_PARTNER-REF_PARTNER_FCT = 'CRMH04'.
    APPEND IT_PARTNER TO IT_PARTNER.
    **Values for Internal Table IT_ORGANIZATION**
    IT_ORGANIZATION-SALES_ORG = 'O 50000100'.
    IT_ORGANIZATION-DIS_CHANNEL = '30'.
    IT_ORGANIZATION-DIVISION = '80'.
    APPEND IT_ORGANIZATION TO IT_ORGANIZATION.
    **Values for Internal Table IT_SCHEDULELINE**
    IT_SCHEDULELINE-QUANTITY  =  '2.268'.
    APPEND IT_SCHEDULELINE TO IT_SCHEDULELINE.
    **Call BAPI_BUSPROCESSND_CREATEMULTI for creating a sales 0rder******
    CALL FUNCTION 'BAPI_BUSPROCESSND_CREATEMULTI'
      TABLES
        HEADER                  =  IT_HEADER
        ITEM                    =  IT_ITEM
        SALES                   =  IT_SALES
        PARTNER                 =  IT_PARTNER
        ORGANISATION            =  IT_ORGANIZATION
        RETURN                  = IT_RETURN1
        SCHEDULELINE            = IT_SCHEDULELINE.
    ****************CALL COMMIT WORK**********
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
    EXPORTING
        WAIT          = 'X'
    IMPORTING
       RETURN        =  IT_RETURN2.
    ENDFUNCTION.
    Edited by: jessica sam on Dec 10, 2008 1:45 AM

    Hi am getting the sales order but the item data is not available in sales order. Also should I generate a new guide always for HEADER, ITEM, PARTNER, ORGANIZATION, SCHEDULELINE,u2026u2026for the tables that I use?
    I  mean do I need to create a new guide each time for all the tables that I use and finally pass only header guide to the  bapi 'BAPI_BUSPROCESSND_SAVE'.
    I donu2019t know why I am not getting the product data in the saved sales order please help me.
    this is my code
    ***TABLES
    DATA: IT_HEADER TYPE TABLE OF BAPIBUS20001_HEADER_INS.
    DATA: IT_INPUT_FIELDS_FILL TYPE TABLE OF BAPIBUS20001_INPUT_FIELDS.
    DATA: IT_ITEM TYPE TABLE OF BAPIBUS20001_ITEM.
    DATA: IT_OBJECTS_TO_SAVE TYPE STANDARD TABLE OF BAPIBUS20001_GUID_DIS WITH HEADER LINE.
    ***WORK AREA
    DATA: WA_INPUT_FIELDS TYPE BAPIBUS20001_INPUT_FIELDS.
    DATA: WA_HEADER TYPE BAPIBUS20001_HEADER_INS.
    DATA: WA_ITEM TYPE BAPIBUS20001_ITEM.
    DATA: IT_EV_GUID_32 TYPE GUID_32.
    DATA: IT_EV_GUID_32_1 TYPE GUID_32.
    *Create GUID
    CALL FUNCTION 'GUID_CREATE'
      IMPORTING
        EV_GUID_32       = IT_EV_GUID_32.
    * Fill the HEADER
    WA_HEADER-GUID                      =  IT_EV_GUID_32.
    WA_HEADER-PROCESS_TYPE              =  'ZWEB'.
    WA_HEADER-DESCRIPTION               =  'WEB ORDER'.
    WA_HEADER-CREATED_BY                =  'jiopidn'.
    APPEND WA_HEADER TO IT_HEADER.
    *For each FIELD of HEADER fill INPUT_FIELDS
    WA_INPUT_FIELDS-REF_GUID               =  IT_EV_GUID_32.
    WA_INPUT_FIELDS-REF_KIND               =  'A'.
    WA_INPUT_FIELDS-OBJECTNAME             =  'ORDERADM_H'.
    WA_INPUT_FIELDS-LOGICAL_KEY            =  '1'.
    WA_INPUT_FIELDS-CHANGEABLE             =  ' '.
    WA_INPUT_FIELDS-FIELDNAME              =  'PROCESS_TYPE'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME              =  'GUID'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME              =  'DESCRIPTION'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME              =  'CREATED_BY'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    *Create your own GUID
    CALL FUNCTION 'GUID_CREATE'
      IMPORTING
        EV_GUID_32       = IT_EV_GUID_32_1.
    * Fill the ITEM
    WA_ITEM-GUID              =  IT_EV_GUID_32_1.
    WA_ITEM-NUMBER_INT        =  '10'.
    WA_ITEM-ORDERED_PROD      =  '000000000070000000'.
    WA_ITEM-ITM_TYPE          =  'ZTAN'.
    WA_ITEM-MODE              =  'A'.
    APPEND WA_ITEM TO IT_ITEM.
    *For each FIELD of ITEM fill INPUT_FIELDS fields
    WA_INPUT_FIELDS-REF_GUID               =  IT_EV_GUID_32_1.
    WA_INPUT_FIELDS-REF_KIND               =  'A'.
    WA_INPUT_FIELDS-OBJECTNAME             =  'ORDERADM_I'.
    WA_INPUT_FIELDS-LOGICAL_KEY            =  '1'.
    WA_INPUT_FIELDS-CHANGEABLE             =  ' '.
    WA_INPUT_FIELDS-FIELDNAME              =  'GUID'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME              =  'NUMBER_INT'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME                 =  'ORDERED_PROD'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    WA_INPUT_FIELDS-FIELDNAME                 =  'ITM_TYPE'.
    APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS_FILL.
    REFRESH: CREATED_PROCESS.
    ***** CALL BAPI_BUSPROCESSND_CREATEMULTI
                   CALL FUNCTION 'BAPI_BUSPROCESSND_CREATEMULTI'
                     TABLES
                       HEADER                  = IT_HEADER
                       ITEM                    = IT_ITEM
                       INPUT_FIELDS            = IT_INPUT_FIELDS_FILL
                       CREATED_PROCESS         = CREATED_PROCESS
                       RETURN                  = RETURN.
    IT_OBJECTS_TO_SAVE-GUID = IT_EV_GUID_32.
    IT_OBJECTS_TO_SAVE-OBJECT_TYPE = 'BAPIBUS20001'.
    APPEND IT_OBJECTS_TO_SAVE TO IT_OBJECTS_TO_SAVE.
    **** CALL 'BAPI_BUSPROCESSND_SAVE
    CALL FUNCTION 'BAPI_BUSPROCESSND_SAVE'
      EXPORTING
        UPDATE_TASK_LOCAL       = true
        SAVE_FRAME_LOG          = true
      TABLES
        OBJECTS_TO_SAVE         = IT_OBJECTS_TO_SAVE
        SAVED_OBJECTS           = ITAB_SAVED_OBJECTS
        RETURN                  = itab_return.
    **** CALL BAPI_TRANSACTION_COMMIT
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
       EXPORTING
        WAIT = true
      IMPORTING
        RETURN = RETURN1.
    Edited by: jessica sam on Dec 12, 2008 3:50 AM

  • Create a sales order in CRM

    Hello Experts,
    How to create a sales order in CRM, I am using CRM 7.0.
    My reqirement is to create a sales order using ORDERS Idoc. I want to test the data before putting into orders.
    Thanks,
    Suma

    Hi,
    1.goto -->crmd_order Trx
    2.select order folder
    3. Enetr Bp for which u want to create Sales order
    4. Items/ Products information adn save it( prcing procedure shud be don before)
    u can enetr who  is bill to party, ship to party and payer . Other wise by using partner function u can determine it automatically.
    Thansk
    Leena

  • Creating ERP Sales Order from CRM 7.0

    Hi Experts,
    We are implementing the scenario-Creating ERP Sales Order from CRM. My doubt is:-
    Do we need to download the entire product data from ECC via middleware to implement this functionality?
    Is it possible that we manually create few products in CRM with same heirarchy and category and avoid middleware data download?
    My basic doubt is-what product information is passed to ECC from CRM when we create the ECC Sales Order? If only product id is passed, then we can avoid middleware data download for product from ECC to CRM.
    Can anyone please provide me some pointers on this? What should be the approach-download product data from ECC to CRM or manually create product data in CRM?
    Thanks and Regards,
    Rohit

    I´m trying to figure out the ERP Sales Order Scenario in CRM, i found the following link (sap.help) to customize the ERP sales Order in CRM, it´s a quickly guide supported by SALESPRO but in my case does not work, if somebody knows how to retrive the Order in IC i´ll appreciate.
    Here a quick Guide -->
    Prerequisites
    You can directly create and change an ERP sales transaction in SAP CRM once you have carried out the following:
    You are using SAP ERP for your Quotation and Order Management.
    You are using SAP CRM.
    You have assigned the relevant ERP sales transactions to a profile.
    You do this in Customizing for CRM, by choosing  Customer Relationship Management  Transactions  Settings for Sales Transactions  Define Profile for ERP Sales Transactions .
    You have defined an RFC destination.
    You do this in Customizing for CRM, by choosing  Customer Relationship Management  CRM Middleware and Related Components  Communication Setup  Define RFC Destinations .
    You have defined a business role by copying the standard business role SALESPRO to your own. You make this setting in Customizing for CRM, by choosing  Customer Relationship Management  Business Roles  Define Business Role .
    You have defined cross-system copy control of transaction types.
    You do this in Customizing for CRM, by choosing Transactions  Settings for ERP Transactions Maintained via CRM  Cross-System Copy Control for Opportunities and ERP Transactions
    I want to see the screens or video regarding with this scenario.
    Regards,
    Memo

  • BAPI or Function Module for Creating a service order

    Dear developers,
    i want to create a service order in CRM from a web-based BSP application. Which function modules or bapi's can be used for this?
    Has anybody still did something like this?
    Regards,
    Jens

    Hi,
    U can use CRMXIF_ORDER_SAVE FM to create the service Order.
    Regards,
    Ajay Gupta
    Reward points only if it helps

  • Function module unit costing for sales order

    hello all!
    is there a way to create a unit costing for sales order using a function module? i found module K_UNITCOSTING_CREATE - has anyone used that before?
    best regards,
    matthias

    hello!
    i have no master data as basis for unit costing. instead i would like to use information from sales order conditions in unit costing.
    best regards,
    matthias

  • Function Module to retrieve ALL Sales Orders in SAP based from a UserStatus

    Can someone know a function module to give me a set of Sales Documents
    of a specifc type and a specific System Status.
    For example:
    CALL FUNCTION '?????'
        EXPORTING
            txt04    =    'INAC'    "specfic status text not the 'E0001' JEST-STAT value.
            inact    =    ' '           "for ACTIVE statuses only.
            auart    =    'ZMAG'   "specifc document type
        TABLES
            t_vbeln    = i_vbeln   "result is a list of sales orders based from criteria above
    I am thinking it is not as simple as the above. But 2 - 3 FMs will do.
    Note: I am not given a choice to SELECT from DB tables VBAK and JEST. They want pure FM calls only. Please reply ASAP.

    Hi,
    i dont think there is any FM as such ..
    but in VA05,,, u will get the all the information
    reward points if it is useful...
    thanks,
    Manjunath MS

  • Function module for status of sales order

    My reuirement is as follows,
    "Using the Objnr field(vbak), read the status of the sales order using the Function Module."
    So,please send me any existing Function module name to get status of sales order using Objnr field in vbak.
    Its so urgent!
    Thanks & Regards,
    Santu.

    Hi
    Check the given requirementcorrectly once again
    Because for sales order we don't use the field OBJNR (object no) to find the ststau
    Generally we use this field OBJNR for finding the Status of the PP,PM related Orders.We will take the OBJNR from AUFK table and Pass it to the JEST table
    and will read the STATUS of the Order
    So for sales order we don't have that field OBJNR
    if needed use the BAPI BAPI_SALESORDER_GETSTATUS to find the sales Order status
    Or use the table VBUK to find the Sales order status.
    Hope you understood the concept.
    Reward points if useful
    Regards
    Anji

  • Function module to create a CS order from external system

    Hello,
    i´m setting up a prototype for customers service (CS).
    My goal is to create the CS order automatically from a external system where i have all the required data.
    Is there a function module or something in SAP ERP which i can use to create the CS order in background?
    Thank you.
    Best regards
    Manfred

    Hello Amit,
    the requirement is the following:
    we have a SAP CRM System where we create Servicetickets.
    This tickets contain the following data which are also from interest for the CS Order:
    - Customer data
    - Equipment
    - Shorttext
    The goal is to create as follow up for the SAP CRM Serviceticket not a SAP CRM Serviceorder but a CS Order in ERP.
    All data which can be used from the ticket should be used - all further data should the user add to the CS Order manually.
    Thank you for your ideas.
    Best regards
    Manfred

  • IDoc Issues when creating a Sales Order in CRM System

    Hi All,
    We have a BSP application in place which allows the customers to create orders online. This BSP application is linked to R/3. The R/3 BSP application remotely calls a custom code in the CRM system which creates an IDOC for the CRM Order and the IDOC is processed and a CRM Order gets created. In the BSP page we have given a provision to the client to enter a Requested Delivery Date which is mapped to the delivery date in CRM system.
    Now comes the problem. When the customer creates an order, he enters the requested delivery date but the order which is getting created is not being populated with the date entered in the screen but with the current date.
    But when I try and reprocess the IDOC through WE19 without changing any IDOC data records the order gets created with the date which was entered in the webpage.
    Any pointers regarding what is happening?
    Regards,
    Karthik

    Hi Karthik,
    Just check on the field date, this request delivery date in CRM.
    Does it come from date profile? If it does, then try to remove the
    date rule or any default value for this date.
    Alternatively, I am afraid you have to separately save the date
    after first IDOC document creation is done. Seems that the default
    value taken place (and replaced) after the document has created.
    Hope this helps.
    Gun.

  • BAPI/FM in ECC to create a sales order with variant configurable material

    Hi all,
    I need to create a function module that creates a sales order in ECC with a variant configurable material.
    can some one tell me if there is a in built function module or BAPI that i can make use of to create a sales order with variant configurable material in ECC.
    Regards,
    Jessica Sam

    Thanks MxG,
    I dont know how to use this BAPI. .Can you suggest me a sample code.
    My reqmnt is, i have
    Sold to party, ship to party, bill to party , VC config material and all char values that should be populated while creating a sales order.
    please help me with what values should i populate in i/p paramters and and how to use this BAPI with some sample code if posible.
    Regards,
    Jessica.

  • Need a function module to create production order with reference

    Hi
    I need a function module to create a production order with reference to an existing order. There is no BAPI available for SAP 4.7 release. I found that the function module CO_ZF_PRODUCTIONORDER_CREATE does not create with reference to an existing order.
    Any help will be rewarded.
    Pavan

    Dear Pavan,
    Unfortunately there is no FM for this..
    Cheers
    Nitesh

  • BAPI/ FM in CRM to create a sales order with variant configurble material

    Hi All,
    I need to create a sales order using variant configurable material in CRM not manually through GUI. I need to develop a function module that will create sales order using variant configurable material in CRM .
    Can some one tell me if there is an in-built BAPI/Function Module availabe in CRM to create sales order using variant configurable material in CRM .
    When i researched i found that there is a BAPI 
    BAPI_BUSPROCESSND_CREATEMULTI which can create a sales order in CRM.
    I dont know if this can create a sales order with varinat configurable material in CRM
    can some one guide be how i can build a function module in CRM which generates a sales order with variant configurable material.
    Regards,
    Jessica Sam

    Jessica
    I am not a CRM expert and am still learning. But you can try the BAPI CRMXIF_ORDER_SAVE and see if that helps.
    Good Luck
    Ram

Maybe you are looking for

  • Manual BOM selection at the time of order creation

    Dear Experts, Could you help me to understand if there is any provision to select BOM by user at the time of order creation without the help of production version.Is there any configuration required to make BOM selected manually. Regards, Krishna Moh

  • Master and version stack?

    I have a master and its version (both have the same file id/name) - i wish to stack these but am unable to - when i try i get a response stating that they are from different projects and will not let me - thanks in advance for any advice or solution

  • The play option is not available on some iTunes extra titles on Apple TV

    With the latest update iTunes extra has been added to Apple TV, which is pretty cool.  BUT some titles do not have the "play" option once you are in the iTunes extra menu.  All the features are there, but the play option is not.  This is particularly

  • Having problem with with Apple tv?

    I am having problem with wifi connection? can someone please help me out with this problem

  • ITunes using a lot of CPU

    I had been using iTunes for a few hours on my Powerbook and noticed it was using a lot of cpu (about 30-40%) for just playing a song. I quit the application, and then noticed the following message in my console at around that time: Jan 19 17:23:16 My