headershadow

Find back relevant SAP CRM Employee data using multiple approaches

Print Friendly

In SAP CRM you normally create each end-user as an employee in the system.

Technically this means you will create the employee as a Business Partner in the system and map this business partner with the relevant User ID.

  • In the SAP GUI, you would create such an employee using the transaction code BP, where you would create a “Person” in the BP role BUP003 (employee). The mapping with the user ID can then be done on the tab page “identification”, assuming you have selected the BP role Employee to display.
  • In the SAP CRM WEBUI this process is simpler in that sense that you no longer need to manually choose the BP role “BUP003 employee” but rather use the navigation link “Create Employee” which can be found on the work center page “Account Management”.

Details of the employee in the SAP GUI:

When you select the BP role “BUP003 – Employee” and next open the tab page “Identification”, you will see that normally the User ID of the employee is maintained.

Details of the employee in the CRM WEB UI:

When creating the Employee via the CRM WEB UI, you will be able to add the User ID in the assignment block Users.

Below you will find some ways in which you can find back relevant Employee information based on several approches.

1. COM_BPUS_BUPADATA_FOR_USER_GET

Using this Function module, you can easily find back the Business partner details of the corresponding Employee based on his User ID.

You can use this function module to read the following data for a specified user:

(a) the relevant business partner
(b)its central data
(c) an address
(d) the communication data on the standard address

Enter the User ID as import Parameter for IS_USERNAME and press execute:

2. Tables HRP1000 & HRP1001

In table HRP1000 you could look up the Central Person ID for a User based on his name for example:

Object Type: CP
MC_STEXT : *Pelssers*

Now that you know the OBJID (50000001), you can look up the BP details in table HRP1001:

So as input parameter we would use the following:
OTYP: CP
OBJID: 50000001
SCLAS: BP
In the field SOBID we would get the BP number of the employee related to the User.

Alternative approach, doing this search based on the User ID would be to first search for the Central Person (OBJID) that matches the user ID EXE460 in table HRP1001.

In such a case I would enter the following as input parameter:
OTYP: CP
SOBID: EXE460

I now know that the CP ID = 50000001
Next I do another search using:
OTYP = CP
OBJID = 50000001
SCLAS = BP

3. BP_BUPA_SEARCH_BY_USER

You can use this function module to find back the Business Partner ID based on the User ID:

Fill IR_USER structure as follows
SIGN: I
OPTION: EQ
LOW: (username)
You will get the result in ET_PARTNER

Executing this shows us the following:

ET_PARTNER contains the Business Partner ID.

4. BP_CENTRALPERSON_GET

Executing this will return the BP GUID of the employee:

Using this GUID (in table BUT000) I can look-up the BP ID:

 

Cheers

Davy

Davy has been working as an SAP Consultant since 2000 and started working in the SAP IS-U Module , but as of 2002 he has mainly worked as functional SAP CRM consultant and SAP Authorizations consultant.
More about

0 thoughts on “Find back relevant SAP CRM Employee data using multiple approaches

Leave a Reply


*