Professional Documents
Culture Documents
SLT Config
SLT Config
Unrestricted change data capturing Robust and proven architecture with *SAP Customer Activity Repository
*SAP HANA Live
with almost zero impact more than 4400 customers *SAP High Performance Applications
*Suite Accelerator and more apps
SAP Landscape Transformation Replication Server
Product description
SAP LT Replication Server (aka ‘SLT’) is a standard software to move data in real-time between different systems within the same network,
wide area networks, or into the cloud to have the information at the right place at the right point of time.
The software helps to feed analytical systems with up-to-date business information from the productive system landscape, support the
acceleration of large volume transactions executed in SAP HANA, enables real-time reporting and minimizes transfer volume for SAP BW and
enables the synchronization between different systems.
Replication
Real-time or scheduled
Delta capturing to minimize transfer volume
Transformation
Filtering by using selective criteria
Adjustment of tables
Conversion of data, e.g. to make sensitive data
anonymous
Installation & operation
Deeply integrated within SAP landscapes to reuse
existing installation and monitoring capabilities
Monitoring with SAP Solution Manager 7.1 SP5
onwards
Execute transaction LTR in the SLT system to open the Configuration and Monitoring Dashboard
Use File to
download your
settings or upload All configuration are listed in the
the settings to overview area. You can choose
exchange from the configuration that needs some
Dev/QA to adjustments.
productive
systems.
Navigate back to
the Overview
sections
To define special settings for a table, just right-click on the required section and add the table:
• Performance Options: You would like to change the reading type to improve the load
Assign templates to • Rule Assignment: You would like to filter on a specific field
single tables or all
• Table Settings: You would like to adjust the target table structure
tables of the
• Trigger Options: You would like set a filter direct on the trigger in the source system
configuration
Expert Filtering
• Initial Load Filter
• Trigger Options
• Views
Per default, the SAP LT Replication Server loads and replicates all data of the defined tables. Client specific tables are also
loaded and replicated completely and not restricted to a certain client. Data load can be restricted by define some filter rules
(described in the following slides) or by activating the client specific load and replication.
Prerequisites:
• Load / replication should be restricted to a single client
(To restrict a load to multiple but not all clients, individual filter rules need to be defined)
• RFC Destination to the source system points to the relevant
client (relevant client is derived from RFC connection)
Result:
• DB trigger are defined in a way that they only record changes from relevant client
• Data that is loaded and replicated is restricted to the client defined in the RFC destination
Expert Filtering
• Initial Load Filter
• Trigger Options
• Views
You have to open the Table Settings folder and double-click on Global Mapping Values. Choose the add icon and input the Data Type you want
to change and the Target DB Type you want to use for all tables in this configuration.
For each table and table field you can redefine the Global Mapping Values. You find more details in the next chapter.
Rule Assignment
• Field-related Rules
• Event-related Rules
Expert Filtering
• Initial Load Filter
• Trigger Options
• Views
Under Table Settings, you can change the settings for a target table.
By default, the table created in the target system will have the same name
and structure as the source table. However, it might be necessary to
change the name or alter the table structure depending on your
requirements. For instance, tables from different sources could be
replicated to one target system, some table fields might have become
obsolete, or several fields could be combined into one field.
You can specify a new table name can be entered in the Deviating Table Name field.
Modifications to the table structure can be achieved in two different ways. At first, you can use a different ABAP Dictionary
table (could be a copy of the existing table structure with adjusted fields). This type must be defined in either the source
system or in the SAP LT Replication Server system.
You enter the type in the Structure Template field. The second way to change the target structure is to define changes in
the Table Structure tab page. Note that both methods for changing a table structure can be used at the same time.
If a different ABAP Dictionary data type is defined, this type will be used as a starting point for modifications using the
Table Structure tab page.
The Table Store field indicates how the data is stored in the target database. Data can be stored in columns (the default
setting), or rows. The third option is History Column Store. If you select this option, the system records every change to the
source table with a timestamp.
In the Partition Command field, you can specify a partition command for when the target table is created in the target system.
The code that you specify here is executed when the table is created in the target system. You can use the partition
command to split the target table into several smaller packages. For example, 'PARTITION BY HASH (MANDT, CARRID)
PARTITIONS 4' would create the table with four hash partitions selected by the fields Client (mandt) and CARRID.
The size of read portions is the number of entries in one portion during the initial load for the default reading type DB_SETGET. It has no effect
for other reading types, for example access plan, or for delta replication. For delta replication, up to 5000 entries are selected in one portion.
Refresh Behavior
If a table is available in the target system, you can recreate the table (for example if you want to reuse the structure of the table).
To do this, you can choose one of the following options in the Refresh Behavior field:
Default - The system drops the target table completely (structure and data). The system recreates the tables again based on the configuration.
No Action - If the table exists in the target system it is used for the replication; no change to the structure or the data is made
Drop - Choose this option if you want to drop the target table completely (structure and data). The system recreates the tables again based on the
configuration.
Truncate - This option preserves the structure, but removes all data from the table.
You can make changes to the target table structure in the Table Structure tab page. You
can view the existing table structure and the new table structure side by side.
With this option you can minimize the target table to save memory or you can enhance it to fill the
additional field with a transformation rule on the fly. Data type changes could be required if you plan
to fill a field with additonal values or another data type is expected by the target application.
Change a field
You can change the characteristics of a field. To do this, select a field and choose the Edit pushbutton. For example you can change the position of the field in
the table, or the length of the field.
Remove a field
You can remove a field from the table. To do this, select a field and choose the Remove pushbutton.
You can also change multiple fields at the same time. To do the
select the relevant fields, and choose the Mass Change
pushbutton. You can change the data type, length, and decimal
places for multiple fields. You can also remove multiple fields
from the table by choosing the Mass Change pushbutton, and
then specifying the fields that you want to remove.
You can view the modified table structure by choosing the View Modified Table Structure pushbutton. All modifications, that is, the
ABAP Dictionary type and changes made in tab page Table Structure, are considered and the system displays the new structure.
The default type mapping can be redefined for each configuration on table level. The individual type mapping for a
table can be defined in Mapping Values and will affect only the table. These settings will win against the Global
Mapping Values.
FLDATE was the only field with data type DATS. It was changed into DATE.
If you only want to have a single field changed from e.g. from DATS to DATE, just use the Table Fields mapping. The Target
DB Types has to be specified as a string (for example DAYDATE CS_DAYDATE).
You can choose Create Table to get a preview which SQL statement will be executed to create the table on SAP
HANA. The result after all changes is illustrated on the right screenshot. You see that the target table name was
changed to ZSFLIGHT_TEST, SID field was added as a key field and the field NEWFIELD_1 was removed.
Can we recalculate
some fields on the fly
SAP LT
SAP
ABAP/ non-ABAP system
Replication Server HANA
Replication only:
Apply filter criteria directly for DB trigger via LTRS (Trigger
Option) on SLT system.
The data for transformation will be split into portions (default: load: 10,000 lines, replication: 5,000 lines)
The portions will be processed successively, mapped, and transferred to sender
Extension of functionality (for example data conversion) is possible at several points of the process
Implementation of filter or data transformation as ABAP coding
A rule can filter or transform data during the load an replication process. Choose Rule
Assignment and add the relevant table. A new user interface will appear and you can create
a new rule for the table.
Event-Related Rule
• More flexible
• Knowledge of data processing within the SAP LT Replication Server
needed to select the right event for the specific business scenario
• Has access to all fields of a record
Field-Related Rule
• Less flexible
• Easy to create by using parameters
Filter Rule
Within the table we have several carriers like Lufthansa (LH), American Airlines (AA) and many
more.
We only want to move the data from carrier Lufthansa (CARRID = “LH”) to SAP HANA
After you confirmed you will see a new entry for a Field-Related Rule.
Double-click on the rule in the Rule Overview section, so that the
relevant data is displayed below.
© 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 32
Rule Assignment – Field-Related Rule
Will be performed after the record is mapped to the receiver structure and before it will be added to the sender portion.
Import Parameters
Are used within ABAP-code to apply values, which were determined in Advanced Replication Settings
If no parameter has to be used within the rule, IMP_PARAM_1 has to be set to ‘DUMMY’!
Values of fields of the sender record will be addressed in the include using the following name:
IMPORT PARAMETER 1: i_<fieldname>_1 (for example, i_mandt_1)
IMPORT PARAMETER 2: i_<fieldname>_2
IMPORT PARAMETER 3: i_<fieldname>_3
Export Parameter
Specifies the fieldname of the receiver structure, which has to be filled within the parameter rule
Addressed in the include using the following name:
EXPORT PARAMETER: e_<fieldname> (for example, e_mandt).
As the import value we choose a text literal ‘RK3’ (do not miss the ‘’). This value should be
inserted into the SID field for all records.
This small piece of code can be defined directly in the Line of Code:
E_SID = I_P1.
Do not forget the spaces before and after the `=` and the fullstop at the end. Do not forget to
save the rule afterwards.
We find 13 entries in the source table including all By the filter on Lufthansa we reduced the records to
carriers like Air Canada (AC) and Air France (AF). 10. In addition we filled the SID field with the value
‘T40’.
Start Load / Replication Can be used to initialize certain global fields that might be used in subsequent events (for example, fill
internal mapping tables)
BOP – Begin of Processing
EOP (End of Processing):
DO
Get next portion from source system Processed only once, after the data transfer is completed.
LOOP AT source Access to all data records of a portion read from the sender system
BOL – Begin of Loop EOT (End of Block):
MOVE-CORRESPONDING Access to all data records immediately before they are passed to the receiver system
source To target BOL (Begin of Loop):
BOR – Begin of Record Like BOT if only one table is included in the conversion object; in case of objects with multiple tables, it can
individual field mapping be applied to each specific table
EOP – End of processing This event is processed after the field mapping of the individual fields of a certain data record has finished.
In this example we created the include Z_RULE where we specify the rule. You can create it within
transaction SE38 or SE80 and specify the name in the field Include Name.
This small piece of code can be defined in the include :
<wa_r_zsflight_01>-sid = ‘T40'.
Do not forget the spaces between and the full stop. Do not forget to save and activate the include afterwards.
© 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 42
Rule Assignment – Event-Related Rule
You can reuse the existing include to specify also the filter code.
IF <wa_s_zsflight_00>-carrid NE 'LH'.
SKIP_RECORD.
ELSE.
Do not forget the spaces between and the full stop. Do not forget to save and activate the include afterwards.
© 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 43
Rule Assignment – Field-Related Rule
We find 13 entries in the source table including all By the filter on Lufthansa we reduced the records to
carriers like Air Canada (AC) and Air France (AF). 10. In addition we filled the SID field with the value
‘T40’.
Expert Filtering
• Initial Load Filter
• Trigger Options
• Views
Use Case
You don't want to load the entire source table but a filter on the SLT is not the optimal solution as most of the data is transferred to the SLT system
and skipped here. In case you filter a significant part of a table it's better to already limit the reader module of the initial load accordingly.
Process
With DMIS 2011 SP6 a new table is available where Filter for the Initial Load and / or settings to parallelize the replication can be defined. The
entries in table DMC_ACSPL_SELECT have to be defined on the SLT systems.
Use Case
SLT is capturing all updates, inserts and deletes for a table that is in replication. If you expect a very high change rate on the table, but your use
case requires only a subset of the records, you could minimize the replication volume by a trigger filter.
Process
Within the Trigger Options in LTRS you can specify a trigger code that will be added when SLT creates the DB trigger on the source system.
Ensure that the trigger condition is correct. The trigger option is a expert function, the code is database-specific. Keep in mind that with wrong
settings you can harm your source system.
Field Action
DBSYS Enter the database type of the source system.
LINE_NO You can specify multiple lines if the condition is too complex to be filled in only one line.
LINE Enter the trigger condition here. Only when the data change fulfills the condition , it will be recorded into the
logging table for the SLT replication.
In this example, we want to customize the trigger directly in the source system
in a way that only changes to the data with CARRID = ‘LH’ will be recorded.
Table A
Table A
In the SLT system you have to assign the new view to the table. Add
the table under Table Settings and assign the view in the
Processing Settings of the table. You may assign the view for both
initial load and replication.
You can add a deviating table name, meaning that the table is
created with this new name in the target system. This helps to show
that a table is modified.
+
Table A
Create table deviation of table A with
Table A 2 fields of B, load/replicate from view C
Table B
ABAP Workbench
Create
With a Database View you can join fields of tables to a leading table. Create a
new view in the ABAP Workbench and join the leading table with the dependent
table on the Join Conditions tab.
Define which fields should be filled in the target. After the activation of the view
you can display the table content and check the functionality of the view.
For Views, the reading type has to be set to 5 in the Performance Options of the leading table.
If you create a view an choose it as template for the table you want to replicate, you can change the field names and only create the fields you want
to fill in the target. Again we have entered a deviating table name.