Issue with creation of sales order in CRM system

Hi Experts,
Here are the details of the process we followed
1.     We found a Function Module u201CBAPI_BUSPROCESSND_CREATEMULTIu201D which is used to create a sales order in CRM.
2.     We have set a Break point in the FM u201CCRM_ORDER_MAINTAINu201D and tried to create a sales order using the transaction u201CCRMD_ORDERu201D. For this the parameters we have given are
a.     sold-to-party
b.     ship-to-party
c.     quantity
d.     product
And after this we have saved the order and the order is saved and in the debug mode we have the parameters in u201CCRM_ORDER_MAINTAINu201D and we found all these     parameters in the FM.
3.     After this we have given all the parameters mentioned above in the FM u201CBAPI_BUSPROCESSND_CREATEMULTIu201D and still the order is not created, gave an error message saying that CRM_ORDER: Incorrect values in the interface object.
4.     We checked the CRM_ORDER badiu2019s interface and it is having only header guid to be given. We gave this header guid also in the FM u201CBAPI_BUSPROCESSND_CREATEMULTIu201D and then it gave a different error saying that : Document cannot be saved.
5.     Finally we are not able to know the parameters to be passed to the FM to create an order.
Any inputs will be highly appreciated.
Thanks a lot in advance.
Lakshman.

Hi Easwar,
Now i am able to create a sales order by passing the parameters to "BAPI_BUSPROCESSND_CREATEMULTI" and the parameters i am passing are Process_type in the ORDERADM_H, parner_fct (partner function), partner_no , Quantity and prod_ordered (product name) but after creation of sales order using my report program and if i see the sales order uisng transaction crmd_order (using transaction ID) or crmd_orderadm_h(using headerguid) or crm_order_index, only the PROCESS_TYPE is updated but the remaining parameters which i passed like QUANTITY,PRODUCT NAME,PARTNER NUMBER are not present in the sales order. I am providing the code which i have written for creation of the sales order. Can you please look into it and tell me where i might have went wrong??
*& Report  ZCREATEORDER_TEST
REPORT  ZCREATEORDER_TEST.
DATA : LV_HEADER_GUID  TYPE  GUID_32,
WA_HEADER            TYPE         BAPIBUS20001_HEADER_INS,
ITAB_HEADER          TYPE STANDARD TABLE OF BAPIBUS20001_HEADER_INS,
ITAB_CREATED_PROCESS TYPE STANDARD TABLE OF BAPIBUS20001_HEADER_INS,
ITAB_OBJECTS_TO_SAVE TYPE STANDARD TABLE OF BAPIBUS20001_GUID_DIS,
ITAB_PARTNER        TYPE STANDARD TABLE OF BAPIBUS20001_PARTNER_INS,
lt_product_i TYPE STANDARD TABLE OF BAPIBUS20001_ITEM,
wa_product_i  type BAPIBUS20001_ITEM,
lt_schedlin_i type standard table of BAPIBUS20001_SCHEDLIN,
wa_schedlin_i type BAPIBUS20001_SCHEDLIN,
ITAB_INPUT_FIELDS TYPE TABLE OF bapibus20001_input_fields,
ls_inputfields TYPE bapibus20001_input_fields,
WA_PARTNER          TYPE BAPIBUS20001_PARTNER_INS,
ITAB_RETURN          TYPE STANDARD TABLE OF BAPIRET2,
WA_OBJECTS_TO_SAVE  LIKE LINE OF ITAB_OBJECTS_TO_SAVE,
           "To store the Objects to be saved.
WA_CREATED_PROCESS  LIKE LINE OF ITAB_CREATED_PROCESS,
ITAB_SAVED_OBJECTS   TYPE STANDARD TABLE OF BAPIBUS20001_OBJECT_ID,
WA_SAVED_OBJECTS    LIKE LINE OF ITAB_SAVED_OBJECTS,
GC_X type c.
gc_x = 'x'.
CALL FUNCTION 'GUID_CREATE'
  IMPORTING
    ev_guid_32 = lv_header_guid.
