Performance of BAPI's to create Leads and Activities in CRM

Hi,
I'm using the BAPI's BAPI_LEAD_CREATEMULTI and BAPI_ACTIVITYCRM_CREATEMULTI to create Leads and Activities.
The scenario is:
1) The input file has 3 types of records coming in
(a) Leads only
(b) Activities only (Prospect Lead activities)
(c) LEad + Activity (rescheduled activities)
2) Depending on the type of record, I'm required to create the relevant order and if required link the lead and activity (scenario - C)(using the FM CRM_DOC_FLOW_MAINTAIN_OW).
3) In addition to this, I'm also required to link campaign elements to both Leads and Activities (done within the BAPI's BAPI_LEAD_CREATEMULTI and BAPI_ACTIVITYCRM_CREATEMULTI in the doc_flow structure).
ISSUE:
The issue that I am facing is that it is taking a lot of time to create these. I'm basically running a custom conversion program for LEads and Activities. The rate is almost 6-8 secs for each record, and we have about 500,000 records to be converted.
Also, I'm having to use the following function modules after the creation of Leads and Activities:
1) CRM_MA_ACT_SAVE - to set the status of the activity to OPEN or IN PROGRESS. This is being done after the creation of an activity because the BAPI BAPI_ACTIVITYCRM_CREATEMULTI seems to always default the status to OPEN.
2) CRM_ORDER_CHANGE_STATUS - to set the status of the LEad to OPEN or IN PROGRESS. This is being done after the creation of an activity because the BAPI BAPI_LEAD_CREATEMULTI seems to always default the status to OPEN.
3) BAPI_LEAD_ATT_CHANGE - to set the STATUS SINCE field for a Lead. This is being done because I'm unable to set the STATUS_SINCE field using the BAPI BAPI_LEAD_CREATEMULTI.
The logic being used within the code is to process a batch of records (500/1000 records - value is an input selection parameter) from the input file in one go, and then commit all of them after their creation. After this, the next batch of records is again processed and committed.
We've also tried to create LEads and Activities record by record and not in batches... but the performance still remains the same.
I'm not sure what is slowing down the process. If whether it is all the commits, or if it is the additional use of the FM's to change the 'status' and 'Stauts-since' values after having committed the leads and activities.
When we look at the LEads and Activities that are created, everything looks fine. It is only that the performance is really slow.
Thanks for all your patience and suggestions,
- Akarsh

In order to improve the performance you could use several processes. Just start you conversion-program with several variants at the same time.
Last time I converted 80.000 contracts it took me 6 hours with 5 processes.
Hopes this helps.

