Download - Crm Middleware1
-
8/10/2019 Crm Middleware1
1/91
-
8/10/2019 Crm Middleware1
2/91
India SAP CoE, Slide 2
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
Middleware Enhancement
-
8/10/2019 Crm Middleware1
3/91
India SAP CoE, Slide 3
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
Middleware Enhancement
-
8/10/2019 Crm Middleware1
4/91
India SAP CoE, Slide 4
Introduction
Purpose
Use
Challenges
-
8/10/2019 Crm Middleware1
5/91
India SAP CoE, Slide 5
Purpose
Integration with all CRM applications and the existing Backend
landscape.
Develop a completely new application which has the full
integration with other applications provided by the CRM
Middleware.
Enhancing Middleware to have full integration with for any
enhancement in CRM
-
8/10/2019 Crm Middleware1
6/91
India SAP CoE, Slide 6
Use
Customizing Objects, often it is table existing in one system (e.g.
R/3 Backend), which should also be available in the connectedsystem (e.g. CRM server).
Typically Customizing Objects are not validated by an
application, because they normally contain data that is used for
validation itself. Customizing objects can be loaded from an R/3
Backend to CRM, to CDB or from the CRM system to the CDB.
-
8/10/2019 Crm Middleware1
7/91
India SAP CoE, Slide 7
Challenges
No considerable challenges are identified during this
replication. The RFC connection needs to be ensured betweenR/3 and CRM systems.
-
8/10/2019 Crm Middleware1
8/91India SAP CoE, Slide 8
Middleware Enhancement
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
-
8/10/2019 Crm Middleware1
9/91India SAP CoE, Slide 9
Object Replication
Most projects have additional requirements like customer-specificfields and tables, which should be fully integrated with all CRM
applications and the existing Backend landscape. In some cases it
might also be required to develop a completely new application
which has the full integration with other applications throughout
the whole landscape.
Here we are going in details about 3 common Use Cases.
-
8/10/2019 Crm Middleware1
10/91India SAP CoE, Slide 10
Table Replication Scenarios
Load Customizing Object from R/3 to CRM (new table)
Load Customizing Object from R/3 to CRM (new table)
using BDoc
Add new field in R/3 table communicated to the CRM
Online application
-
8/10/2019 Crm Middleware1
11/91India SAP CoE, Slide 11
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
Middleware Enhancement
-
8/10/2019 Crm Middleware1
12/91India SAP CoE, Slide 12
Table Replication Scenarios
Load Customizing Object from R/3 to CRM (new table)
Load Customizing Object from R/3 to CRM (new table)
using BDoc
Add new field in R/3 table communicated to the CRM
Online application
-
8/10/2019 Crm Middleware1
13/91India SAP CoE, Slide 13
Syntax DescriptionImportant Transactions used in this exercise
SE11 : To create Custom table in R/3 as well as in CRM
SE37 : To create Function group and to copy
standard function Module in CRM
R3AC3 : Create adapter Object (In CRM)
R3AS : Execute Adapter Object (In CRM)
SMQ1 : Outbound Queue monitor (In R/3)
SMQ2 : Inbound Queue Monitor (In CRM)
SMWP: Monitor Work Process (In CRM)
-
8/10/2019 Crm Middleware1
14/91India SAP CoE, Slide 14
Syntax Description
Important Function Modules used in this Exercise
MAP_BAPIMTCS_TO_CUSTOMIZING : Signature FM used for Mapping
in CRM
Important Tables / Structures used in this document
BAPIMTCS : Middleware Transaction Container Structure
-
8/10/2019 Crm Middleware1
15/91India SAP CoE, Slide 15
Table replicationwithout Bdoc
SAP CRMSAP R/3
- Create a Mapping Function
Module ( Use template
MAP_BAPIMTCS_TO_CUSTOMI
ZING)
-Create MW Adaptor Object
*Object Class = Customizing
*Source Site type=
SMOF_ERPSITE R/3
*Table/Structure = new table of
R/3
*Mapping Module R/3 to CRM =
newly created Mapping F.M
1.2.
4.
3.
- Create new table in R/3-Create a similar tables as of R/3
5. Process Initial Load
-
8/10/2019 Crm Middleware1
16/91India SAP CoE, Slide 16
Create Custom Table in R/3
Create a customizing table
EX: ZCOUNTRY
Field Key Data Element
MANDT Yes MANDT
COUNTRY Yes TEXT30CONTINENT No TEXT30
-
8/10/2019 Crm Middleware1
17/91India SAP CoE, Slide 17
Create Custom Table in CRMCreate a new table as a copy of table ZCOUNTRYin the R/3 Backend
using the transaction SE11.
The final table structure should be similar to R/3:
Table ZCOUNTRY:
Field Key Data ElementMANDT Yes MANDT
COUNTRY Yes TEXT30
CONTINENT No TEXT30
-
8/10/2019 Crm Middleware1
18/91India SAP CoE, Slide 18
Custom Table in CRM & R/3
-
8/10/2019 Crm Middleware1
19/91India SAP CoE, Slide 19
Create a mapping function module in CRM
Use function module AP_BAPIMTCS_TO_CUSTOMIZING
as a template and copy it to the new function module say
ZMAP_BAPIMTCS_TO_CUSTOMIZING. (create custom
function group)
-
8/10/2019 Crm Middleware1
20/91India SAP CoE, Slide 20
Code for custom FMMap all data from container into database structure and
update database table
Loop the Bapimtcs.
Check DA for data
Populate the data into the custom table.
ENDLOOP.
Update the database table directly
INSERT THE DATA INTO THE CUSTOM TABLE
Ensure that no validation flow is called
E_DO_NOT_CALL_GDH = 'X'.20
-
8/10/2019 Crm Middleware1
21/91India SAP CoE, Slide 21
To create the adapter object, go to transaction R3AC3 (Maintenance of
customizing objects). Click on Create
Create a MW adapter object to enable initial
load
Create
-
8/10/2019 Crm Middleware1
22/91India SAP CoE, Slide 22
Adapter Object Overview
Enter a name for the object. In our example the object name is
ZCRMCOUNTRY,
Description isCountries and continents.
Press return so that the other fields are ready for input.
Enter a description of your object in the field right of the object name
e.g. Countries and Continents CRM.
The object class is already filled withCUSTOMIZING.
Leave the fieldLinked BDoc type - empty
Enter a block size1000
-
8/10/2019 Crm Middleware1
23/91India SAP CoE, Slide 23
Adapter Object Overview
Enter Description
This will come automatically for
customizing objects
Adapter Object Name
Block Size
-
8/10/2019 Crm Middleware1
24/91India SAP CoE, Slide 24
Adapter Object details
Tab strip Initial Flow Contexts
In our example the source site type is R/3. Choose the entry from thecombo box. All the other fields are filled automatically, especially the
target site type CRM.
Provide R/3
-
8/10/2019 Crm Middleware1
25/91India SAP CoE, Slide 25
Adapter Object details
Tab strip Tables/Structures
Enter the table name ZCOUNTRY in column table (source site). All
other fields can be left empty as we provide the mapping with our mapping
function module.
Provide Table Name
-
8/10/2019 Crm Middleware1
26/91India SAP CoE, Slide 26
Adapter Object details
Tab strip Mapping Modules R/3 to CRM
Provide the mapping function module created for this object inour case it is ZMAP_BAPIMTCS_TO_CUSTOMIZING
Tab strip Mapping Modules R/3 to CRM
Provide Custom Mapping FM
-
8/10/2019 Crm Middleware1
27/91
India SAP CoE, Slide 27
Test initial load (Tcode: R3AS)
To test the work, go to transaction r3as, select object
ZCRMCOUNTRY, Execute and start the initial load.
When you press enter these
fields will be filled automatically
Provide The Adapter ObjectExecute
-
8/10/2019 Crm Middleware1
28/91
India SAP CoE, Slide 28
Test initial load (Tcode: R3AS)
Once the initial load is started you will find the popup
-
8/10/2019 Crm Middleware1
29/91
India SAP CoE, Slide 29
Table Replication
Load Customizing Object from R/3 to CRM (new table)using BDoc
Load Customizing Object from R/3 to CRM (new table)
Add new field in R/3 table communicated to the CRM
Online application
-
8/10/2019 Crm Middleware1
30/91
India SAP CoE, Slide 30
Table replicationusing Bdoc
SAP CRMSAP R/3
-Create a extension part Structure
for new table
1.
2.
5.
4.
- Create new table in R/3
-Create a similar tables as of R/3
- Create a Transfer Structure
(Table Fields without Client)3.
- Create a Transfer Structure(Table Fields without Client)
-Create a Message BDoc6.
-MW adapter mapping function
module in CRM (using template
SAMPLE_INTERFACE_BAPIMTC
S_BDOC )
7.
-
8/10/2019 Crm Middleware1
31/91
India SAP CoE, Slide 31
SAP CRMSAP R/3
-Create a Validation F.M
9.
8.
12.
- Create a mapping function
module with table parameters 1.
newly created table, 2.
BAPIMTCS
- Create a Extract Function
Module (using template
CRM_SAMPLE_EXTRACT_MOD
ULE )
10.
-Maintain the flow table in
SMW3BDOCIF (entering Validation
F.M)
13.
14.
-Create a MW Adaptor Object,
*Object Class = Customizing Class,
*Source Site type=
SMOF_ERPSITE R/3,
*Table/Structure = new table of R/3,
*Mapping Module R/3 to CRM =
newly created Mapping F.M
- Registering the extractor module
in table CRMSUBTAB11.
Process Initial Load
Table replicationusing Bdoc
-
8/10/2019 Crm Middleware1
32/91
India SAP CoE, Slide 32
Syntax DescriptionImportant Transactions used in this exercise
SE11 : To create Custom table in R/3 as well as in CRM
SE37 : To create Function group and to copy
standard function Module in CRM
R3AC3 : Create adapter Object (In CRM)
R3AS : Execute Adapter Object (In CRM)
SMQ1 : Outbound Queue monitor (In R/3)
SMQ2 : Inbound Queue Monitor (In CRM)
SMWP: Monitor Work Process (In CRM)
-
8/10/2019 Crm Middleware1
33/91
India SAP CoE, Slide 33
Syntax Description
Important Function Modules used in this Exercise
CRM_SAMPLE_EXTRACT_MODULE:
Extractor FM used for extracting data in R/3.
SAMPLE_INTERFACE_BAPIMTCS_BDOC:
Signature Mapping FM from R/3 to CRM.
Z_CRS_MAP_ZUOM_BAPIMCTS:
Custom FM to send data from R/3 to CRM
server via the MW adapter framework.
Important Tables / Structures used in this document
BAPIMTCS :
Middleware Transaction Container Structure
-
8/10/2019 Crm Middleware1
34/91
India SAP CoE, Slide 34
Create Custom Table in R/3Create a customizing table
EX: Z_UOM
Field Key Data Element
MANDT Yes MANDT
UOM Yes CHAR10DESCRIPTION No CHAR25
-
8/10/2019 Crm Middleware1
35/91
India SAP CoE, Slide 35
Custom Table in CRMCreate a customized transfer structure. The data exchange
between R/3 Backend and CRM server realized by transfer
structures, which are then sent via BAPIMTCS data containers.
EX: Z_UOM_TRANSFER
Component Data Element
UOM CHAR10DESCRIPTION CHAR25
-
8/10/2019 Crm Middleware1
36/91
India SAP CoE, Slide 36
Create a mapping function module in R/3
Create a mapping FM (Z_CRS_MAP_ZUOM_BAPIMTCS) in R/3
Use function module SAMPLE_INTERFACE_BAPIMTCS_BDOC
as a template and copy it to the new function module say
Z_CRS_MAP_ZUOM_BAPIMCTS.(create custom function group)
-
8/10/2019 Crm Middleware1
37/91
India SAP CoE, Slide 37
Code for custom FM in R/3
FUNCTION Z_CRS_MAP_ZUOM_BAPIMCTS.
Create transfer structure LIKE ZDC_K_UOM_TRANSFER.
* Map all selected R/3 table entries
LOOP AT r3tables.
* Map R/3 table entry into transfer structure
MOVE-CORRESPONDING r3tables TO transfer structure.
* Store transfer structure into data container
et_bapimtcs-tabname = 'Z_UOM_TRANSFER'.
MOVE lv_transfer_structure TO bapimtcs data field.
* other fields of BAPIMTCS are not relevant for this example
APPEND et_bapimtcs.
ENDLOOP.
-
8/10/2019 Crm Middleware1
38/91
India SAP CoE, Slide 38
Create an extractor FM in R/3
Create an extractor FM (Z_EXTRACTR3_UOM) by copying the
standard FM (CRM_SAMPLE_EXTRACT_MODULE) to extract datafrom the custom table created.
-
8/10/2019 Crm Middleware1
39/91
India SAP CoE, Slide 39
Register the extractor FM in R/3
In CRMSUBTAB of R/3 Maintain the following entries
Field Value
Consumer CRM
Object name Z_CRM_UOM
Up or download D
Object class Z_CRM_UOM_CL
Function module Z_EXTRACTR3_UOM
-
8/10/2019 Crm Middleware1
40/91
India SAP CoE, Slide 40
Create custom Table in CRM
Create custom table Z_UOM
Field Key Data Element
MANDT Yes MANDT
UOM Yes CHAR10
DESCRIPTION No CHAR25
-
8/10/2019 Crm Middleware1
41/91
India SAP CoE, Slide 41
Create custom Transfer Structure in CRMCreate a customized transfer structure. The data exchange between R/3
Backend and CRM server realized by transfer structures, which are then
sent via BAPIMTCS data containers.
EX: Z_UOM_TRANSFER
Component Data Element
MANDT CHAR3
UOM CHAR10
DESCRIPTION CHAR25
-
8/10/2019 Crm Middleware1
42/91
India SAP CoE, Slide 42
Creating mBDocCreate structure Z_CRM_UOM_ROOT_CONTROL
Component Component type
TASK Char1
Create structure Root Data Z_CRM_UOM_ROOT_DATA
Component Component type
GUID SMO_GUID
UOM CHAR10
DESCRIPTION CHAR25
-
8/10/2019 Crm Middleware1
43/91
India SAP CoE, Slide 43
Create structure Root Data Z_CRM_UOM_ROOT_DATAX
Component Component type
UOM CHAR10
DESCRIPTION CHAR25
Create structure Z_CRM_UOM_ROOTfor the entire root segment with the following
component.
Component Component type
CONTROL Z_CRM_UOM_ROOT_CONTROL
DATA Z_CRM_UOM_ROOT_DATADATAX Z_CRM_UOM_ROOT_DATAX
Creating mBDoc
-
8/10/2019 Crm Middleware1
44/91
India SAP CoE, Slide 44
Creating mBDocCreate structure Z_CRM_UOM_ROOT_TABLE with line type
Z_CRM_UOM_ROOTin order to carry multiple messaging BDoc
instances, i.e. root segments, it is necessary to create the standardtable.
Finally it is necessary to create the entire extension part, which
should hold all data segments. The structure Z_CRM_UOM_EXT
Component Component type
Z_CRM_UOM_ROOT Z_CRM_UOM_ROOT_TABLE
-
8/10/2019 Crm Middleware1
45/91
India SAP CoE, Slide 45
Creating a Messaging BDoc
Create and activate a new messaging BDoc type that can transport the
content of the table Z_UOM.
Call transaction SBDM. Press the Button create BDoc, F5 or
Go via the menu BDoc -> Create BDoc.
Details of BDoc
Tab strip BDoc Overview
Enter a name and a short name for the BDoc, here for example
name=ZUOM_MESG, short name=ZUOM_MESG.
-
8/10/2019 Crm Middleware1
46/91
India SAP CoE, Slide 46
Enter a description for your BDoc, e.g. MESG BDoc for UOM &
Description.
Make sure, the BDoc Class is set to Messaging BDoc
Fill the field Related Data type in tab General Data" with the name of the
extension part structure. Enter Z_CRM_UOM_EXT.
Creating a Messaging BDoc
-
8/10/2019 Crm Middleware1
47/91
India SAP CoE, Slide 47
Creating messaging BDoc type.
The classical part is used to determine the receiver of BDocmessages. To create the classical part, add a segment to the BDoc
type.
Creating the Segments
Press the Button Create Segment,
F7 or select via the menu BDoc -> Create Segment.Tab strip Segment Overview
Enter the name and description for the segment, for example
segment name = Z_CRM_UOM_ROOT, description Table Z_UOM.
Classical part of the new mBdoc
-
8/10/2019 Crm Middleware1
48/91
India SAP CoE, Slide 48
Creating Classical part of the new
messaging BDoc type.
Tab strip Segment FieldsGo to the Segment Fields tab and specify the fields of the new segment. Use
the following fields:
Field Name Key Data Element
GUID X SMO_GUID
DESCRIPTION TEXT25
Save your changes. Check your new messaging BDoc type and activate it.
-
8/10/2019 Crm Middleware1
49/91
India SAP CoE, Slide 49
Creation of MW Adapter object to enable
initial load.Object Overview
Enter a name for the object. In our example the object name is
Z_CRM_UOM;
Provide description Adaptor Object UOM using
MBDoc.
Press return so that the other fields are ready for input.
Enter a description of your object in the field right of the objectname, e.g. Adaptor Object UOM using MBDoc.
The object class is changed to Z_CRM_UOM_CL.
-
8/10/2019 Crm Middleware1
50/91
India SAP CoE, Slide 50
Creation of adapter object to enable initial
load.
Select the value ZUOM_MESGfor the field Linked BDoc type
Enter a block size (eg 1000) .
-
8/10/2019 Crm Middleware1
51/91
India SAP CoE, Slide 51
Creation of adapter object to enable initial
load.
Tab strip Initial Flow ContextsIn our example the source site type is R/3. Choose the entry from the
combo box. All the other fields are filled automatically, especially the
target site type CRM.
Tab strip Tables/Structures
In this tab strip the tables which are to be selected can be entered.
Enter the table name Z_UOM in column table (source site). And mention
Z_UOMin the mapped Table structure.
-
8/10/2019 Crm Middleware1
52/91
India SAP CoE, Slide 52
Creation of adapter object to enable initial
load.
Tab strip Mapping modules
Enter Z_MAP_UOM_BAPIMTCS_MBDOCin column Module
name.
Save your changes.
-
8/10/2019 Crm Middleware1
53/91
India SAP CoE, Slide 53
Creation of mapping function module in
CRM (Inbound )
To process the data in the CRM server it is necessary to map the datasent via the container structure BAPIMTCS into an mBDoc.
Copy the Signature FM SAMPLE_INTERFACE_BAPIMTCS_BDOC
to Z_MAP_UOM_BAPIMTCS_MBDOCand select the function group
you created in the previous step.
-
8/10/2019 Crm Middleware1
54/91
India SAP CoE, Slide 54
Test initial load
To test the work, go to transaction r3as, select object Z_UOM, Execute
and start the initial load.
When you press enter thesefields will be filled automatically
Provide The Adapter Object
Execute
-
8/10/2019 Crm Middleware1
55/91
-
8/10/2019 Crm Middleware1
56/91
India SAP CoE, Slide 56
Table Replication
Load Customizing Object from R/3 to CRM (new table)
using BDoc
Load Customizing Object from R/3 to CRM (new table)
Add new field in R/3 table communicated to the CRM
Online application
-
8/10/2019 Crm Middleware1
57/91
India SAP CoE, Slide 57
Syntax Description
Important Transactions used in this exercise
SE11 : Tocreate Custom table in R/3 as well as in CRM
SE37 : To create Function group and to copy
standard function Module in CRM
R3AC3 : Create adapter Object (In CRM)
R3AS : Execute Adapter Object (In CRM)
SMQ1 : Outbound Queue monitor (In R/3)
SMQ2 : Inbound Queue Monitor (In CRM)
SMWP: Monitor Work Process (In CRM)
-
8/10/2019 Crm Middleware1
58/91
India SAP CoE, Slide 58
Syntax Description
Important Function Modules used in this Exercise
MAP_BAPIMTCS_TO_CUSTOMIZING : Signature FM used for
Mapping in CRM
Important Tables / Structures used in this document
BAPIMTCS : Middleware Transaction Container Structure
Add new field in R/3 table communicate to the
-
8/10/2019 Crm Middleware1
59/91
India SAP CoE, Slide 59
Add new field in R/3 table communicate to the
CRM Online applicationSAP CRMSAP R/3
-Write macro to fulfill Unicode
support
1.
4.
- Extend database table by using
Append Structure
- Create a transfer structure, the
fields are similar to append
structure
2.
-implement user exit in R/3 adapter,
outbound direction5.
-Create F.M which returns the
value of global fields with export
parameters
*Enhanced table name,
*Enhanced table name
3.
-Register the user exit in tables
TBE24, TPS346.
Add new field in R/3 table communicated to the CRM Online application
-
8/10/2019 Crm Middleware1
60/91
India SAP CoE, Slide 60
Add new field in R/3 table communicated to the CRM Online application
SAP CRMSAP R/3
-Write macro to fulfill Unicodesupport
7.
11.
- Add new fields which are added
in R/3 by using EEWB
- Create a transfer structure8.
-Implement the user exit in R3
adapter, inbound direction.
12. -Create F.M in CRM which mapsthe field coming from R/3 to the
field created by EEW in CRM
10.
-Register the user exit in tables
TBE24, TPS34,
CRMC_BUT_CALL_FU
13.
- Enhance mBDoc type9.
14. Process Initial Load
E t d DDIC i R/3
-
8/10/2019 Crm Middleware1
61/91
India SAP CoE, Slide 61
Extend DDIC in R/3
Create a new domain (ZCONTINENT)
Create a new data element (ZCONTINENT)
E t d DDIC i R/3
-
8/10/2019 Crm Middleware1
62/91
India SAP CoE, Slide 62
Extend DDIC in R/3
Extend database table (KNA1 Table)
Go to -> Append structure
Append structure as ZZCONTINENT
Component ZZCONT and data element ZCONTINENT
E t d DDIC i R/3
-
8/10/2019 Crm Middleware1
63/91
India SAP CoE, Slide 63
Extend DDIC in R/3
Create the structure ZCONTINENT_TRANSFER
Component ZZCONT and data element ZCONTINENT
Implement User Exit in R/3
-
8/10/2019 Crm Middleware1
64/91
India SAP CoE, Slide 64
Implement User Exit in R/3
To transfer the field in both initial and delta load you can use a user exit of
the R/3 adapter which is in a central place. The user exit with interface
CRM0_200 is called in function module CRS_SEND_TO_SERVER, which
is the central sending functionality of the MW adapter framework.
Create function module
Z_USER_EXIT_BEFORE_SEND_TO_MW (Copy FMSAMPLE_PROCESS_CRM0_200 as a template)
Implement User Exit in R/3
-
8/10/2019 Crm Middleware1
65/91
India SAP CoE, Slide 65
Implement User Exit in R/3Code in the function Module:
Z_USER_EXIT_BEFORE_SEND_TO_MW
1. Check Object Class is BUPA.
2. Check Object Name is CUSTOMER_MAIN.
3. Define a macro for Unicode support
4. Determine next free CURRDNO5. Get KUNNR (Customer Number) from BAPIMTCS structure
6. Field I_BAPICRMDH2- DWNLOADTYP distinguish between
delta or initial Load
7. If delta load Read the data from global memory
8. If initial load read the data from KNA1 table
9. Add new BAPIMTCS Business Partner - New Field: CityCode
I l t U E it i R/3
-
8/10/2019 Crm Middleware1
66/91
India SAP CoE, Slide 66
Implement User Exit in R/3Parameters of the Function Module:
Z_USER_EXIT_BEFORE_SEND_TO_MW
-
8/10/2019 Crm Middleware1
67/91
India SAP CoE, Slide 67
Register user exit (R/3 Backend)
Parameter Value
Product ZCRM
Text User Exits in R/3
adapterRFC Destination Initial
Active X
Table maintenance: TBE24
R i t it (R/3 B k d)
-
8/10/2019 Crm Middleware1
68/91
India SAP CoE, Slide 68
Register user exit (R/3 Backend)
Parameter ValueProcess CRM0_200
Country Initial
Application Initial
Function Module Z_USER_EXIT_BEFORE_SEND_TO_MW
Product ZCRM
Table maintenance: TPS34
C C
-
8/10/2019 Crm Middleware1
69/91
India SAP CoE, Slide 69
Enhance DDIC in CRM
1. Create a new domain (ZCONTINENT)
2. Create a new data element (ZCONTINENT)
E h DDIC i CRM
-
8/10/2019 Crm Middleware1
70/91
India SAP CoE, Slide 70
Enhance DDIC in CRM
3. Extend database table (BUT000 Table)
Goto -> Append structure
Append structure as ZZCONTINENT
Component ZZCONT and data element
ZCONTINENT
-
8/10/2019 Crm Middleware1
71/91
India SAP CoE, Slide 71
Enhance DDIC in CRM
4. Create the structure ZCONTINENT_TRANSFER Component ZZCONT and data element
ZCONTINENT
-
8/10/2019 Crm Middleware1
72/91
India SAP CoE, Slide 72
Enhance mBDoc Type
1. Business Partner BDoc type BUPA_MAIN uses the
structure BUS_EI_EXTERN
2. For the data type BUS_EI_EXTERN in the ABAP
Dictionary in change mode. Then double-click on thecomponent CENTRAL_DATA, after that on the
component COMMON, and finally on DATA. You are now
in the substructure BUS_EI_BUPA_CENTRAL_DATA;
where you can create a new append structure
3. Add the name ZCONTINENTwith component ZZCONT
and component type ZCONTINENT
Enhance mBDoc Type
-
8/10/2019 Crm Middleware1
73/91
India SAP CoE, Slide 73
Enhance mBDoc Type
Structure : BUS_EI_EXTERN
Enhance mBDoc Type
-
8/10/2019 Crm Middleware1
74/91
India SAP CoE, Slide 74
Enhance mBDoc Type
Structure : BUS_EI_CENTRAL_DATA
Enhance mBDoc Type
-
8/10/2019 Crm Middleware1
75/91
India SAP CoE, Slide 75
Enhance mBDoc Type
Structure: Append Structure of
ZBUS_EI_BUPA_CENTRAL_DATA
Implement user exit in R/3 adapter inbound
-
8/10/2019 Crm Middleware1
76/91
India SAP CoE, Slide 76
Implement user exit in R/3 adapter, inbound
direction (CRM)
Create function module Z_USER_EXIT_BAPI_CRM_SAVEPseudo Code:
Check whether Exit was called during Download
Check E_BAPICRMDH2-REF_ID is initial and
BAPICRMDH2-DWNLOADTYP is D
Check Object Name (Business Transaction) is BUPA_MAIN orCUSTOMER_MAIN
Define a macro to get full Unicode support
Move MESSAGE_EXT to BUS_EI_MAIN (structure).
Process TI_BAPIMTCS with condition TABNAME as
'ZCONTINENT' . Process BUS_EI_MAIN with condition
header-object_instance-bpartnerguid = ti_bapimtcs-objkey
Assign the value to data-ZZCOUNT field
Implement User Exit in R/3
-
8/10/2019 Crm Middleware1
77/91
India SAP CoE, Slide 77
Implement User Exit in R/3
Parameters of the Function Module:
Z_USER_EXIT_BAPI_CRM_SAVE
Register user exit (CRM)
-
8/10/2019 Crm Middleware1
78/91
India SAP CoE, Slide 78
Register user exit (CRM)
Parameter ValueProduct ZCRM
Text User Exits in MW adapter
RFC Destination Initial
Active X
Table maintenance: TBE24
Register user exit (CRM)
-
8/10/2019 Crm Middleware1
79/91
India SAP CoE, Slide 79
Register user exit (CRM)
Parameter Value
Process SMOUTIL3
Country Initial
Application Initial
Function Module Z_USER_EXIT_BAPI_CRM_SAVE
Product ZCRM
Table maintenance: TPS34
-
8/10/2019 Crm Middleware1
80/91
-
8/10/2019 Crm Middleware1
81/91
Register validation functionality
-
8/10/2019 Crm Middleware1
82/91
India SAP CoE, Slide 82
Register validation functionality
Parameter Value
Event CRMIN
Object BUPA or Business Partner
Item Enter a 6-figure item number
greater than existing entriesFunction Module Z_CRMIN_APPEND_FIELDS
Call Tick the check-box
Table maintenance: CRMC_BUT_CALL_FU
Start Initial load
-
8/10/2019 Crm Middleware1
83/91
India SAP CoE, Slide 83
Start Initial load
Transaction:r3as
Middleware Enhancement
-
8/10/2019 Crm Middleware1
84/91
India SAP CoE, Slide 84
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
Middleware Enhancement
Exercises
-
8/10/2019 Crm Middleware1
85/91
India SAP CoE, Slide 85
Exercises
Create a custom table with 2 fields in ERP side and get it
replicated in CRM with some validations.
Middleware Enhancement
-
8/10/2019 Crm Middleware1
86/91
India SAP CoE, Slide 86
1 PrepareMe
2 TellMe
3 ShowMe
4 LetMe
5 HelpMe
Middleware Enhancement
HelpMe
-
8/10/2019 Crm Middleware1
87/91
India SAP CoE, Slide 87
HelpMe
Tips and Tricks
Additional Info
Tips and Tricks
-
8/10/2019 Crm Middleware1
88/91
India SAP CoE, Slide 88
Tips and TricksIn inbound Queue (Tcode SMQ2 in CRM as the CRM is the inbound to this
process) if the process of initial load is successful you will not find your entry
in this.
If your adapter object is in the list of adapter object queues, to know
the details of the queue, double click on the adapter object.
Tips and Tricks
-
8/10/2019 Crm Middleware1
89/91
India SAP CoE, Slide 89
Tips and Tricks
Double click on the corresponding status to find the description of the Error
Double Click
Tips and Tricks
-
8/10/2019 Crm Middleware1
90/91
India SAP CoE, Slide 90
Tips and Tricks
To monitor all the queue objects go with the tcode SMWP
CRM Middleware monitoring cockpit
-
8/10/2019 Crm Middleware1
91/91