CLEAR : WA_HEADER.
Passing the respective values from the Header table to internal table.
WA_HEADER-GUID          =  LV_HEADER_GUID.
WA_HEADER-PROCESS_TYPE  =  'ZTA'.
APPEND WA_HEADER TO ITAB_HEADER.
*Appending the values to the ITAB_HEADER.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'ORDERADM_H'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'PROCESS_TYPE'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
*ls_inputfields-ref_handle = '0000000000'.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-objectname = 'ORDERADM_H'.
  ls_inputfields-fieldname = 'MODE'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'ORDERADM_H'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'GUID'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
CHANGES MADE
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'SCHEDLIN'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'LOGICAL_KEY'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
  ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'SCHEDLIN'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'MODE'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
  ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'SCHEDLIN_I'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'GUID'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
   ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'SCHEDLIN_I'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'QUANTITY'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
   ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'SCHEDLIN_I'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'MODE'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
CHANGES MADE
WA_PARTNER-REF_GUID = LV_HEADER_GUID.
WA_PARTNER-REF_KIND = 'A'.
giving the partner function and partner no 000000038 for slod to party
WA_PARTNER-PARTNER_FCT = '00000038'.
WA_PARTNER-PARTNER_NO = '10017'.
APPEND WA_PARTNER TO ITAB_PARTNER.
*"ADDING VALUES for the product
  wa_product_i-header        = lv_header_guid.
  wa_product_i-handle        = '0000000001'.
  wa_product_i-ordered_prod  = '12000014'.
  wa_product_i-mode          = 'A'.
  APPEND wa_product_i TO lt_product_i.
*"ADDING VALUES for quantity
  wa_schedlin_i-quantity   = 30.
  wa_schedlin_i-handle = 1.
  APPEND wa_schedlin_i TO lt_schedlin_i.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'PARTNER'.
*ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'REF_GUID'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'PARTNER'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'PARTNER_FCT'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
ls_inputfields-ref_guid =  LV_HEADER_GUID.
ls_inputfields-REF_KIND = 'A'.
ls_inputfields-objectname = 'PARTNER'.
ls_inputfields-logical_key = ' '.
ls_inputfields-fieldname = 'PARTNER_NO'.
APPEND ls_inputfields TO ITAB_INPUT_FIELDS.
CALL FUNCTION 'BAPI_BUSPROCESSND_CREATEMULTI'
  TABLES
    HEADER          = ITAB_HEADER
    ITEM            = lt_product_i
    RETURN          = ITAB_RETURN
    PARTNER         = ITAB_PARTNER
    INPUT_FIELDS    = ITAB_INPUT_FIELDS
    CREATED_PROCESS = itab_created_process
    SCHEDULELINE    = lt_schedlin_i.
READ TABLE ITAB_CREATED_PROCESS INTO WA_CREATED_PROCESS WITH KEY GUID = LV_HEADER_GUID BINARY SEARCH.
WA_OBJECTS_TO_SAVE-GUID = WA_CREATED_PROCESS-GUID.
Appending the Guid of the contract to be saved to the internal table
APPEND WA_OBJECTS_TO_SAVE TO ITAB_OBJECTS_TO_SAVE.
CALL FUNCTION 'BAPI_BUSPROCESSND_SAVE'
  EXPORTING
    update_task_local = space
    save_frame_log    = GC_X
  TABLES
    objects_to_save   = itab_objects_to_save
    saved_objects     = itab_saved_objects
    return            = itab_return.
Calling the Standard BAPI to Commit the transcation.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
I have debugged the above code, all the values are passing are passing to the FM "'BAPI_BUSPROCESSND_CREATEMULTI'" and these passed to the CRM_ORDER_MAINTAIN and then to CRM_ORDER_READ which are called inside the "'BAPI_BUSPROCESSND_CREATEMULTI'". Finally the sales order is created but not able to see all the values that i am passing except PROCESS_TYPE.
Thanks a lot in Advance,
Lakshman.

