Monday, July 5, 2010

Setting up CRM middleware

Below are the steps to configure the middleware for replication of data between CRM and R/3 system. In each step, the target system is mentioned in the braces indicating which system this particular setting is to be done.

Step 1 - Define Logical systems (CRM)

  • In the SAP CRM IMG menu, goto Customer Relationship Management -> CRM Middleware and Related Components -> Communication Setup -> Set Up Logical Systems -> Define Logical System and then New Entries (F5).
  • In the Log.System column, enter a name for the logical system that you want to create.
  • It is recommend that you use the following naming convention: CLNT (for example, CS7CLNT200) , is the ID number of your ERP system, in the number of the relevant client in your ERP system.
  • In the Name column, enter a description of the logical system, for example, CRM Best Practices.
  • Save your entries.
  • Now follow the above steps to create a logical system for your ECC system

Step 2 – Assign logical system to a client (CRM)

  • Goto tcode SCC4. Alternate path: IMG -> Customer Relationship Managment -> CRM Middleware and Related Components -> Communication Setup -> Set Up Logical Systems -> Assign Logical System to Client.
  • Select your CRM client.
  • Choose Details
  • The Change View “Clients”: Details screen appears.
  • Under Logical system, enter , for example, CS7CLNT200.
  • Save your entries.

Step 3 – Define Logical system (ECC)

  • In the SAP ERP IMG menu, goto SAP NetWeaver -> Application Server -> IDoc Interface/Application Link Enabling (ALE) -> Basic Settings -> Logical Systems -> Define Logical Systems.
  • Choose New Entries (F5).
  • In the Log.System column, enter a name for the logical system that you want to create.
  • It is recommend that you use the following naming convention: CLNT (for example, ES7CLNT020), is the ID number of your ERP system, in the number of the relevant client in your ERP system.
  • In the Name column, enter a description of the logical system.
  • Save your entries.
  • Repeat the above steps to create a logical system for your CRM system.

Step 4 – Assign logical system to a client (ECC)

  • Goto tode SCC4. Alternate path: In the SAP ERP menu, goto Tools -> Administration -> Administration -> Client Administration -> Client Maintenance.
  • Select your ERP client and choose Details (Ctrl + Shift + F2).
  • In the Logical System field, select the newly created logical system of your SAP ERP client using the input help.
  • Save your entries.

Step 5 - Creating RFC users (CRM & ECC).
An RFC user needs to be created in both the systems, which will be used by the middleware to connect to the target systems. In other words, a user in CRM system will be used by the R/3 system to connect to CRM system and vice verse. Creation of RFC user is similar to creating any other user in the system from tcode SU01, only difference is the USER TYPE field in logon data. The user type for rfc users should be "Communication" rather than dialogue, which is for mormal users of the system. You cannot login into SAP gui using this rfc user. It is only for communication purpose. This step needs to be performed in both CRM as well as R/3 system for a bidirectional flow.

Step 6 - Creating RFC destinations (CRM & ECC).
RFC destinations is like giving a name to your system which can be used to by other systems to connect to it.
To create an RFC destination goto tcode SM59 or follow IMG path IMG -> Customer Relationship Management -> CRM Middleware and Related Components -> Communication Setup -> Define RFC Destinations.

In the SAP ERP IMG menu, goto SAP NetWeaver -> Application Server -> IDocInterface/Application Link Enabling (ALE) -> Communication -> Create RFC Connections .

  • Click on the create button in the tool bar to create a new RFC destination.
  • In the field RFC Destination give a name for this connection. Usually we follow the naming convention like CLNT. For example R3DCLNT200.
  • Choose connection type as 3 - Connection to ABAP system.
  • Enter a description for this RFC connection and press enter.

You will see different fields show up in technical settings and other tabs.

  • In Tech Settings tab, select Load Balancing as No. System number you can get from the logon pad. Target host and IP address you can get from your basis team. ( Remeber all these details are of your target system and not of your CRM system.)

Now click on the Logon and Secirity Tab.

  • If we have defined this system as a trusted system in the target system then we can select the radio button as Yes. Else we can leave it as No.
  • As we shall be using the RFC in background as well we can keep the check-box for Logon screen as unchecked. If we check this checkbox then system would throw up the logon screen where the details are to be entered in order to login to the system. This kind of manual intervention cannot be handled in background.
  • If we are using the Secure Network Communication (SNC) for which the profile has already been configured then this field becomes active.
  • We can have an added authorization to allow only specific users to use the RFC Connection. This can be done by adding a value in the field ‘Authorization for Destination’.
  • Enter the logon language and the client number for your target system.
  • Enter the RFC user name and password which we created in Step 1 in the R/3 system. (remeber this user is available in your target system and not your current system.)
  • The password field will not be required if we select trusted system.

Save your entries. Other tabs and fields can be left as default.
Now to view the connection you can go to SM59 tcode and in the initial screen open the ABAP connections folder. Double click on the RFC connection name you created. It will display the selected RFC connection. Here you can test your connection using the Test connection button. You can also edit your connection and save it.