Similar Messages

  • Performance of BAPI's to create Leads and Activities

    Hi,
    I'm using the BAPI's BAPI_LEAD_CREATEMULTI and BAPI_ACTIVITYCRM_CREATEMULTI to create Leads and Activities.
    The scenario is:
    1) The input file has 3 types of records coming in
       (a) Leads only
       (b) Activities only (Prospect Lead activities)
       (c) LEad + Activity (rescheduled activities)
    2) Depending on the type of record, I'm required to create the relevant order and if required link the lead and activity (scenario - C)(using the FM CRM_DOC_FLOW_MAINTAIN_OW).
    3) In addition to this, I'm also required to link campaign elements to both Leads and Activities (done within the BAPI's BAPI_LEAD_CREATEMULTI and BAPI_ACTIVITYCRM_CREATEMULTI in the doc_flow structure).
    ISSUE:
    The issue that I am facing is that it is taking a lot of time to create these. I'm basically running a custom conversion program for LEads and Activities. The rate is almost 6-8 secs for each record, and we have about 500,000 records to be converted.
    Also, I'm having to use the following function modules after the creation of Leads and Activities:
    1) CRM_MA_ACT_SAVE - to set the status of the activity to OPEN or IN PROGRESS. This is being done after the creation of an activity because the BAPI BAPI_ACTIVITYCRM_CREATEMULTI seems to always default the status to OPEN.
    2) CRM_ORDER_CHANGE_STATUS - to set the status of the LEad to OPEN or IN PROGRESS. This is being done after the creation of an activity because the BAPI BAPI_LEAD_CREATEMULTI seems to always default the status to OPEN.
    3) BAPI_LEAD_ATT_CHANGE - to set the STATUS SINCE field for a Lead. This is being done because I'm unable to set the STATUS_SINCE field using the BAPI BAPI_LEAD_CREATEMULTI.
    The logic being used within the code is to process a batch of records (500/1000 records - value is an input selection parameter) from the input file in one go, and then commit all of them after their creation. After this, the next batch of records is again processed and committed.
    We've also tried to create LEads and Activities record by record and not in batches... but the performance still remains the same.
    I'm not sure what is slowing down the process. If whether it is all the commits, or if it is the additional use of the FM's to change the 'status' and 'Stauts-since' values after having committed the leads and activities.
    When we look at the LEads and Activities that are created, everything looks fine. It is only that the performance is really slow.
    Thanks for all your patience and suggestions,
    - Akarsh

    In order to improve the performance you could use several processes. Just start you conversion-program with several variants at the same time.
    Last time I converted 80.000 contracts it took me 6 hours with 5 processes.
    Hopes this helps.

  • BAPI needed to create invoice and creditmemo

    Hi all,
          Is there any BAPI available to create invoice and creditmemo when material no is not given.
          My requirement is to create credit memo and  invoice through FB75 or FB70 transaction. I am able to achieve the same through BDC. Is there any BAPI availabe for the same to create credit memo or invoice to avoid BDC.
          Input given to the program is a excel file in which i have the following fields
          Transaction -- which separates credit memo or
                         invoice
          Company code, purchase order number, GL account
          number, cost center, profit center, amount etc...
    Please let me know some pointers.
    Regards,
    Karthik.

    GN_INVOICE_CREATE or BAPI_BILLINGDOC_CREATEMULTIPLE
    Please find the sample code for Billing document BAPI.
    t_billing-salesorg = vbak-vkorg.
    t_billing-DISTR_CHAN = vbak-vtweg.
    t_billing-DIVISION = vbak-spart.
    t_billing-DOC_TYPE = vbak-auart.
    t_billing-ref_doc = vbak-vbeln.
    t_billing-ref_item = vbap-posnr.
    t_billing-doc_number = vbak-vbeln.
    t_billing-ITM_NUMBER = vbap-posnr.
    t_billing-ordbilltyp = 'BILLING TYPE'.
    t_billing-price_date = sy-datum.
    t_billing-ref_doc_ca = vbak-vbtyp.
    t_billing-sold_to = vbak-kunnr.
    t_billing-material = vbap-matnr.
    t_billing-plant = vbap-werks.
    APPEND t_billing.
    CALL FUNCTION 'BAPI_BILLINGDOC_CREATEMULTIPLE'
    TABLES
    billingdatain = t_billing
    return = t_return
    success = t_success.
    commit work.
    Regards

  • Create complaints and returns in crm 2007

    Hi buddies,
    my doubt is  how we ll maintain complaints and returns in crm 2007
    thanks in advance.
    Regards,
    manav

    Hi buddies,
    i want to map complaints and returns on the web client for the this business process .
    if customer purchases a product snd if not satisfied with the product,he calls to the call center.Call Center Executive creates a complaint and assign it to a service executive. he goes and finds that the it is a quality defect.he forwards this problem to the Quality Management department.If they finds that it is a quality defect then tells to return the product against which a new product has to be issues.
    we have make this in a close lope between R/3 & CRM.
    Now my doubts are--
         1-How will we maintain the stock update?
         2-How will we maintain that the subsittute product delivery should be free of cost
            as customer has already paid for the goods?
    If possible then tell me the customization steps as well
    Thanks in advance.
    help will be rewarded for sure.
    my mail id is [email protected]
    Regards,
    Manav
    Edited by: Rronit Manav on Mar 10, 2008 2:26 PM

  • Explination of integrating Groupware and Activities in CRM

    Hey
    I am about to implement Groupware to my CRM 4.0 system, but I have some question first that doesnt come so clear out of the installation / how-to manuals.
    How is the scenario when creating a new Activity in CRM to the Calendar in Outlook? Does the calander gets updated as well? and reverse from Calendar to Activity?
    And if a Business Partner receives a mail.. or sends a mail. How is this integrated to the sap object? Does it gets attached as an attatchments ? Or is it another way to see all the mails on a Business Partner?
    If someone have tried this, please write me back!
    Best Regards
    Kristoffer Engh

    Thanks!
    After reading thoose two notes, I see that
    1) E-Mail integration is not supported by this solution
    2) Activities can be synchronized both ways
    I was hoping Groupware could support e-mail, by making a link of a Business Partner and to all the mails that has been received and accepted :/
    Any suggestion of how to make that integration?
    Best Regards
    Kristoffer Engh

  • Are there any standard BAPIs to change/create/delete quote data on CRM side

    Hello Friends
    I am getting prepared for the XI integration of the data (quotes related) from our application to CRM. Are there any specific BAPIs that you guys are using to create, modify, delete a quote in CRM.
    Any feedback or advice will be highly appreciated.
    Tks
    Ram

    Hi Ram,
    Check these BAPIs:
    BAPI_QUOTATION_CREATEFROMDATA2
    BAPI_CONTRACT_CREATEFROMDATA
    Hope this helps you.
    Regards,
    Chandra Sekhar

  • How to achieve Number Ranges in third party CRM tool and in SAP CRM

    Hello Guru's,
    My business requirement is I have to create LEAD from third party CRM tool to SAP CRM and vice versa i want to maintain number ranges for created lead in both side.
    How can I achieve this please provide me your valuable suggestions and document.
    Thank's In Advance

    Hi,
    In SAP IMG screen maintain the external number range in CRM  through the below path.
    CRM-Transactions-basic setting-Define Number range.
    Also maintain the same number range for lead in the third party crm.
    Regards,
    Ashish

  • Is there any BAPI/FM to create a trasnport request and add objects into it?

    Hi Experts,
    Could anyone please assist me in finding a BAPI/FM to create a transport request and add objects to it.
    I could find a BAPI BAPI_REQUEST_CREATE, it creates trasnport request but doesn't have option to add objects.
    Thanks
    Yogesh Gupta

    Create a custom Function Module , in that write a BDC to create a transport request and add objects to it.
    Thats it.

  • How to create a Sales Lead and Sales Lead Contact using Web Services

    Hi,
    I am working on integration of sales lead with third party application. I want to create a sales lead and sales lead contact using web services.
    The question is What WSDLs should I use to create Sales Lead and sales lead Contact? And What are the required parameters to pass to that WSDL?
    Please let me know if any information required.
    Thanks and Regards,
    Jason

    Hi,
      Sample soap messages for creating Sales Lead ::
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://xmlns.oracle.com/apps/marketing/leadMgmt/leads/leadService/types/" xmlns:lead="http://xmlns.oracle.com/oracle/apps/marketing/leadMgmt/leads/leadService/" xmlns:lead1="http://xmlns.oracle.com/apps/marketing/leadMgmt/leads/leadService/" xmlns:not="http://xmlns.oracle.com/apps/crmCommon/notes/noteService" xmlns:not1="http://xmlns.oracle.com/apps/crmCommon/notes/flex/noteDff/">
       <soapenv:Header/>
       <soapenv:Body>
          <typ:createSalesLead>
             <typ:salesLead>
                <lead:Name>Lead Created For Migrration Test4</lead:Name>
                <lead:Rating_c>A</lead:Rating_c>
             </typ:salesLead>
          </typ:createSalesLead>
       </soapenv:Body>
    </soapenv:Envelope>
      Sample soap messages for creating Opportunity ::
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://xmlns.oracle.com/apps/sales/opptyMgmt/opportunities/opportunityService/types/" xmlns:opp="http://xmlns.oracle.com/apps/sales/opptyMgmt/opportunities/opportunityService/" xmlns:rev="http://xmlns.oracle.com/apps/sales/opptyMgmt/revenues/revenueService/" xmlns:not="http://xmlns.oracle.com/apps/crmCommon/notes/noteService" xmlns:not1="http://xmlns.oracle.com/apps/crmCommon/notes/flex/noteDff/" xmlns:rev1="http://xmlns.oracle.com/oracle/apps/sales/opptyMgmt/revenues/revenueService/" xmlns:act="http://xmlns.oracle.com/apps/crmCommon/activities/activitiesService/">
       <soapenv:Header/>
       <soapenv:Body>
          <typ:createOpportunity>
             <typ:opportunity>
                <opp:Name>Test Opportunity</opp:Name>
             </typ:opportunity>
          </typ:createOpportunity>
       </soapenv:Body>
    </soapenv:Envelope>
    Please revert if you have any clarifications.
    Best Regards,
    Mohd Sabeer

  • No template found creating Tabs and Processes in HR Flexible Performance UI

    Dear Experts
    We will be using EHP4 Flexible Performance UI.
    I have created the sample performance template in PHAP_CATALOG and have transported this to our DEV playpen client.
    Within the config Master client I want to configure the u201CDefine Tabs and Process Configuration for Templateu2019 IMG node and after I log in it takes me to the web dynpro screen u201CWeb dynpro ABAP configuration for Appraisalsu201D, I get the error u201CNo template foundu201D.
    When I check the Help it says 1) to check the template has been created and 2) that the template has been released
    I checked and the template does exist in PHAP_CATALOG and has been released.
    Has anyone encountered this problem and has a way to fix this?
    Thanks
    Oliver

    Hi Maurice,
    Thanks for your quick reply.
    Yes the template has been definitely released.
    Yes Iu2019m using the same user to create the template and trying to do the process tabs u2013 I have SAP ALL Access.
    Also, when I transport this template from the DEV master client - to a DEV unit test client I can actual run the process template setupu2026u2026u2026u2026.
    Developer has checked the code and DEV Master client is the same as DEV Unit test clientu2026u2026u2026.interesting.
    Have you ever come across the issue where the source client where template has been created and released that you could not create the process tabs?
    Any other ideas how I could solve this?
    Many thanks
    Oliver

  • BAPI to create PO and GR

    Hi,
    Can anybody send me some sample code to handle multiple files in application server. My requirement is to create an interface to create PO and GR from the file residing in Application server. Multiple files will be in application server. No selection screens are there. BAPI used are BAPI_PO_CREATE1 and BAPI_GOODSMVT_CREATE. And If anyone has already created this interface, please give me some idea of how to read multiple files and if possible send some sample code.
    Any help will be greatly appreciated.
    Regards,
    Naveen

    Hi Naveen,
        Go through this link.
    BAPI_PO_CREATE1
    Re: Proble in Creating Multiple Item PO using BAPI_PO_CREATE1
    BAPI_GOODSMVT_CREATE
    http://www.sap-img.com/abap/bapi-goodsmvt-create-to-post-goods-movement.htm
    http://www.4ap.de/abap/bapi_goodsmvt_create.php
    Reward Points For the Helpful.
    Regards,
    Harini.S

  • BAPI for create VIP and Group_d for BP

    Hey
    Do you know BAPI for filling fields VIP and Group_d from table BP001 for BP?
    Regards
    Radek

    Hey, thank you, with this BAPI I found bapi BAPI_BUPA_FS_TREASURY_ADD that suit my needs.
    BAPI FS_API_BP001_change is only for changing records, BAPI FS_API_BP001_ADD has some problems (short dump).
    Regards
    Radek

  • Function or bapi to upload the lead questionnaire to lead partner portal

    hi all,
    Is there any function or bapi to upload the lead questionnaire that exists in the marketing leads-lead partner portal . The survey should get attached to the lead . I am able to create the lead though with the LDPO process by a function module .Any help on this will be very useful.
    Thanks in advance.
    Mithun

    Hi Bharani,
    I can answer two of your questions:
    2. No, with a BAPI you cannot see the screens during processing.  After it is called you can display the BOM and check that the data is loaded correctly.
    3. You can see the error messages of the BAPI by looking in the RETURN structure.  This will contain details of any error, warning, information, and success messages generated during the creation of the BOM.
    Cheers,
    Brad

  • Creating IT00 and retrieving pernr

    Hi Guys,
              Generally when we do hiring in R/3, after creating IT0000 we get the pernr (internal). How to achieve this through BAPI? I know we cannot perform action thru BAPI. But what I am doing is I am creating each infotype (00, 01, 02, 06, 07, 19) with HR_MAINTAIN_MASTERDATA. So after creating IT00, I need to capture the created pernr and update other infotypes for that pernr. Is it right way? Please help me asap.

    use GET parameter ID PER as posted previously, that definitely works.  The HR_RETURN parameter does not work, that only contains PERNR when you are maintaining data on a pre-existing records.
    Be careful using HR_MAINTAIN_MASTERDATA for Hiring actions, in 4.6 it does not create the CP object and CP-->P relationship in OM.  Maybe it does in later releases, not sure.

  • Query on creating "Lead" from the Flat file

    Hi Group,
    I was trying to use the BAPI "BAPI_LEAD_CREATEMULTI" to create the lead.
    I have a requirement for creating the Lead... and I have a few questions on creating the Lead like:
    1)Does this Lead creation happen with the Business Partners or it has no
    in no way connection with the Business Partners?
    2)My requirement is that, I need to create leads for the records of the input file
    which I get from the User and this looks like this with the fields as:
    Sales prospect; Lead group; status; Qualification level; Origin; Priority; contact person; Lead group; status; Qualification level; Origin; and Priority.
    (ie., 12 different input fields starting with Sales Prospect to Priority ).
    In Sales Prospect, I will give the Business Partner # and also in the Contact Person.
    Could you pls let me know how my requriement can be fulfilled( probably with some other code ).
    Please give me your valuable suggestions on this to move further. And also, please give me some sample code to build this requirement.
    thanks in advance.
    Regards,
    Vishnu.

    Check the return structure in the BAPI if it contains only success message, then try giving <b>CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'</b> passing essential parameters immediately after the create bapi call.