Similar Messages

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

  • Creation of sales order in CRM and replicating it to Multiple ECC system.

    We have a requirement for creation of sales order in CRM and replicating it to Multiple ECC system.
    We have checked the following standard Adapter objects in transaction R3AC1.
    BUS_TRANS_MSG
    The initial flow contexts does not support target site type as R/3(SMOF_ ERPSITE). So we are not able to replicate the sales order from CRM
    to ECC.
        2. SALESDOCUMENT
    Here the initial flow contexts does not support flow from CRM -> R/3 as we don’t see the target site as CRM.
    Please let us know if the standard sap middleware objects don’t support the sales order flow from CRM to multiple ECC or is there any
    other adapter object we need to use for this.

    Hey Vijay Duvvada,
    I hope you are already referred below sap note  and which explains scope & how to do   -
    1084315 - Consulting: Information about the multiple backend scenario
    1763516 - How-to: Basic Setup of MEP
    As explained by Rohit Sharma data should be start flowing to multiple sites.
    please let me know if it does help.
    Regards,
    Arjun

  • Factory Calendar issue in creation of Sales Order/ Delivery Order

    Hi all,
    There is one issue. Our user is not able to create Sales Order/ delivery order as he is getting the below error message u201CDate 2010-12-27 lies after the end of Factory calendar F1u201D. But when I checked the plant in customization, the Factory calendar assigned is u201CKRu201D and not u201CF1u201D. So I donu2019t understand why this error message is appearing. But when I checked Factory calendar u201CF1u201D, it was valid only up to 2010 and there are special rules also set. Only few days in the year are working days. Factory Calendar u201CF1u201D description says u201CKOR customers billed on the 25th of every monthu201D
    Please advice.
    Regards,
    Brijesh

    Dear
    If F1 is the correct calander , then goto OP03-Calander Maintenece -select the Holoiday Caleneder  and extende the Valaidity till 2020 and also Select the Factory Calander  do the same till 2020 .Now Goback to main screen of OP03-Plant asisngement -re-assing the same F1 calaneder .
    Secondly check the factory calender of the plant in OX10.Then in SPRO > enterprise structure >Definition > logistic execution>define shipping point .Select you shipping point and assgin the proper factory calender
    .Goto OVX5 , choose your sales organization, click on details, Detailed information tab - Sales Org Calendar (maintain your factory calendar here not Sale Org Calander )
    .Check in VOV8, use the "Propose delivery date" and "Lead time in Days" options to default today's date as the requested delivery date.
    Refer : Public holiday dates issue
    Regards
    JH

  • Problem with creation of Sales Order with reference to Contract

    Hi,
    I have a problem when creating Sales order with reference to Contract , shipping condition was not copied. Is there any existing copy routines suitable to accomodate this?
    Thanks!

    your functional team can help you in finding one.

  • Issue with the Internal sales Order

    Hi
    We are trying to populate the customer information in the internal sales orders.
    We are updating the Customer_ID, Customer_Number, Customer_name information on the iface header table...and we are submitting the Order Import concurrent program...even though customer information is not populated....
    Could any one sggest on this....
    Regards,
    Krishna

    Why are you updating the interface record?
    You create and approve an internal requisition (IR)
    You run the "Create Internal Orders" concurrent program.
    This program reads the IR details and populates the Order Interface table.
    Then you run the "Import Orders" concurrent request.
    That program processes the interface record and creates the Internal Sales Order (ISO). All the information Oracle needs to create the ISO (such as customer name, number etc.) is already in the interface table or is derived by the Import Orders program. You should NOT update the information.
    Hope this helps,
    Sandeep Gandhi

  • BAPI to post a Goods issue with relation to Sales Order?

    Hi Everyone,
    After creating a delivery order, I need a BAPI to automatically post a goods issue for this DO.
    I tried using BAPI_GOODSMVT_CREATE but it returns the message 'Goods Movement not possible with mvmt type 601'.
    Any advice?
    Best Regards,
    Junwen

    Hi John,
    My data are as follows:
    GOODSMVT HEADER:
    PSTNG_DATE: 30.09.2004
    DOC_DATE: 30.09.2004
    REF_DOC_NO: had tried 1014000359 or empty
    GOODSMVT_CODE: 03
    GOODSMVT_ITEM:
    MATERIAL: HP0121002
    PLAN: 1010
    STGE: 10FG
    BATCH: BATCH1
    MOV: 601
    CUSTOMER: 180017
    ENTRY_QNT: 1
    ENT_UOM: PC
    ENT_UOM_ISO: PC
    DELIV_NUMB: 1014000359
    DELIV_ITEM: 000001
    From your feedback, it is possible to use the BAPI to create a goods issue for movement type 601?
    Best Regards,
    Junwen

  • Mass sales orders from CRM to ECC

    Hi,
    We have a requirement to mass upload sales orders from CRM system ECC system. I could not able to find any option to push sales orders in bulk from CRM to ECC.
    Could you please let me know if you know any kind of solution for this kind of scenario.
    Thanks in advance!
    Regards,
    Kumar B.

    Hi Maggie,
    Thanks a lot for your response. But I could not able find CRMD_MASS_UPDATE in CRM system as well as in ECC.
    Could you please let me know how to try this other please let me know the program or tcode.
    Regards,
    Kumar B

  • Number Range issues with sales orders in CRM and R/3

    Hi,
    We are currently using CRM4.0. I have sales orders created in R/3 and they are replicated into CRM.  These sales orders can only be created in R/3.  I have given them a number range of 0000000001 and 0005899999, however we have reached the number 0005899999 so we increased the internal number range for the sales orders in R/3 to 0009499999, however we forgot to update the number range for the corresponding sales transaction type in CRM so we are getting the following error in CRM:
    +Enter a business transaction number between 0000000001 and 0005899999
    Message no. CRM_ORDERADM_H532
    Diagnosis
    You have attempted to enter a transaction number which is not allowed for the transaction type.
    Procedure
    Enter a number between  &1 and &2. Make sure that you issue a number which has not already been issued.+
    We have now updated the CRM number range to match that in R/3 to 0000000001 and 0009499999 but we are still getting the error above on our existing sales orders in CRM.  I thought that increasing this number range it will remove the error but when I open sales orders in CRM the error is still there. 
    Is there any way to remove this error message?  Any tips or advice would be much appreciated.
    Please note we've already checked the post Re: Number Range Problem and note 427289.
    Kind Regards
    JoJo

    Hi Sirisha,
    The solution depends on the exact issue you are facing.
    The CRM Sales Order is created OK, but you only see the error when you open the Sales Order?
    If this is the case, then you can follow the steps below:
    1. Find the Message ID and Message No for the error message
    2. Use Program - CRM_MESSAGES_DELETE to delete error messages from the error producing Sales Orders.
    Let me know if this is not the issue you are facing.
    Regards,
    Nelson

  • Re: Purchase REquisition creation with ref to SAles Order

    Hi All,
    I need help on an issue.
    I have sales order creation and when saving Purchase REq is created at the back end. But for the sales order for item category n schedule line category combination does not allow creation of Pur Req. n pur req no. is not dislayed in Sales order.
    But I have Pur Rq created with ref to sales order.
    How is it possible.
    In Pur req  I checked the creation indiacotr, it is with ref to sales order.not manually.
    Can you please help it out..
    Regards,
    Smitha

    Hi,
    Purchase Requisition creation from Sales Order is dependent on the configuration of Schedule line category not Item category. Check configuration of Schedule line category in VOV6.
    Also to see the PR No in Sales Order, double click on the Sales line item and click on the "Purchase Requisition" button under "Schedule Lines" Tab.

  • HOW TO CONTROL ON CREATION OF SALES ORDER WITH REFERENCE TO EARLIER SO?

    Dear All,
    I want to contol on creation of Sales order with reference to earlier SO?  While creation of sales order our enduser are creating sales order with reference to earlier month SO which I want to restrict. Recently I made changes in sales order like payment terms is grayed, system will atomatically pick pay terms from customer master.Now I am getting correct data also but enduser is using old SO no while creating new SO and old payment data is reflecting in fbl5n.
    I want to restrict enduser while creating new SO with ref. to old SO. Only for returns they should be able to use Billing refrence. Pl. suggest how to control the with reference to ealier SO.
    Nikhil

    Nikhil Deshpande,
          If you dont want allow create a sales order in referent to other one, just delete the copy control between these sales order type, so when the user tries to create a SO in reference to other one a message is displayed that is not possible.
    Thanks,
    Mariano.

  • 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

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

  • Creation of production order with reference to sales order

    dear all guru's,
                       i m having a requirement of creating production order with ref to sales order but without changing my old strategy of make to stock.
    regards
    ujwal

    Hi,
    For the purpose of creation of production order with reference to sales order while maintaing MTS strategy you need to maintain Make to stock strategy 40 in strategy group in MRP-3 View of Material Master.
    This is the only Make-to-Stock Strategy which enables you create Production Order against both Sales order as well as Demand / PIR.
    So if your strategy group is already 40 then you need not change it.
    However if you are using any other Make-to - Stock strategy like 10, 11 etc. then it is not possible to create Production Order against Sales Order since they dont consider Sales Order in planning.So you need to change them and set strategy group as 40.
    Hope this helps.
    Revert if you have any doubt.
    Regards,
    Tejas
    Edited by: Tejas  Pujara on Sep 27, 2008 8:50 AM

  • BAPI for creation of Production Order with Ref to sales order

    Hi all,
    we are using BAPI_PRODORD_CREATE  for creating Production Order with ref to sales order.
    As per the Business Scenario, we are not creating any masters like BOM and Routing, instead
    we are creating Routing directly into the Production Order under operation overview screen.
    during creation of routing system is generating a default operation.
    the following is the error results after running the Bapi.
    "No routing selected"
    Best Regards.
    GTNRNR.

    Hi GTNRNR,
    with out creation of BOM you created routing and in routing for the operations which components did you allocated so that can be used to manufacture the final product. Can you be please specific?
    Regards,
    Madhu.G