Step 7 – Maintaining CRM connectivity config tables (ECC)

  • Table CRMCONSUM

Create an entry with the following details:

User : CRM

Active: selected

Description: CRM

Q-prefix: R3A

  • Table CRMRFCPAR

Create an entry with the following details:

User: CRM

Object name: *

Destination: Erp__to_Crm_ (for example, Erp_ER1001_to_Crm_CR10)

Load type: * all load types

Inqueue flag: X

Send XML: Mixed mode

Stop data:

For some of the fields left blank here (for example, queue names, BAPI name, description), entries will be added automatically by the system when starting the download of objects at a later stage in the installation.

Ensure that there is only one (the new) entry with Consumer CRM maintained in the CRMRFCPAR table. If not, delete other existing entries with CRM as Consumer. Otherwise, the download of sales documents ERP – CRM might not be successful.

  • Table CRMPAROLTP

Create an entry with the following details:

Parameter name: CRM_RELEASE

Parameter value:

  • Table TBE11 – Activating Event control

In this table, set the application NDI (New Dimension Integration) to status Active by selecting the check box in the A column.


Step 8 - Select your industry.
The industry selection determines the repository objects and the services generated for data exchange. We can select the relevant industry by navigating through the following path:
IMG -> Customer Relationship Management -> CRM Middleware and Related Components -> Generating Industry-Specific Objects and Services -> Select Your Industry

Step 9 - Generate industry specific objects
In general, this activity need not be done for new installations. Only in case of upgrades this needs to be done. We may check the initial generation log by going to transaction SMOGLASTLOG. If we see that the generation is already done then we need not do this activity again.
If its not done yet we can do it through tcode SMOGTOTAL or IMG path:
IMG -> Customer Relationship Management -> CRM Middleware and Related Components -> Generating Industry-Specific Objects and Services -> Generate Industry-Specific Objects
After starting the generation, we can monitor the status of the same through transaction GENSTATUS or through the IMG path:
IMG -> Customer Relationship Management -> CRM Middleware and Related Components -> Generating Industry-Specific Objects and Services -> Check Generation Processes

Step 10 - Creating Sites, Publications and Subscriptions.
Before configuring these three entities i'll tell you what is their significance.

  • Any system involved in the data transfer is referred to as a site, eg CRM system, R/3 system or BW system. Each site individually can act as a source site or a target site or both at the same time during a bidirectional exchange of data.
  • A Publication is a logical group or set of data eg Bus. Partners, relationships, campaigns conditions etc.Each publication has replication object (which is generated from and represents a particular BDoc type) assigned to it which determines the data which shall be exchanged.
  • Subscription is the assignment of a Publication to a particular site.

To configuration of all the above can be done from tcode SMOEAC or IMG path:
IMG -> Customer Relationship Management -> CRM Middleware and Related Components -> Communication Setup -> Create Sites and Subscriptions.

  • In SMOEAC initial screen select object type on the left panel as Site and click on create button.
  • Enter a name and description for this site. (remember we are creating a site for r/3 system so name it similar to it)
  • In the type field select R/3
  • Click on the button "Site Attributes".
  • A popup is displayed.
  • Enter the RFC destination we created in step 2 above.(i.e. RFC destination of the R/3 system)
  • Click on button "Get Values". All other fields of the popup will get populated automatically.
  • Save the site. A new site is created.

Creating a publication

  • On the left hand side select object type as publication and click on create button. A wizard will be started.
  • Enter a name for the publication.
  • Select Simple intelligent or simple bulk popup depending on need.
  • Select the replication object on the right based on the requirement.
  • Next screen aloows to select criteria fields.
  • On the left all the available criteria fields will be displayed. to select the fields and click on right arrow to move it to the right column to select it.
  • After this just complete the wizard and a publication will be created.

Create subscription now.

  • On the left hand side select object type as Subscription and click on create button. A wizard will be started.
  • Enter a subscription name and the publication name you want to subscribe to.
  • If applicable (if we have selected Criteria Values during configuration of the Publication as we have seen in the earlier step) then the screen for Criteria Values shall appear. Else on clicking the ‘Continue’ button this step will be ignored and the screen for Sites assignment shall appear.
  • To assign a site click on the create button.
  • A popup will be displayed showing all the available sites. Choose the site which you want to assign. Multiple sites can be selected depending on the need.
  • Complete the wizard to create the subscription.

Step 11 - Define Middleware Parameters These are the parameters which determine how the data exchange between various systems will happens. These parameters would be dependant on the various business scenarios of the Client.We can maintain these parameters using transaction R3AC6. you can get some examples on how maintian the parameters in SAP note 490932.

Step 12 - Registration of RFC destination.
Check that all the RFC Destinations have been registered. Unless and until the registration is done there shall not be any data exchange with those destinations.
This can be done in transaction SMQS

  • Go to tcode SMQS and click on button "Registration".
  • In the popup screen enter the destination name, the max connection time and max run time.