Maybe you are looking for

  • IPod Mini and Windows Vista RC1

    Ok, so I connect my mini to my Vista RC1 machine (FULL PC, not BootCamp), then went to bed. A few minutes later, the mini's screen lights up like I just connected it to the machine, then the main ipod folder opens up like it was set to hard-drive mod

  • Patches and packges in 11.5.10.2 for solaris 9 to 10 upgrade

    Hi All, Im upgrading Solaris 9 to Solaris10, what are all the additional OS patches and Packages are required for APPS 11.5.10.2 on Sparc. Thanx in advance.

  • TS3276 Duplicate messages in mail

    I get messages left in my drafts folder, but they also show in my sent folder. How can I keep from getting these duplicates?  Or what am I doing that causes them?  Doesn't happen for everything.  Also happens in 10.7

  • Multiple webapp timeout

    I am working on a website using JSP and Servlets that contains multiple webapps. A user could potentially leave one webapp and spend a large amount of time in another before going back. We would like to find a way to prevent timeout from occurring if

  • Missing PCA document  in BW during delta extraction of 0EC_PCA_3

    Hi experts, We are using Oracle 10g Data base for our ECC6.0 R/3 system.During BW extraction some of the PCA line item records got missed which gets update in data base table GLPCA in R/3 after successful document creation. We are in the process of a