Maybe you are looking for

  • My macbook pro keeps freezing and shutting off when I am browsing the web on Safari.  How can I figure out what is causing this issue?

    For the past few weeks my computer will slow down when I have been on Safari for awhile, then freeze, and then just go black.  I have to press the power button and then it goes to a black screen with the apple logo and a loading bar underneath when i

  • RCA TO HP PAVILLION 23 ALL IN ONE

    I am trying to connect an Ion Profile LP (Vinyl-Archiving Turntable to an HP 23 All in One.  The turn table has RCA cords. I do not see any audio input cables much less RCA input.  What can I use to plug the device in and where can I plug it into. Th

  • Play movies on my mac onto tv

    Hi, i know this has been asked loads, but i just wanna make sure this will work before i spend the money on it. i've got a dual 1.8 g5 with an ati 9600. i want to watch movies from my mac on a tv in another room. i was going to buy a adc to vga adapt

  • Reverse Calculation in Pricing

    Dear All, I have following scenario to be configured in sd pricing procedure. MRP  :                 145 - (this will be entered bu user or condition record) Trade Disc.(20% on MRP):   29     Promo disc (3% on MRP) :    4.35 Price after  Disc. : 111.

  • Outlook 2013 Search Problem.

    Hello friends, My outlook 2013 search box gives no result. I cant find anything after I move pst file from D:\ to D:\outlook\ folder.  Actually there are many topics about this issue in technet and I check the related topics, so I found a little solu