Step 13 - Registering the queues.
In tcode SMQR all the CSA and R3A queues must be registered i.e. Type = R, for the bdocs to flow.

  • If any of the queue is showing as Type = U, then select the queue and click on registration.
  • To deregister the queue (for debugging purpopse), select the queue and click on deregister.
  • If you do not see any queue entry in SMQR, then you can run FM QIWK_REGISTER to add a queue entry.

Step 14 - Setting up number ranges.
Number ranges must be defined according to the requirement, inorder for the replication to take place correctly.

  • For example, if a BP is created in CRM and this BP has to be replicated to R/3 with the same BP number, then number range for business partner in CRM should be defined as internal and number ranges in R/3 for BP should be defined as external.

Step 15 - Set up objects
There are primarily three types of objects viz. Business Objects, Customizing Objects and Condition Objects. These can be done in transactions R3AC1, R3AC3 and R3AC5 respectively. Here we can as well setup the filters and inactivate/activate objects for data exchange. Alternate path is: SAP Menu -> Architecture and Technology -> Middleware -> Data Exchange -> Object Management

Once the above configuration steps are done we can start with the data exchange between SAP R/3 and CRM system.

Step 16 - Start initial load
The initial load can be started using transaction R3AS. Here we have to provide the objects for which we want to start the initial load along with the sender and receiving Sites.
Alternate path: SAP Menu -> Architecture and Technology -> Middleware -> Data Exchange -> Initial Load

Step 17 - Monitor the initial load
On starting the initial load, we can monitor the progress and status of the data exchange through transaction R3AM1. Alternate path: SAP Menu -> Architecture and Technology -> Middleware -> Data Exchange -> Initial Load

The same can also be done through Middleware Monitoring Cockpit, tcode SMWP

Step 18 - Activation of Delta load
The delta download can be setup through transaction R3AC4. Here we can specify which of the Objects classes and the events under that Object Class to be added and if we want to inactivate that we can as well do so.
Alternate path: SAP Menu -> Architecture and Technology -> Middleware -> Data Exchange -> Delta Load

Step 19 – Create Sync request

The synchronization requests can be created through transaction R3AR2.
Alternate path: SAP Menu -> Architecture and Technology -> Middleware -> Data Exchange -> Synchronization

Step 20 – Start Sync request

The synchronization requests can be started through transaction R3AR4.
Here we have to specify the Request name which we created in the earlier step and also source and target sites

14 comments:

  1. Hey Vinay,
    Thanks for the blog, this is really helpful.

    I have a doubt:
    For the step - Assign logical system to a client, we assign the logical system i.e. for CRM system we assign the CRM logical system and for ECC we assign the ECC logical system. Correct?
    My question is how will the CRM system understand which is the ECC system connected and vice versa.
    Or is it just by defining the logical system in the activity - Define Logical systems the connection between ECC and CRM is done?

    Thanks!

    Best Regards,
    Roshan

    ReplyDelete
  2. Hi roshan
    ECC RFC destination name and CRM logical system has to be same and ECC logical name and RFC
    destination has to be same

    ReplyDelete
  3. Finding the time and actual effort to create a superb article like this is great thing. I’ll learn many new stuff right here! Good luck for the next post buddy.

    I will bookmark your site and check again here often. I’m quite sure :)

    Thanks
    ERP Software Dubai

    ReplyDelete
  4. Hi! Thank you so much for detailed explanation, it's really wonderful that you showed the most important steps to configure the middleware for replication of data between microsoft dynamic crm and R/3 system. I appreciate it, please write more :)

    ReplyDelete
  5. Well explained. Got to learn new things from your Blog on Appium.Appium training in chennai

    ReplyDelete
  6. Webtrackker technology is the best IT training institute in NCR. Webtrackker provide training on all latest technology such as Sap crm training. Webtrackker is not only training institute but also it also provide best IT solution to his client. Webtrackker provide training by experienced and working in the industry on same technology.Webtrackker Technology C-67 Sector-63 Noida 8802820025

    SAP crm Training institute in indirapuram


    SAP crm Training institute in Noida


    SAP crm Training institute in Ghaziabad


    SAP crm Training institute in Vaishali


    SAP crm Training institute in Vasundhara

    SAP crm Training institute in Delhi South Ex

    ReplyDelete
  7. This comment has been removed by the author.

    ReplyDelete
  8. I really appreciate information shared above. It’s of great help. If someone want to learn Online (Virtual) instructor led live training in SAP CRM, kindly Contact GRONYSA
    Click for SAP CRM Course details SAP CRM
    GRONYSA Offer World Class Virtual Instructor led training on SAP CRM. We have industry expert trainer. We provide Training Material and Software Support. GRONYSA has successfully conducted 10,000 + trainings in India, USA, UK, Australlia, Switzerland, Qatar, Saudi Arabia, Bangladesh, Bahrain and UAE etc.
    For Demo Contact us.
    Nitesh Kumar
    GRONYSA
    E-mail: nitesh.kumar@gronysa.com
    Ph: +91-9632072659/ +1-2142700660
    www.GRONYSA.com



    ReplyDelete
  9. Can I find any SAP Server Access in your portfolio?

    ReplyDelete