Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

SAP HANA EIM Installation and Configuration Guide en

Download as pdf or txt
Download as pdf or txt
You are on page 1of 598

PUBLIC

SAP HANA Smart Data Integration and SAP HANA Smart Data Quality 2.0 SP03
Document Version: 1.0 – 2020-05-30

Installation and Configuration Guide


© 2020 SAP SE or an SAP affiliate company. All rights reserved.

THE BEST RUN


Content

1 Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP HANA
Smart Data Quality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.1 Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.2 Architecture. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
1.3 Components to Install, Deploy, and Configure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.4 Deployment Options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Deployment in High Availability Scenarios. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16
Deployment with SAP HANA Cloud. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Deployment with the SAP HANA Service. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
1.5 Administration Tools. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

2 Configure Smart Data Integration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24


2.1 Assign Roles and Privileges. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
2.2 Configure the Data Provisioning Server. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Enable the Server in a Multi-database Container Scenario. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Enable the Server in a Scale-out SAP HANA Database Scenario. . . . . . . . . . . . . . . . . . . . . . . . . 32
Enable the Server for the SAP HANA Service. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
2.3 Download and Deploy the Data Provisioning Delivery Unit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Download the Data Provisioning Delivery Unit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
Deploy the Delivery Unit from SAP HANA Studio. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .35
Deploy the Delivery Unit from SAP HANA Application Lifecycle Management. . . . . . . . . . . . . . . .35
2.4 Install the Data Provisioning Agent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .36
Planning and Preparation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
Install the Data Provisioning Agent. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Manage Agents from the Data Provisioning Agent Monitor. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
2.5 Configure the Data Provisioning Agent. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
Configuring the Agent in Command-Line Interactive Mode. . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
Configuring the Agent in Command Line Batch Mode. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Configuring the Agent in Graphical Mode [Deprecated]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Managing Agent Groups. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
Manage Agents from the Data Provisioning Agent Monitor. . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
Agent Adapter Framework Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104
Agent Runtime Options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .108
Replicating an Agent Configuration to Another Host. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .110
2.6 Register Data Provisioning Adapters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .111
Register Adapters with SAP HANA. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
Register Adapters with SAP HANA [Command Line]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .114

Installation and Configuration Guide


2 PUBLIC Content
Manage Adapters from the Data Provisioning Agent Monitor. . . . . . . . . . . . . . . . . . . . . . . . . . . 115
2.7 Create a Remote Source. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
Create a Remote Source in the Web-Based Development Workbench . . . . . . . . . . . . . . . . . . . . 118
Create a Remote Source in the SQL Console. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
Create Credentials for a Secondary User. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120
Configure a Grantor for the HDI Container. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
2.8 Set Up Data Provisioning Monitoring. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Grant Roles to Users . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
2.9 Enabling Enterprise Semantic Services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Setting Up the SAP HANA Instance for Enterprise Semantic Services. . . . . . . . . . . . . . . . . . . . 126
Download Enterprise Semantic Services Delivery Unit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
Importing the Enterprise Semantic Services Delivery Unit. . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
Install or Upgrade Enterprise Semantic Services (install.html) . . . . . . . . . . . . . . . . . . . . . . . . . 130
Grant Enterprise Semantic Services Roles and Privileges to Users . . . . . . . . . . . . . . . . . . . . . . 132
Uninstall Enterprise Semantic Services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
2.10 Enable SAP HANA Smart Data Integration REST API. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .133

3 Configure Smart Data Quality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135


3.1 Directories. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
Install or Update Directories on the SAP HANA Host Using Lifecycle Manager. . . . . . . . . . . . . . 136
Install or Update Directories from a Web Browser Using Lifecycle Manager. . . . . . . . . . . . . . . . 138
Integrate Existing Directories into Lifecycle Manager. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
Uninstall Directories. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144

4 Update Smart Data Integration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145


4.1 Update the Data Provisioning Agent. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
4.2 Install or Upgrade Enterprise Semantic Services (install.html) . . . . . . . . . . . . . . . . . . . . . . . . . . . 148

5 Uninstall Smart Data Integration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150


5.1 Uninstall the Data Provisioning Agent. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150
5.2 Uninstall Enterprise Semantic Services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152

6 Configure Data Provisioning Adapters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .153


6.1 Configure Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
Configure Adapter Preferences in Discrete Command Mode. . . . . . . . . . . . . . . . . . . . . . . . . . . 157
6.2 Custom Adapters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
6.3 Apache Camel Facebook. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
Set up the Camel Facebook Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .158
Camel Facebook Adapter Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .159
6.4 Apache Camel Informix. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160
Set Up the Camel Informix Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
Camel Informix Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .162
6.5 Apache Camel JDBC. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163

Installation and Configuration Guide


Content PUBLIC 3
Set up the Camel JDBC Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
Camel JDBC Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .166
Connect to MySQL Using the Camel JDBC Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
6.6 Apache Camel Microsoft Access. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169
Set Up the Camel Microsoft Access Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170
Microsoft Access Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170
6.7 Apache Cassandra. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .172
Cassandra SSL Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
Enable Kerberos Authentication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
Cassandra Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
6.8 Apache Impala. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
Apache Impala Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
Kerberos Realm and KDC. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
6.9 File. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .187
Configure the File Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .189
File Adapter Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
Configuration Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198
Remote Source Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
Connect to a SharePoint Remote Source. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
Access SharePoint Using HTTPS/SSL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
Accessing Files On a Shared Network. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft
Office365. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
Configure Your Microsoft Azure Application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221
6.10 File Datastore Adapters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
Authorizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .223
Configuring Access to Your Data and Configuration Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
File Format Configuration Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
Format Parameters for File Datastore Adapters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Virtual Procedures. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
FileAdapterDatastore. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
SFTPAdapterDatastore. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
6.11 Hive. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .244
Understanding Hive Versions, Features, and JAR Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
Hive Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
Kerberos Debugging. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
6.12 IBM DB2 Log Reader. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254
IBM DB2 Real-time Replication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256

Installation and Configuration Guide


4 PUBLIC Content
DB2LogReaderAdapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
DB2 Log Reader Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
Using a Schema Alias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .277
Log Reader Adapter Log Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
Configure SSL for the DB2 Log Reader Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .278
Creating a Whitelist to Limit Access to a Source Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
6.13 IBM DB2 Mainframe. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
Setting DB2 Universal Database Environment Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .284
IBM DB2 Mainframe Permissions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
Bind the DB2 SYSHL Package. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
Preparing JDBC JAR Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
IBM DB2 Mainframe Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
6.14 Microsoft Excel. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
Microsoft Excel Authorizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
Microsoft Excel Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
Microsoft Excel Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
Access SharePoint Using HTTPS/SSL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
Accessing Microsoft Excel Data Files in a Shared Network Directory . . . . . . . . . . . . . . . . . . . . .296
Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft
Office365. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297
Configure Your Microsoft Azure Application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 298
6.15 Microsoft Outlook. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
Microsoft Outlook Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
Microsoft Outlook Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
6.16 Microsoft SQL Server Log Reader. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301
Microsoft SQL Server Real-time Replication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303
MssqlLogReaderAdapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322
Microsoft SQL Server Log Reader Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . 325
Using a Schema Alias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
Log Reader Adapter Log Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
Configure SSL for the Microsoft SQL Server Log Reader Adapter. . . . . . . . . . . . . . . . . . . . . . . 338
Configuring Windows Authentication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .340
Creating a Whitelist to Limit Access to a Source Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
Configure Microsoft Windows Authentication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 343
6.17 OData. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
Installation and Deployment. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 345
Consume HTTPS OData Services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348
6.18 Oracle Log Reader. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
Oracle Database Permissions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352

Installation and Configuration Guide


Content PUBLIC 5
Oracle Real-time Replication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
OracleLogReaderAdapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
Oracle Log Reader Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
Using a Schema Alias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
Oracle RAC Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 387
Amazon Web Services Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .389
Log Reader Adapter Log Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 390
Synchronize the Oracle and Data Provisioning Agent Timestamp. . . . . . . . . . . . . . . . . . . . . . . 390
Configure SSL for the Oracle Log Reader Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
Creating a Whitelist to Limit Access to a Source Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 395
6.19 PostgreSQL Log Reader. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .396
Configure PostgreSQL Source for Real-time Replication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .397
PostgreSQL Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 398
Amazon Web Services Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
Using a Schema Alias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 402
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 403
PostgreSQL DDL Replication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .404
6.20 SAP ABAP. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 405
Authorizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 406
Using RFC Streaming With Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 412
SAP ABAP Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
SAP ABAP Adapter Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
6.21 SAP ASE. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
Configure Your SAP ASE Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 420
SAP ASE Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421
SAP ASE Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 422
6.22 SAP ECC. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 424
Terminology. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
Installation and Setup. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
SAP ECC Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .427
Permissions for ECC Dictionary Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .436
Create an ECC Remote Source. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 436
SAP ECC Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
Creating a Whitelist to Limit Access to a Source Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . 439
SQL Pushdown for Pooled and Cluster Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 440
Loading Metadata for Cluster and Pooled Tables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 441
6.23 SAP HANA. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
User Permissions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .444
SAP HANA Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444
SAP HANA Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444

Installation and Configuration Guide


6 PUBLIC Content
SAP HANA DDL Propagation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .456
Use a Shadow Remote Source. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .457
Creating a Whitelist to Limit Access to a Source Database. . . . . . . . . . . . . . . . . . . . . . . . . . . . 458
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 459
6.24 SDI DB2 Mainframe. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460
SDI DB2 Mainframe Adapter Architecture. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462
Mandatory Changes on Mainframe Systems. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .463
Install the SDI DB2 Mainframe Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
SDI DB2 Mainframe Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
Install Replication Agent for SDI DB2 Mainframe Adapter. . . . . . . . . . . . . . . . . . . . . . . . . . . . .467
Replication Agent for SDI DB2 Mainframe Adapter Configuration. . . . . . . . . . . . . . . . . . . . . . . 470
Change the OCS Server Port Number Using Command-Line Utility. . . . . . . . . . . . . . . . . . . . . . 472
Preparing JDBC JAR Files. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 473
IBM DB2 Mainframe Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 473
6.25 SOAP. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .478
SOAP Adapter Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
Setting up the SOAP Adapter: SQL Example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 480
6.26 Teradata. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .481
Authentication and User Privileges. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
Teradata Adapter Preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
Teradata Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
Disable Adapter Write-back Functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .490
6.27 Twitter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 491
Installation and Deployment. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 493
Twitter Remote Source Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 495

7 Security. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497
7.1 Authentication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497
7.2 Configuring SSL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 498
Configure SSL for SAP HANA (CA). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 500
Configure SSL for SAP HANA (Self-Signed). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 505
Configure SSL for SAP HANA On-Premise [Command Line Batch]. . . . . . . . . . . . . . . . . . . . . . 509
Connect to SAP HANA On-Premise with SSL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .512
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent
Configuration Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 513
Change the Agent Configuration Tool SSL Settings. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 515
Reconfigure an Existing Agent for SSL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516
Troubleshoot the SSL Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 517
7.3 Update JCE Policy Files for Stronger Encryption. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 518
7.4 Authorizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 519
Activating and Executing Task Flowgraphs and Replication Tasks. . . . . . . . . . . . . . . . . . . . . . . 520
7.5 Communication Channel Security. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 520

Installation and Configuration Guide


Content PUBLIC 7
7.6 Auditing Activity on SAP HANA Smart Data Integration Objects. . . . . . . . . . . . . . . . . . . . . . . . . . . 521
7.7 Data Protection and Privacy in SAP HANA Smart Data Integration and SAP HANA Smart Data
Quality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 522

8 SQL and System Views Reference for Smart Data Integration and Smart Data Quality. . . . . . 523
8.1 SQL Statements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 523
ALTER ADAPTER Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .525
ALTER AGENT Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .527
ALTER REMOTE SOURCE Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . 528
ALTER REMOTE SUBSCRIPTION Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . 532
CANCEL TASK Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 533
CREATE ADAPTER Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 535
CREATE AGENT Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 537
CREATE AGENT GROUP Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . 539
CREATE AUDIT POLICY Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . 540
CREATE REMOTE SOURCE Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . 542
CREATE REMOTE SUBSCRIPTION Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . 543
CREATE VIRTUAL PROCEDURE Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . 548
DROP ADAPTER Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 550
DROP AGENT Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 551
DROP AGENT GROUP Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . 552
DROP REMOTE SUBSCRIPTION Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . 553
GRANT Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .554
PROCESS REMOTE SUBSCRIPTION EXCEPTION Statement [Smart Data Integration]. . . . . . . . 556
SESSION_CONTEXT Function [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .557
START TASK Statement [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 558
8.2 System Views. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
ADAPTER_CAPABILITIES System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . 564
ADAPTER_LOCATIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . .565
ADAPTERS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 565
AGENT_CONFIGURATION System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . 566
AGENT_GROUPS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566
AGENTS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566
M_AGENTS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567
M_REMOTE_SOURCES System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . 568
M_REMOTE_SUBSCRIPTION_COMPONENTS System View [Smart Data Integration]. . . . . . . . 568
M_REMOTE_SUBSCRIPTION_STATISTICS System View [Smart Data Integration]. . . . . . . . . . . 569
M_REMOTE_SUBSCRIPTIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . 570
M_SESSION_CONTEXT System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . .571
REMOTE_SOURCE_OBJECT_COLUMNS System View [Smart Data Integration]. . . . . . . . . . . . 572
REMOTE_SOURCE_ OBJECT_DESCRIPTIONS System View [Smart Data Integration]. . . . . . . . 572
REMOTE_SOURCE_OBJECTS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . 573

Installation and Configuration Guide


8 PUBLIC Content
REMOTE_SOURCES System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . 573
REMOTE_SUBSCRIPTION_EXCEPTIONS System View [Smart Data Integration]. . . . . . . . . . . . 574
REMOTE_SUBSCRIPTIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . 575
TASK_CLIENT_MAPPING System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . 575
TASK_COLUMN_DEFINITIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . 576
TASK_EXECUTIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . 576
TASK_LOCALIZATION System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . .577
TASK_OPERATIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . 578
TASK_OPERATIONS_EXECUTIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . 578
TASK_PARAMETERS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . 579
TASK_TABLE_DEFINITIONS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . 580
TASK_TABLE_RELATIONSHIPS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . 581
TASKS System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 581
VIRTUAL_COLUMN_PROPERTIES System View [Smart Data Integration]. . . . . . . . . . . . . . . . . 582
VIRTUAL_TABLE_PROPERTIES System View [Smart Data Integration]. . . . . . . . . . . . . . . . . . . 583
BEST_RECORD_GROUP_MASTER_STATISTICS System View [Smart Data Quality]. . . . . . . . . . 583
BEST_RECORD_RESULTS System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . 584
BEST_RECORD_STRATEGIES System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . 585
CLEANSE_ADDRESS_RECORD_INFO System View [Smart Data Quality]. . . . . . . . . . . . . . . . . 586
CLEANSE_CHANGE_INFO System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . 587
CLEANSE_COMPONENT_INFO System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . .588
CLEANSE_INFO_CODES System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . 589
CLEANSE_STATISTICS System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . 590
GEOCODE_INFO_CODES System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . 591
GEOCODE_STATISTICS System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . 592
MATCH_GROUP_INFO System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . . 592
MATCH_RECORD_INFO System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . 593
MATCH_SOURCE_STATISTICS System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . 594
MATCH_STATISTICS System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 594
MATCH_TRACING System View [Smart Data Quality]. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 595

Installation and Configuration Guide


Content PUBLIC 9
1 Installation and Configuration Guide for
SAP HANA Smart Data Integration and
SAP HANA Smart Data Quality

This guide describes the main tasks and concepts necessary for the initial installation and configuration of SAP
HANA smart data integration and SAP HANA smart data quality.

For information about the capabilities available for your license and installation scenario, refer to the Feature
Scope Description (FSD) for your specific SAP HANA version on the SAP HANA Platform page.

This guide includes the following content:

● Architecture, components, deployment, and tools


● Configuration tasks to enable functionality
● Configuring data provisioning adapters
● Security
● SQL syntax and system views

For information about the ongoing administration and operation of SAP HANA smart data integration and SAP
HANA smart data quality, refer to the Administration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality.

For information about administration of the overall SAP HANA system, refer to the SAP HANA Administration
Guide.

Related Information

Overview [page 10]


Architecture [page 12]
Components to Install, Deploy, and Configure [page 14]
Deployment Options [page 15]
Administration Tools [page 23]
SAP HANA Administration Guide for SAP HANA Platform
Administration Guide for SAP HANA Smart Data Integration and SAP HANA Smart Data Quality

1.1 Overview
SAP HANA smart data integration and SAP HANA smart data quality provide tools to access source data and
provision, replicate, and transform that data in SAP HANA on-premise or in the cloud.

SAP HANA smart data integration and SAP HANA smart data quality let you enhance, cleanse, and transform
data to make it more accurate and useful. You can efficiently connect to any source to provision and cleanse

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
10 PUBLIC HANA Smart Data Quality
data for loading into SAP HANA on-premise or in the cloud, and for supported systems, writing back to the
original source.

Capabilities include:

● A simplified landscape; that is, one environment in which to provision and consume data
● Access to more data formats including an open framework for new data sources
● In-memory performance, which means increased speed and decreased latency

Feature area Description

SAP HANA smart data Real-time, high-speed data provisioning, bulk data movement, and federation. Provides built-in
integration adapters plus an SDK so you can build your own adapters.

Includes the following features and tools:

● Replication Editor in SAP Web IDE and SAP HANA Web-based Development Workbench or
Web IDE, which lets you set up batch or real-time data replication scenarios in an easy-to-
use web application
● Transformations presented as nodes in SAP Web IDE and SAP HANA Web-based Develop­
ment Workbench, which let you set up batch or real-time data transformation scenarios
● Data Provisioning Agent, a lightweight component that hosts data provisioning adapters,
enabling data federation, replication, and transformation scenarios for on-premise or in-
cloud deployments
● Data Provisioning adapters for connectivity to remote sources
● An Adapter SDK to create custom adapters
● Monitors for Data Provisioning Agents, remote subscriptions, and data loads

SAP HANA smart data Real-time, high-performance data cleansing, address cleansing, and geospatial data enrich­
quality ment. Provides an intuitive interface to define data transformation flowgraphs in SAP Web IDE
and SAP HANA Web-based Development Workbench.

New Features Delivered in Patches

This guide introduces you to features delivered in SAP HANA smart data integration and SAP HANA smart data
quality 2.0 Service Packs only. For information about features delivered in subsequent patches, as well as other
information, such as fixed and known issues, refer to the SAP Note for each of the relevant patches. The
Central SAP Note for SAP HANA smart data integration and SAP HANA smart data quality is the best place to
access this information, with links to the SAP Notes for every Service Pack and Patch.

Related Information

Central SAP Note for SAP HANA smart data integration and SAP HANA smart data quality

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 11
1.2 Architecture

These diagrams represent common deployment architectures for using smart data integration and smart data
quality with SAP HANA.

In all deployments, the basic components are the same. However, the connections between the components
may differ depending on whether SAP HANA is deployed on-premise, in the cloud, or behind a firewall.

Figure 1: SAP HANA deployed on-premise

Figure 2: SAP HANA deployed in the cloud or behind a firewall

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
12 PUBLIC HANA Smart Data Quality
The following tables explain the diagram and the network connections in more detail.

Outbound Connections

Client Protocol and Additional Information Default Port

Data Provisioning Agent When SAP HANA is deployed on-premise, the 5050
Data Provisioning Server within SAP HANA con­
nects to the agent using the TCP/IP protocol.

To manage the listening port used by the agent,


edit the adapter framework preferences with
the Data Provisioning Agent Configuration tool.

Sources The connections to external data sources de­ Varies by source


pend on the type of adapter used to access the
Examples: Data Provisioning Adapters
source.

C++ adapters running in the Data Provisioning


Server and Java adapters deployed on the Data
Provisioning Agent connect to the source using
a source-defined protocol.

Inbound Connections

Client Protocol and Additional Information Default Port

Data Provisioning Agent When SAP HANA is deployed in the cloud or be­ 80xx
hind a firewall, the Data Provisioning Agent con­
nects to the SAP HANA XS engine using the 43xx
HTTP/S protocol.

 Note
When the agent connects to SAP HANA in
the cloud over HTTP/S, data is automati­
cally gzip compressed to minimize the re­
quired network bandwidth.

For information about configuring the port used


by the SAP HANA XS engine, see the SAP HANA
Administration Guide.

Related Information

Configuring the Agent in Graphical Mode [Deprecated] [page 83]

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 13
1.3 Components to Install, Deploy, and Configure

SAP HANA smart data integration and SAP HANA smart data quality include a number of components that you
must install, deploy, and configure.

Within this guide, the steps to install and deploy the components appear in the section Configure [SDI/SDQ].

Component Description

Data Provisioning Server The Data Provisioning Server is a native SAP HANA process. It is built as an index server var­
iant, runs in the SAP HANA cluster, and is managed and monitored just like other SAP HANA
services. It provides out-of-the-box native connectivity for many sources and connectivity to
the Data Provisioning Agent.

The Data Provisioning Server is installed with, but must be enabled in, the SAP HANA
Server.

Data Provisioning Agent The Data Provisioning Agent is a container running outside the SAP HANA environment, and
it is managed by the Data Provisioning Server. It provides connectivity for all those sources
where the driver cannot run inside the Data Provisioning Server. Through the Data Provi­
sioning Agent, the preinstalled Data Provisioning Adapters communicate with the Data Pro­
visioning Server for connectivity, metadata browsing, and data access. The Data Provision­
ing Agent also hosts custom adapters created using the Adapter SDK.

The Data Provisioning Agent is installed separately from SAP HANA server or client.

HANA_IM_DP delivery unit The HANA_IM_DP delivery unit bundles monitoring and administration capabilities and the
Data Provisioning Proxy for connecting to SAP HANA in the cloud.

The delivery unit includes the Data Provisioning administration application, the Data Provi­
sioning Proxy, and the Data Provisioning monitor.

Data Provisioning adminis­ The Data Provisioning administration application is an XS application that manages the ad­
tration application ministrative functions of the Data Provisioning Agent with SAP HANA in the cloud.

This component is delivered via the HANA_IM_DP delivery unit.

Data Provisioning Proxy The Data Provisioning Proxy is an XS application that acts as a proxy to provide communica­
tion between the Data Provisioning Agent and the Data Provisioning Server when SAP HANA
runs in the cloud. When SAP HANA is in the cloud, the agent uses HTTP(S) to connect to
the Data Provisioning Proxy in the XS Engine, which eliminates the need to open more ports
in corporate IT firewalls.

This component is delivered via the HANA_IM_DP delivery unit.

Data Provisioning monitor The Data Provisioning monitor is a browser-based interface that lets you monitor agents,
tasks, and remote subscriptions created in the SAP HANA system. You can view the moni­
tors by entering the URL of each monitor into a web browser or by accessing the smart data
integration links in the SAP HANA cockpit, a web-based launchpad that is installed with SAP
HANA Server.

You enable Data Provisioning monitoring functionality for agents, data loads, and remote
subscriptions by creating the statistics tables and deploying the HANA_IM_DP delivery unit.

SAP HANA Web-based Devel­ The SAP HANA Web-based Development Workbench, which includes the Replication Editor
opment Workbench Replica­ to set up replication tasks, is installed with SAP HANA Server.
tion Editor

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
14 PUBLIC HANA Smart Data Quality
Component Description

SAP HANA Web-based Devel­ The SAP HANA Web-based Development Workbench Flowgraph Editor provides an interface
opment Workbench Flow­ to create data provisioning and data quality transformation flowgraphs.
graph Editor

Application function modeler The application function modeler provides an interface to create data provisioning and data
quality transformation flowgraphs.

The application function modeler is installed with SAP HANA studio.

1.4 Deployment Options

Common deployment options for SAP HANA systems, Data Provisioning Agents, and source systems are
described.

There are two common deployment landscapes that we recommend:

Landscape Description

Distributed landscape ● System 1: SAP HANA Server


● System 2: Data Provisioning Agent
● System 3: Source system

Combined landscape ● System 1: SAP HANA Server


● System 2: Data Provisioning Agent and the source system

SAP HANA on premise vs. SAP HANA in the SAP Cloud Platform Neo
Environment

Using SAP HANA on premise or in the cloud is a choice of deployment. Here are some things to keep in mind
when deciding which deployment to use. If your deployment includes SAP HANA in the cloud and a firewall
between SAP HANA and the Data Provisioning Agent:

● The Data Provisioning Proxy must be deployed. To deploy the proxy, download and deploy the
HANA_IM_DP delivery unit.
● The Data Provisioning Agent must be configured to communicate with SAP HANA using HTTP. Configure
the Agent by using the Data Provisioning Agent Configuration tool.

SAP Cloud Platform, SAP HANA Service

If your deployment includes the SAP Cloud Platform, SAP HANA service in the Cloud Foundry environment,
configure the Data Provisioning Agent to connect via JDBC WebSockets.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 15
For more information about connecting to the SAP Cloud Platform, SAP HANA service, see Connect to the SAP
HANA Service via JDBC WebSockets [Command Line] [page 56].

SAP HANA Cloud

If your deployment includes SAP HANA Cloud, configure the Data Provisioning Agent to connect via JDBC.

For more information about connecting to SAP HANA Cloud, see Deployment with SAP HANA Cloud [page
18].

Other deployment considerations

When planning your deployment, keep the following in mind:

● You may not have one Data Provisioning Agent registered in multiple SAP HANA instances.
● You may have multiple instances of the Data Provisioning Agent installed on multiple machines. For
example, a developer may want to have a Data Provisioning Agent installed on their computer to work on a
custom adapter.

Related Information

Deployment in High Availability Scenarios [page 16]


Deployment with SAP HANA Cloud [page 18]
Deployment with the SAP HANA Service [page 21]

1.4.1 Deployment in High Availability Scenarios

In addition to installing SAP HANA in a multiple-host configuration, you can use agent grouping to provide
automatic failover and load balancing for SAP HANA smart data integration and SAP HANA smart data quality
functionality in your landscape.

Auto-failover for the Data Provisioning Server

In a multiple-host SAP HANA system, the Data Provisioning Server runs only in the active worker host. If the
active worker host fails, the Data Provisioning Server is automatically started in the standby host when it takes
over, and any active replication tasks are resumed.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
16 PUBLIC HANA Smart Data Quality
 Note

The Data Provisioning Server does not support load balancing.

For more information about installing SAP HANA in a multiple-host configuration, see the SAP HANA Server
Installation and Update Guide.

Auto-failover for the Data Provisioning Agent

Agent grouping provides automatic failover for connectivity to data sources accessed through Data
Provisioning Adapters.

When an agent that is part of a group is unreachable for a time longer than the configured heart beat time limit,
the Data Provisioning Server chooses a new active agent within the group, and it resumes replication for any
remote subscriptions active on the original agent.

Initial and batch load requests to a remote source configured on the agent group are routed to the first
available agent in the group.

 Restriction

Fail-over is not supported for initial and batch load requests. Restart the initial load following a failure due to
agent unavailability.

Load balancing for the Data Provisioning Agent

Agent grouping provides load balancing for initial loads only.

For example, with multiple agents in the group, you can choose to have the agent for the initial load selected
randomly, or selected from the list of agents in a round-robin fashion.

 Restriction

Load balancing is not supported for change data capture (CDC) operations.

For complete information about configuring agent groups, see the Administration Guide for SAP HANA Smart
Data Integration and SAP HANA Smart Data Quality.

Related Information

SAP HANA Server Installation and Update Guide


Load Balancing in an Agent Group [page 96]
Failover Behavior in an Agent Group [page 95]

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 17
1.4.2 Deployment with SAP HANA Cloud

Understand the landscape and deployment and configuration process when using SAP HANA smart data
integration with SAP HANA Cloud

When you are using SAP HANA Cloud, you can use SAP HANA smart data integration with tools such as SAP
Web IDE on SAP Cloud Platform to transform and replicate data into the SAP HANA database.

Table 1: Deployment Tasks


Task Description More Information

Create an SAP HANA Cloud To create an SAP HANA Cloud instance in the SAP Cloud SAP HANA Cloud Getting
instance Started Guide: Creating SAP
Platform cockpit, you must be working in a global account
HANA Cloud Instances
and have added a quota to the SAP HANA Cloud.

 Tip
Add the IP addresses for your Data Provisioning Agent
host systems to the list of whitelisted connections when
creating your SAP HANA Cloud instance.

Enable flowgraph and repli­ To use the flowgraph and replication task editors in SAP Web Enable Additional Features
cation task editors (Extensions)
IDE on SAP Cloud Platform, you must first enable the SAP
EIM Smart Data Integration Editors extension.

 Note
SAP HANA smart data quality functionality, including
the Cleanse, Geocode, and Match nodes, is not available
in the SAP EIM Smart Data Integration Editors extension
in SAP Web IDE on SAP Cloud Platform.

Connect the Data Provision­ Connect to SAP HANA using JDBC when you are using an Connect to SAP HANA Cloud
ing Agent [Command Line] [page 52]
SAP HANA Cloud instance.

 Note
You must use Data Provisioning Agent version 2.4.2.4 or
newer, and must create users for agent administration
and agent messaging.

Configure adapters for your The Data Provisioning Agent includes adapters that allow Register Data Provisioning
data sources
SAP HANA smart data integration to connect to your data Adapters [page 111]
sources. You may need to perform configuration steps on
Configure Data Provisioning
your source system to prepare your source for use with a
Adapters [page 153].
data provisioning adapter.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
18 PUBLIC HANA Smart Data Quality
Task Description More Information

Create remote sources for Use the SAP HANA database explorer to create remote sour­ Configure Data Provisioning
your data sources Adapters [page 153]
ces in SAP HANA Cloud.

1. In the SAP HANA database explorer, right-click the


Remote Sources object in your database catalog and
click New Remote Source.
2. Specify the remote source name, adapter name, and
dpserver for Source Location.
3. Specify the adapter version and choose Adapter
Properties as the connection mode.
4. Fill in the other required connection property fields as
required for your adapter and data source, and click OK.

Configure an HDI grantor Before SAP Web IDE users can create and execute flow- Configure a Grantor for the
service HDI Container [page 121]
graphs and replication tasks, you must configure grantor
privileges for the HDI container.

Design flowgraphs and repli­ The Modeling Guide, SAP Web IDE addresses SAP HANA Modeling Guide for SAP
cation tasks HANA Smart Data Integra­
smart data integration features and tools to accomplish
tion and SAP HANA Smart
these tasks:
Data Quality
● The Replication Editor is for creating real time or batch
replication scenarios for moving data into SAP HANA.
● Transformation nodes can be used for pivoting tables,
capturing changed data, comparing tables, and so on.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 19
Task Description More Information

Execute and monitor flow- Access the Data Provisioning Monitors from the Catalog Monitoring Data Provisioning
graphs and replication tasks in the SAP HANA Web-based
folder in the SAP HANA database explorer.
Development Workbench
Table 2: Data Provisioning Monitors
Monitor Access

Agents Right-click Data Provisioning Agents


Show Data Provisioning Agents .

Remote Sources
Right-click Remote Sources Show

Remote Sources .

Click a remote source to access the


detailed view for that source.

Remote Subscrip­ Open a system node such as SYSTEM,


tions
or a container. Right-click Remote

Subscriptions Show Remote

Subscriptions .

Click a remote subscription to access


the detailed view for that subscription.

Tasks Open a system node such as SYSTEM,

or a container. Right-click Tasks

Show Tasks .

 Note
You can also access the tasks
monitor from the flowgraph editor
by opening the flowgraph and

choosing Tools Launch Tasks

Overview .

Click a task to access the detailed view


for that task.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
20 PUBLIC HANA Smart Data Quality
1.4.3 Deployment with the SAP HANA Service

Understand the landscape and deployment and configuration process when using SAP HANA smart data
integration with SAP Cloud Platform, SAP HANA service.

Context

When you are using the SAP Cloud Platform, SAP HANA service, you can use SAP HANA smart data
integration with tools such as SAP Web IDE on SAP Cloud Platform to transform and replicate data into the
SAP HANA database.

 Restriction

SAP HANA service does not support SAP HANA smart data quality functionality.

Procedure

1. Ensure that you are using an SAP HANA service instance that has the SAP HANA Data Provisioning Server
capability enabled.

○ To create an instance with the SAP HANA Data Provisioning Server capability, use the SAP Cloud
Platform cockpit.
For more information, see Create an SAP HANA Service Instance Using the Cloud Cockpit.
○ To enable the SAP HANA Data Provisioning Server capability on an existing instance, use the SAP
HANA Service Dashboard.
For more information, see Enable and Disable Capabilities.

2. Ensure that the flowgraph and replication task editors are available in SAP Web IDE on SAP Cloud Platform.
To use the flowgraph and replication task editors in SAP Web IDE on SAP Cloud Platform, you must first
enable the SAP EIM Smart Data Integration Editors extension. For more information, see Enable Additional
Features (Extensions).

 Note

SAP HANA smart data quality functionality, including the Cleanse, Geocode, and Match nodes, is not
available in the SAP EIM Smart Data Integration Editors extension in SAP Web IDE on SAP Cloud
Platform.

3. Connect the Data Provisioning Agent to the SAP HANA service instance via JDBC WebSockets.

For information, see Connect to the SAP HANA Service via JDBC WebSockets [Command Line] [page 56].
4. Configure adapters for your data sources.

The Data Provisioning Agent includes adapters that allow SAP HANA smart data integration to connect to
your data sources. You may need to perform configuration steps on your source system to prepare your
source for use with a data provisioning adapter.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 21
For more information, see Register Data Provisioning Adapters [page 111] and Configure Data Provisioning
Adapters [page 153].
5. Create remote sources in SAP HANA that connect to your data sources.
Use the SAP HANA database explorer to create remote sources in the SAP HANA service.
a. In the SAP HANA database explorer, right-click the Remote Sources object in your database catalog
and click New Remote Source.
b. Specify the remote source name, adapter name, and dpserver for Source Location.
c. Specify the adapter version and choose Adapter Properties as the connection mode.
d. Fill in the other required connection property fields as required for your adapter and data source.
e. Click OK.
For more information about the connection properties for each adapter, see Configure Data Provisioning
Adapters [page 153].
6. Configure a grantor service for the HDI container.

Before SAP Web IDE users can create and execute flowgraphs and replication tasks, you must configure
grantor privileges for the HDI container.

For more information, see Configure a Grantor for the HDI Container [page 121].
7. Design flowgraphs and replication tasks to retrieve data from your remote data sources, transform it, and
persist it in SAP HANA database tables.

The Modeling Guide, SAP Web IDE addresses SAP HANA smart data integration features and tools to
accomplish these tasks:
○ The Replication Editor is for creating real time or batch replication scenarios for moving data into SAP
HANA.
○ Transformation nodes can be used for pivoting tables, capturing changed data, comparing tables, and
so on.

For more information, see the Modeling Guide, SAP Web IDE for SAP HANA Smart Data Integration and
SAP HANA Smart Data Quality.
8. Execute and monitor your SAP HANA smart data integration flowgraphs and replication tasks.
Access the Data Provisioning Monitors from the Catalog folder in the SAP HANA database explorer:

Option Description

Agents Overview Right-click Data Provisioning Agents Show Data Provisioning Agents .

Remote Sources Right-click Remote Sources Show Remote Sources . Click a remote source.
Detailed View

Remote Sources Right-click Remote Sources Show Remote Sources .


Overview

Remote Subscrip­ Open a system node such as SYSTEM, or a container. Right-click Remote Subscriptions
tions Detailed View Show Remote Subscriptions . Click a remote subscription.

Remote Subscrip­ Open a subfolder of the system, or a container. Right-click Remote Subscriptions Show
tions Overview Remote Subscriptions .

Task Detailed View Open a system node such as SYSTEM, or a container. Right-click Tasks Show Tasks . Click
a task.

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
22 PUBLIC HANA Smart Data Quality
Option Description

 Note
Also, you may access the tasks monitor from the flowgraph editor by opening the flowgraph
and choosing Tools Launch Tasks Overview .

Task Overview Open a system node such as SYSTEM, or a container. Right-click Tasks Show Tasks .

 Note
Also, you may access the tasks monitor from the flowgraph editor by opening the flowgraph
and choosing Tools Launch Tasks Overview .

For more details about the information provided in each monitor, see Monitoring Data Provisioning in the
SAP HANA Web-based Development Workbench.

1.5 Administration Tools

Several tools are available for the administration of SAP HANA smart data integration and SAP HANA smart
data quality.

Tool Description

SAP HANA studio The SAP HANA Administration Console perspective of the SAP HANA
studio is the main tool for general system administration and monitoring
tasks.

Data Provisioning Agent Configuration tool This tool manages Data Provisioning Agents and adapters, and connec­
tions to SAP HANA.

SAP HANA cockpit The SAP HANA cockpit is an SAP Fiori Launchpad site that provides you
with a single point-of-access to a range of Web-based applications for
the administration of SAP HANA. You access the SAP HANA cockpit
through a web browser.

Through the SAP HANA cockpit, you can monitor Data Provisioning
Agents, tasks, and remote subscriptions.

SAP HANA Enterprise Semantic Services Ad­ The SAP HANA Enterprise Semantic Services Administration user inter­
ministration tool face is a browser-based application that lets you manage artifacts for se­
mantic services. To launch the SAP HANA Enterprise Semantic Services
Administration tool, enter the following URL in a web browser:http://
<your_HANA_instance:port>/sap/hana/im/ess/ui

Installation and Configuration Guide


Installation and Configuration Guide for SAP HANA Smart Data Integration and SAP
HANA Smart Data Quality PUBLIC 23
2 Configure Smart Data Integration

A list of high-level tasks needed to set up SAP HANA smart data integration.

1. Assign Roles and Privileges [page 25]


Add roles and privileges for users to perform various tasks.
2. Configure the Data Provisioning Server [page 31]
Enable the Data Provisioning Server to use SAP HANA smart data integration.
3. Download and Deploy the Data Provisioning Delivery Unit [page 33]
Download the Data Provisioning delivery unit. Then, using SAP HANA studio or SAP HANA Application
Lifecycle Management tools, deploy the delivery unit to obtain the following functionality:
4. Install the Data Provisioning Agent [page 36]
The Data Provisioning Agent provides secure connectivity between the SAP HANA database and your
on-premise, adapter-based sources.
5. Configure the Data Provisioning Agent [page 49]
Configure the Data Provisioning Agent before you can use adapters to connect to data sources, create
remote sources, and so on.
6. Register Data Provisioning Adapters [page 111]
After configuring the Data Provisioning Agent, register adapters.
7. Create a Remote Source [page 117]
Using SAP HANA smart data integration, you set up an adapter that can connect to your source
database, then create a remote source to establish the connection.
8. Set Up Data Provisioning Monitoring [page 124]
After you install SAP HANA smart data integration, you must take several actions to enable and access
the monitoring user interfaces for Data Provisioning Agents, remote subscriptions, and tasks.
9. Enabling Enterprise Semantic Services [page 125]
Enterprise Semantic Services provides an API to enable searching for publication artifacts or run-time
objects based on their metadata and contents. It is optional for SAP HANA smart data integration.
10. Enable SAP HANA Smart Data Integration REST API [page 133]
Use the SAP HANA smart data integration REST API to programmatically execute and monitor
flowgraphs and to process data for interactive data transformation within your application.

Related Information

Installation and Configuration Guide


24 PUBLIC Configure Smart Data Integration
2.1 Assign Roles and Privileges

Add roles and privileges for users to perform various tasks.

The following tables list common tasks and roles or privileges that an administrator requires to assign to
complete those tasks.

Data Provisioning Agent and Data Provisioning Adapter Tasks

Users may need specific roles and privileges to accomplish tasks when installing and configuring the Data
Provisioning Agent and Data Provisioning Adapters.

 Note

Users may also require permissions for accessing a particular database through a data provisioning
adapter. See the “Data Provisioning Adapters” section for more information.

Task Roles and Privileges Description

Register a DP Agent System privilege:

● AGENT ADMIN

Register an adapter System privilege:

● ADAPTER ADMIN

Configure DP Agent to Role: Whoever sets the Data Provisioning Agent to use HTTP
use HTTP (cloud) pro­ (cloud) in the Data Provisioning Agent Configuration tool re­
● sap.hana.im.dp.proxy::Agent­
tocol quires this role.
Messaging

Create an Agent or Application privilege: Needed when an administrator wants to create adapters and
adapter when SAP agents from the Data Provisioning Agent Configuration tool
● sap.hana.im.dp.admin::Admin­
HANA is in the cloud when SAP HANA is on the cloud (or the agent uses HTTP
istrator
protocol).

Import a delivery unit Role: This role is necessary if you are using SAP HANA Application
using SAP HANA Ap­ Lifecycle Management to import the data provisioning deliv­
● sap.hana.xs.lm.roles::Adminis­
plication Lifecycle ery unit.
trator
Management

Import a delivery unit Role:


using SAP HANA stu­
● sap.hana.xs.lm.roles::Trans­
dio
port

Monitoring Tasks

Users may need specific roles and privileges to access and perform various tasks through the Data
Provisioning monitors, which can be accessed from the SAP HANA cockpit.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 25
Task Roles and Privileges Description

Monitoring Role: The Monitoring role includes the following application privi­
leges:
● sap.hana.im.dp.moni­
tor.roles::Monitoring ● sap.hana.ide::LandingPage

Application privilege: ● sap.hana.im.dp.monitor::Monitoring

● sap.hana.im.dp.monitor::Moni­
toring

Role: The Operations role includes the following application privi­


leges (sap.hana.im.dp.monitor::*):
● sap.hana.im.dp.moni­
tor.roles::Operations ● AddLocationToAdapter
● AlterAgent
● AlterRemoteSource
● AlterRemoteSubscription
● CreateAgent
● DeleteSchedule
● DropAgent
● DropRemoteSubscription
● ExecuteDesignTimeObject
● NotificationAdministration
● ProcessRemoteException (This privilege includes both
remote source and remote subscription exceptions.)
● RemoveLocationFromAdapter
● ScheduleDesignTimeObject
● ScheduleTask
● StartTask
● StopTask
● UpdateAdapter

Enable users to sched­ Role:


ule a task
● sap.hana.xs.admin.roles::Job­
SchedulerAdministrator

Schedule a task Role:

● sap.hana.im.dp.moni­
tor.roles::Operations

Application privilege:

● sap.hana.im.dp.moni­
tor::ScheduleTask

Start a task Application privilege:

● sap.hana.im.dp.monitor::Start­
Task

Stop a task Application privilege:

● sap.hana.im.dp.monitor::Stop­
Task

Installation and Configuration Guide


26 PUBLIC Configure Smart Data Integration
Task Roles and Privileges Description

Process remote sub­ Object privilege: Must be explicitly granted for a remote source created by an­
scription exceptions other user.
● PROCESS REMOTE SUB­
SCRIPTION EXCEPTION

Remote Source and Remote Subscription Tasks

Users may need specific roles and privileges to create and manage remote sources and remote subscriptions.

Task Roles and Privileges Description

Create a remote System privilege: When a user can create a remote source (has CREATE RE­
source MOTE SOURCE system privilege), that user automatically
● CREATE REMOTE SOURCE
has CREATE VIRTUAL TABLE, DROP, CREATE REMOTE SUB­
SCRIPTIONS and PROCESS REMOTE SUBSCRIPTION EX­
CEPTION privileges; these privileges do not need to be as­
signed to the user. However, this only applies to remote sour­
ces that the user creates himself. If someone else creates a
remote source, those privileges must be assigned for each
remote source in order to perform those tasks.

Alter a remote source Object privilege: To alter a remote source, a user must have the ALTER object
privilege on the remote source. Examples of altering a re­
● ALTER
mote source include:

● ALTER REMOTE SOURCE


<remote_source_name> SUSPEND CAPTURE
● ALTER REMOTE SOURCE
<remote_source_name> RESUME CAPTURE

Drop a remote source Object privilege: This privilege must be explicitly granted for a remote source
created by another user.
● DROP

Search for an object in Object privilege: To search for remote objects such as tables in a remote
a remote source source, a user must have the ALTER object privilege on the
● ALTER on the remote source
to be searched remote source so the system can create a dictionary.

Add a virtual table Object privilege This privilege must be explicitly granted for a remote source
created by another user.
● CREATE VIRTUAL TABLE

 Note
When you use SAP Web IDE for SAP HANA, the internal
ObjectOwner of the HDI project must have privileges to
create virtual tables on the remote source.

Create a remote sub­ Object privilege: This privilege must be explicitly granted for a remote source
scription created by another user.
● CREATE REMOTE SUBSCRIP­
TION

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 27
Replication Task and Flowgraph Tasks

Users may need specific roles and privileges to create and run flowgraphs and replication tasks from SAP Web
IDE for SAP HANA, SAP HANA Web-based Development Workbench, or the SAP HANA studio.

Task Roles and Privileges Description

Create a flowgraph For SAP HANA Web-based Devel­ Allows creation of .hdbflowgraph.
opment Workbench and SAP HANA
studio:  Tip

Role: When you use SAP Web IDE for SAP HANA, specific
roles or privileges are not required to create flowgraphs.
● sap.hana.xs.ide.roles::Editor­
Developer

Object privilege:

● EXECUTE on
"_SYS_REPO"."TEXT_ACCES­
SOR" and
"_SYS_REPO"."MULTI_TEXT_A
CCESSOR"

Create a flowgraph of Object privilege:


type Task
● SELECT (for input/output
schema)

Create a replication Role: Allows creation of .hdbreptask.


task
● sap.hana.xs.ide.roles::Editor­
Developer

Activate replication Object privileges: Must be granted to _SYS_REPO.


task (.hdbreptask)
● SELECT on the source schema
● CREATE VIRTUAL TABLE on
REMOTE SOURCE (Initial Load
Only)
● CREATE REMOTE SUBSCRIP­
TION on REMOTE SOURCE
(for real-time scenarios)

Installation and Configuration Guide


28 PUBLIC Configure Smart Data Integration
Task Roles and Privileges Description

Activate flowgraph Object privileges: Must be granted to _SYS_REPO.


(.hdbflowgraph)
● SELECT on the source table
 Tip
● INSERT, UPDATE, and DELETE
on the target table When you use SAP Web IDE for SAP HANA, the Objec­
● SELECT on the target schema tOwner automatically has all necessary privileges for
(only when using a Template flowgraph activation. When using synonyms, the granter
Table as a target) service must manage the privileges.
● If sequence is used, then
GRANT SELECT on sequence
● History Table:
○ GRANT INSERT on His­
tory Table
○ GRANT SELECT on Target
Table

Execute a stored pro­ Object privilege: Needed on the schema where the stored procedure is lo­
cedure cated.
● EXECUTE

 Tip
When you use SAP Web IDE for SAP HANA, the Objec­
tOwner automatically has all necessary privileges for ex­
ecuting stored procedures. When using synonyms, the
granter service must manage the privileges.

Execute a task Object privilege: Needed on the schema where the task is located.

● EXECUTE
 Tip
● INSERT
● UPDATE When you use SAP Web IDE for SAP HANA, the Objec­
tOwner automatically has all necessary privileges for ex­
● SELECT
ecuting tasks.
● DELETE

Use the JIT (just-in- Object privilege: Must be granted to _SYS_REPO. Needed on the schema
time) Data Preview op­ where the task or stored procedure is located.
● SELECT and EXECUTE with
tion
GRANT OPTION  Restriction
The JIT (just-in-time) Data Preview option is not sup­
ported in SAP Web IDE for SAP HANA. If you want to use
the JIT Data Preview option, consider using SAP HANA
Web-based Development Workbench.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 29
Task Roles and Privileges Description

Use the AFL node or For AFL node in SAP HANA Web-
the Predictive Analysis based Development Workbench
node and Predictive Analysis node in SAP
Web IDE:

Role: XSA_DEV_USER_ROLE and


_<SYS>_DI_OO_DEFAULTS

● AFL_AREAS
● AFL_FUNCTION_PARAME­
TERS
● AFL_FUNCTION_PROPERTIES
● AFL_FUNCTIONS
● AFL_PACKAGES
● AFL_TEXTS

For execution, _<SYS>_DI_OO_DE­


FAULTS

● AFL__SYS_AFL_AFLPAL_EXE­
CUTE

Access to SAP Web IDE for SAP HANA

Although specific authorizations are not required to use the flowgraph editor, you may need to configure users
if they do not already have access to SAP Web IDE in general. For example, they may need the following roles or
permissions:

● A role collection containing the WebIDE_Developer role template


● A role collection containing the WebIDE_Administrator role template
● The SpaceDeveloper role for the space in which they need to work

For complete information about granting users access to SAP Web IDE, see the necessary configuration tasks
described in Post-Installation Administration Tasks.

Parent topic: Configure Smart Data Integration [page 24]

Next: Configure the Data Provisioning Server [page 31]

Related Information

Grant Roles to Users [page 124]


Developer Authorization in the Repository (SAP HANA Security Guide)
SAP HANA Web-based Development Workbench: Editor (SAP HANA Developer Guide)

Installation and Configuration Guide


30 PUBLIC Configure Smart Data Integration
SAP Web IDE for SAP HANA - Installation and Upgrade Guide

2.2 Configure the Data Provisioning Server

Enable the Data Provisioning Server to use SAP HANA smart data integration.

By default, the Data Provisioning Server is disabled when you install SAP HANA.

Enable the Server in a Multi-database Container Scenario [page 31]


To enable the Data Provisioning Server on tenants in a multi-database container environment, use the
ALTER DATABASE SQL command.

Enable the Server in a Scale-out SAP HANA Database Scenario [page 32]
In a scale-out SAP HANA database scenario, you must enable the Data Provisioning Server only on the
host that runs the master index server.

Enable the Server for the SAP HANA Service [page 32]
To use SAP HANA smart data integration with the SAP Cloud Platform, SAP HANA service, you must
use an instance with the SAP HANA Data Provisioning Server capability enabled.

Parent topic: Configure Smart Data Integration [page 24]

Previous: Assign Roles and Privileges [page 25]

Next: Download and Deploy the Data Provisioning Delivery Unit [page 33]

Related Information

2.2.1 Enable the Server in a Multi-database Container


Scenario

To enable the Data Provisioning Server on tenants in a multi-database container environment, use the ALTER
DATABASE SQL command.

For example, ALTER DATABASE <database_name> ADD 'dpserver' [AT LOCATION


'<hostname>[:<port_number>]'].

Parent topic: Configure the Data Provisioning Server [page 31]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 31
Related Information

Enable the Server in a Scale-out SAP HANA Database Scenario [page 32]
Enable the Server for the SAP HANA Service [page 32]
ALTER DATABASE Statement (Tenant Database Management) (SAP HANA SQL and System Views Reference)

2.2.2 Enable the Server in a Scale-out SAP HANA Database


Scenario

In a scale-out SAP HANA database scenario, you must enable the Data Provisioning Server only on the host
that runs the master index server. Slave nodes should not have enabled Data Provisioning Server instances.

ALTER SYSTEM ALTER CONFIGURATION ('daemon.ini', 'HOST',


'<master_indexserver_hostname>') SET ('dpserver','instances') = '1' WITH
RECONFIGURE;

Parent topic: Configure the Data Provisioning Server [page 31]

Related Information

Enable the Server in a Multi-database Container Scenario [page 31]


Enable the Server for the SAP HANA Service [page 32]

2.2.3 Enable the Server for the SAP HANA Service

To use SAP HANA smart data integration with the SAP Cloud Platform, SAP HANA service, you must use an
instance with the SAP HANA Data Provisioning Server capability enabled.

Context

Create an instance with the capability, or enable it on an existing instance.

Procedure

● To create an instance with the SAP HANA Data Provisioning Server capability, use the SAP Cloud Platform
cockpit.

Installation and Configuration Guide


32 PUBLIC Configure Smart Data Integration
● To enable the SAP HANA Data Provisioning Server capability on an existing instance, use the SAP HANA
Service Dashboard.

Next Steps

For more information about managing an SAP HANA Service instance, see the SAP Cloud Platform, SAP HANA
Service Getting Started Guide

Task overview: Configure the Data Provisioning Server [page 31]

Related Information

Enable the Server in a Multi-database Container Scenario [page 31]


Enable the Server in a Scale-out SAP HANA Database Scenario [page 32]
Create an SAP HANA Service Instance Using the Cloud Cockpit
Enable and Disable Capabilities

2.3 Download and Deploy the Data Provisioning Delivery


Unit

Download the Data Provisioning delivery unit. Then, using SAP HANA studio or SAP HANA Application Lifecycle
Management tools, deploy the delivery unit to obtain the following functionality:

Functionality Description

Monitoring The Monitoring application provides a browser-based interface to monitor agents, tasks, and remote
subscriptions created in the SAP HANA system. The monitor application can be accessed from the SAP
HANA cockpit.

Proxy The Proxy application provides a way for the Data Provisioning Agent to communicate with the Data Pro­
visioning Server. It is required when SAP HANA is running in the cloud or when the remote sources are
behind a firewall. In this case, the Data Provisioning Agent stays behind the firewall (that is, close to the
remote source) and communicates with SAP HANA (specifically, the dpserver) via the Proxy application
running in the XS engine.

Admin The Admin application provides a way for the Data Provisioning Agent Configuration tool to issue SQL
commands necessary to register the agent and the adapters in the SAP HANA system. This application
is used when SAP HANA is in the cloud and the Data Provisioning Agent is behind a firewall.

Parent topic: Configure Smart Data Integration [page 24]

Previous: Configure the Data Provisioning Server [page 31]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 33
Next: Install the Data Provisioning Agent [page 36]

Related Information

Download the Data Provisioning Delivery Unit [page 34]


Deploy the Delivery Unit from SAP HANA Studio [page 35]
Deploy the Delivery Unit from SAP HANA Application Lifecycle Management [page 35]

2.3.1 Download the Data Provisioning Delivery Unit

Download the Data Provisioning delivery unit from the SAP Software Download Center.

Context

The data provisioning delivery unit is available in the same download area as the data provisioning agent.

Procedure

1. Go to the SAP Software Download Center, and navigate to the following location: SAP Software Download
Center Software Downloads Installations & Upgrades By Alphabetical Index (A-Z) H SAP HANA
SDI SAP HANA SDI 2.0 .
2. Click COMPRISED SOFTWARE COMPONENT VERSIONS.
3. Click HANA DP 2.0.
4. Click the ZIP file that you need, and save it to your preferred location.
5. In the HANAIMDP<version number>.ZIP file, find and extract the HANA_IM_DP.tgz file.
This is the delivery unit file that needs to be imported into SAP HANA.

Related Information

SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Installation and Configuration Guide


34 PUBLIC Configure Smart Data Integration
2.3.2 Deploy the Delivery Unit from SAP HANA Studio

You can deploy the Data Provisioning delivery unit from SAP HANA studio.

 Note

When SAP HANA is deployed in a multi-tenant database container configuration, you must import the
delivery unit into the tenant database.

Prerequisites

Ensure that you have been granted the SYSTEM privilege REPO.IMPORT to be able to import the delivery unit.

Procedure

1. Log in to SAP HANA studio as user SYSTEM.

2. In the upper left corner, click File Import .


3. On the Import dialog, type delivery into the search box for Select an import source.
4. Click Delivery Unit on the resulting navigation tree and click Next.
5. Select your SAP HANA server name, and click Next.
6. On the Import Through Delivery Unit dialog, select either Client or Server, depending on whether the
delivery unit is on the client or server machine.
a. If you select Client, click Browse and navigate to the location where you downloaded the delivery unit,
then select HANAIMDP.tgz and click Open.
b. If you select Server, select the delivery unit you want to import from the dropdown list.
7. Click Finish.

2.3.3 Deploy the Delivery Unit from SAP HANA Application


Lifecycle Management

You can deploy the Data Provisioning delivery unit through SAP HANA Application Lifecycle Management
(ALM).

 Note

When SAP HANA is deployed in a multi-tenant database container configuration, you must import the
delivery unit into the tenant database.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 35
Procedure

1. If not already granted, grant the role sap.hana.xs.lm.roles::Administrator to the user name you use to log in
to ALM.
a. In the SAP HANA studio Systems view, expand the name of your SAP HANA server and choose
Security Users System .
b. On the Granted Roles tab, click the green “+” icon in the upper left corner.
c. On the Select Roles dialog, type lm in the search string box.
d. Select the role sap.hana.xs.lm.roles::Administrator and click OK.
2. Access ALM by typing the following URL in a web browser:
<host name>:80<2-digit instance number>/sap/hana/xs/lm
3. Log in to ALM as the user name you authorized in step 1.
The first time you log in, a pop-up window asks you to enter a name for this server.
4. On the ALM Home tab, click the Delivery Units tile.
5. Click the Import tab.
6. Click Browse and navigate to the location where you downloaded the delivery unit, then select
HANAIMDP.tgz and click Open.
7. Click Import.
After successful import, the name HANA_IM_DP (sap.com) appears in the list of delivery units on the left.

2.4 Install the Data Provisioning Agent

The Data Provisioning Agent provides secure connectivity between the SAP HANA database and your on-
premise, adapter-based sources.

1. Planning and Preparation [page 37]


Before you install the Data Provisioning Agent, plan your installation to ensure that it meets your
system landscape's needs.
2. Install the Data Provisioning Agent [page 42]
You can install the Data Provisioning Agent on a Windows or Linux host.
3. Manage Agents from the Data Provisioning Agent Monitor [page 47]
Use the Data Provisioning Agent Monitor to perform basic administration tasks such as registering,
altering, or dropping Data Provisioning Agents.

Parent topic: Configure Smart Data Integration [page 24]

Previous: Download and Deploy the Data Provisioning Delivery Unit [page 33]

Next: Configure the Data Provisioning Agent [page 49]

Installation and Configuration Guide


36 PUBLIC Configure Smart Data Integration
Related Information

2.4.1 Planning and Preparation

Before you install the Data Provisioning Agent, plan your installation to ensure that it meets your system
landscape's needs.

When planning your installation, consider the following questions:

● Where should the Data Provisioning Agent be installed?


You can install the agent on any host system that has access to the sources you need, meets the minimum
system requirements, and has any middleware required for source access installed. Install the agent on a
host where you have full control to view logs and restart, if necessary.
In many cases, installing the Data Provisioning Agent on the same host machine as the source database is
not practical, because the Data Provisioning Agent host may need restarting when you troubleshoot issues
and can consume a significant amount of memory.
For best performance, install the Data Provisioning Agent on a separate machine or in a virtual machine as
close to the source database as possible.

 Restriction

We do not recommend installing the Data Provisioning Agent directly on the SAP HANA system.

 Note

For information about Data Provisioning Agent, operating system, and DBMS compatibility, refer to the
SAP HANA smart data integration Product Availability Matrix (PAM).

● How many Data Provisioning Agents should be installed?


You can install one or many agents depending on your landscape requirements.
● Which network protocols are required in your system landscape?
Depending on whether SAP HANA is installed on premise, in the cloud, or behind a firewall, the connection
between the agent and SAP HANA can use TCP/IP or HTTP.
For security purposes, be sure to enable SSL correctly for the Framework listener port using the Data
Provisioning Configuration Tool for On-Premise application. For SAP HANA on Cloud, use HTTPS to
communicate with SAP HANA and configure the agent to communicate using the HTTPS protocol using
the Data Provisioning Configuration Tool.
● Can the host system support the load from the Data Provisioning Agent?
Generally speaking, the agent generates minimal additional load on the host system. The agent translates
the source's format and commands to and from the SAP HANA format and commands. Additionally, the
system utilization varies depending on the type and number of adapters deployed.

Parent topic: Install the Data Provisioning Agent [page 36]

Next task: Install the Data Provisioning Agent [page 42]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 37
Related Information

Supported Platforms and System Requirements [page 38]


Software Download [page 39]
Prepare the Amazon Web Services Environment [page 40]
Download the SAP HANA Server Certificate [page 41]
Supported Platforms and System Requirements [page 38]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Agent Adapter Framework Preferences [page 104]


Configuring SSL [page 498]

2.4.1.1 Supported Platforms and System Requirements

Install the Data Provisioning Agent on a supported platform that meets the minimum system requirements or
higher.

You can find a complete list of all SAP HANA components and the respective SAP HANA hardware and software
requirements in the Product Availability Matrix (PAM) on the Support Portal and in the SAP Community
Network.

Operating System for the Data Provisioning Agent

For the Data Provisioning Agent host system, the following 64-bit platforms are supported:

● Microsoft Windows Server


● SUSE Linux Enterprise Server (SLES)
● Red Hat Enterprise Linux (RHEL)

Software Requirements

For more information about supported Java versions, see the SAP HANA Smart Data Integration Product
Availability Matrix (PAM).

On Linux platforms, the following extra requirements apply:

● The system must have GCC 5.x to run the Data Provisioning Agent service, ASEAdapter, and
ASEECCAdapter.
For more information, see SAP Note 2338763 .

Installation and Configuration Guide


38 PUBLIC Configure Smart Data Integration
Related Information

SAP Note 2338763 - Linux: Running SAP Applications compiled with GCC 5.x
SAP HANA Smart Data Integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

2.4.1.2 Software Download

The Data Provisioning Agent installation package is available in the component SAP HANA SDI (SAP HANA
smart data integration) on the SAP Software Download Center.

 Note

Installation of the Data Provisioning Agent requires the correct version of SAP HANA. Subsequent support
packages or revisions of SAP HANA may require an equivalent update to the Data Provisioning Agent. For
details, see the SAP HANA smart data integration Product Availability Matrix (PAM).

On the SAP Software Download Center , you can find the installation packages in the following locations:

● Installation media for an SAP HANA smart data integration release:


SAP Software Download Center Software Downloads Installations & Upgrades By Alphabetical
Index (A-Z) H SAP HANA SDI SAP HANA SDI <version_number> Comprised Software
Component Versions
● Support Packages and Patches:
SAP Software Download Center Software Downloads Support Packages & Patches By Alphabetical
Index (A-Z) H SAP HANA SDI SAP HANA SDI <version_number> Comprised Software
Component Versions HANA DP AGENT <version_number>
In either case, on the Downloads tab, select the package to download. From the list of items, select the
desired version. Click the Add Selected Items to Download Basket icon. Select Download Basket and select
Download Manager to start the download process. In the downloaded ZIP file, locate the HANAIMADP.tgz
file and extract it.
To verify the agent version, see the SAP HANA smart data integration Product Availability Matrix (PAM).

SAP JVM

The SAP JVM is the default Java runtime supported by the Data Provisioning Agent, and is bundled with the
Data Provisioning Agent installation package. However, to obtain any subsequent security patches, you can
independently download the latest releases of the SAP JVM from the same location and update your agent
installation.

SAP Software Download Center Software Downloads Installations & Upgrades By Alphabetical Index (A-
Z) H SAP HANA SDI SAP HANA SDI 1.0 Comprised Software Versions

For more information about changing the Java runtime, see “Reconfigure the Java Runtime Environment”.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 39
Related Information

SAP Software Download Center


SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Download and Deploy the Data Provisioning Delivery Unit [page 33]
Reconfigure the Java Runtime Environment [page 92]

2.4.1.3 Prepare the Amazon Web Services Environment

Before you can install the Data Provisioning Agent on Amazon Web Services (AWS), you must prepare the
environment.

Procedure

1. Launch the Amazon Web Services (AWS) instance.


2. Copy the Java Development Kit and the Data Provisioning Agent packages to /download on the AWS host:
For example:
○ jdk-8u60-linux-x64.rpm.rpm
○ IMDB_DPAGENT100_00_2-70000174.SAR

 Note

Create the /download directory, if it does not exist.

3. Log in to the AWS host as ec2-user and start a sudo bash command line.

sudo bash

4. Install the Java Development Kit.

zypper install jdk-8u60-linux-x64.rpm.rpm

5. Change to the ec2-user user and extract the Data Provisioning Agent installation program.

su ec2-user
./SAPCAR –xvf IMDB_DPAGENT100_00_2-70000174.SAR

Results

The Java Development Kit is installed and the Data Provisioning Agent installation program is available on the
AWS host. You can continue to install the Data Provisioning Agent from the command line.

Installation and Configuration Guide


40 PUBLIC Configure Smart Data Integration
Related Information

Install from the Command Line [page 45]

2.4.1.4 Download the SAP HANA Server Certificate

When SAP HANA is configured for HTTPS, you need a copy of the server certificate to configure the SAP HANA
Data Provisioning Agent.

 Tip

To verify whether the SAP HANA server is configured for HTTPS, examine the port number being used. If
the port number is 80<xx>, the server is using standard HTTP. If the port number is 43<xx>, the server is
using HTTPS.

When SAP HANA is located in the cloud, it is always configured for HTTPS communication.

Context

You can download the SAP HANA server certificate using a web browser.

 Tip

If the agent keystore does not have the server certificate required for HTTPS communication, the Data
Provisioning Agent Configuration tool allows you to import the server certificate into the agent keystore
directly. This procedure is required only if you do not want the configuration tool to import the certificate
directly, and you want to import it manually separately.

Procedure

1. Navigate to the SAP HANA server in a web browser.

For example, https://<hostname>.us1.hana.ondemand.com.


2. Open the certificate information for the page.

The exact steps to open the certificate information depend on your browser.
○ For Internet Explorer, click the lock icon in the address bar, and click View Certificates.
○ For Chrome, click the lock icon in the address bar, and click Connection Certificate Information .
3. In the Details tab, click Copy to file.

The Certificate Export Wizard displays. Click Next.


4. Select DER encoded binary X.509 (.CER) and click Next.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 41
5. Specify a name for the certificate file and save it locally.

For example, HANA_Certificate_06Oct2015.cer.


6. Transfer the certificate file to a location available to the Data Provisioning Agent.

2.4.2 Install the Data Provisioning Agent

You can install the Data Provisioning Agent on a Windows or Linux host.

The default installation manager is a graphical installation tool. If you cannot or do not want to use a graphical
tool, see Install from the Command Line [page 45].

Prerequisites

To install the Data Provisioning Agent on Windows, you must use the Administrator user or a user in the
Administrators group.

To install the Data Provisioning Agent on Linux, there are extra prerequisites:

● GTK 2 is installed so you can run the installation tool.


● A local X11 graphical environment and an X server must be available on the machine where you install.
● Create or use an existing non-root agent user that is authorized to open a display and has full read and
write access to the intended installation location.

 Note

The default installation location (/usr/sap/dataprovagent) requires the agent user to have write
access to the /usr/ directory.

Before installation, grant the agent user the appropriate permissions (use sudo to create
the /usr/sap/dataprovagent directory and grant permissions to the user) or choose a different
installation location.

Context

 Caution

When you install the Data Provisioning Agent, the agent uses, by default, a non-secure channel when
communicating with the SAP HANA server.

To enable secure communication, you must configure SSL with the Data Provisioning Agent Configuration
tool after installation. For more information, see “Connect to SAP HANA on-premise with SSL” and
“Connect to SAP HANA in the cloud”.

Installation and Configuration Guide


42 PUBLIC Configure Smart Data Integration
Procedure

1. Download and extract the software to an empty directory.


2. Navigate to the directory where you extracted the software.
3. Call the installation manager.

○ On Windows, right-click hdbsetup.exe and choose Run as administrator.


○ On Linux, run ./hdbsetup.
4. Choose Install new SAP HANA Data Provisioning Agent and specify the installation path.
5. On Windows, specify the unique agent name.

The unique agent name is a string of up to 30 alphanumeric characters that identifies the agent instance
and must be different from any names already used by other agent instances on the same host system.

It is used as a suffix when creating the Windows service, uninstallation entry, and configuration tool
shortcut.
6. On Windows, specify the username (<domain>\<username>) and password to use for the agent service.

The user that runs the agent service must have read and write access to the installation directory so
configuration files can be updated.

 Note

On Linux, the agent user who installs is the installation owner. Ideally, you should be logged in as this
user when starting the agent service.

7. To use a custom Java runtime environment instead of the bundled SAP JVM, specify the path to the JRE
installation.

 Note

We recommend using the bundled SAP JVM located in <DPAgent_root>/sapjvm

For example:
○ On Windows, C:\Program Files\Java\jre7
○ On Linux, /usr/java/jdk<version>/jre

 Note

The Data Provisioning Agent supports only 64-bit Java runtime environments.

Results

The Data Provisioning Agent is installed or updated.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 43
Next Steps

● After installing the Data Provisioning Agent, we recommend that you review the installation log file for any
errors and take any necessary corrective actions.
● If you have installed the Data Provisioning Agent on Amazon Web Services (AWS), set the
cloud.deployment parameter.
Open <DPAgent_root>/dpagentconfig.ini in a text editor and set the value:

cloud.deployment=AWS_

● Proceed by configuring the agent as required for your landscape.

 Caution

On Linux, we recommend that you do not start the Data Provisioning Agent while logged in as the root
user. Instead, log in with the agent user, and then start the Data Provisioning Agent.

If you accidentally start the agent as the root user, see “Clean an Agent Started by the Root User” in
the Administration Guide.

Task overview: Install the Data Provisioning Agent [page 36]

Previous: Planning and Preparation [page 37]

Next task: Manage Agents from the Data Provisioning Agent Monitor [page 47]

Related Information

Install from the Command Line [page 45]


Installation Logs [page 47]
Default Installation Paths [page 47]
Connect to SAP HANA On-Premise with SSL [page 512]
Connect to SAP HANA on Cloud [page 86]
Clean an Agent Started by the Root User

Installation and Configuration Guide


44 PUBLIC Configure Smart Data Integration
2.4.2.1 Install from the Command Line

If you cannot use or do not want to use the graphical installation manager, you can install the Data Provisioning
Agent using the command-line tool.

Prerequisites

To install the Data Provisioning Agent on Windows, you must use the Administrator user or a user in the
Administrators group.

To install the Data Provisioning Agent on Linux, you must create or use an existing non-root agent user that
has full read and write access to the intended installation location.

 Note

The default installation location (/usr/sap/dataprovagent) requires the agent user to have write access
to the /usr/ directory.

Before installation, grant the agent user the appropriate permissions (use sudo to create the /usr/sap/
dataprovagent directory and grant permissions to the user) or choose a different installation location.

Context

 Caution

When you install the Data Provisioning Agent, the agent uses, by default, a non-secure channel when
communicating with the SAP HANA server.

To enable secure communication, you must configure SSL with the Data Provisioning Agent Configuration
tool after installation. For more information, see “Connect to SAP HANA on-premise with SSL” and
“Connect to SAP HANA in the cloud”.

Procedure

1. Download and extract the software to an empty directory.


2. Navigate to the directory where you extracted the software.
3. On Windows, create the password XML file one directory level above hdbinst.exe:

<?xml version="1.0" encoding="UTF-8"?>


<Passwords>
<service_password><password></service_password>
</Passwords>

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 45
4. Call the installation program.

○ On Windows, run more ..\passwords.xml | hdbinst.exe --silent --batch --


path="<DPAgent_root>" --agent_listener_port=<port> --agent_admin_port=<port>
--agent_instance=<unique_name> --service_user=<domain>\<username> --
read_password_from_stdin=xml.
○ On Linux, run ./hdbinst --silent --batch --path="<DPAgent_root>" --
agent_listener_port=<port> --agent_admin_port=<port>.

Results

The Data Provisioning Agent is installed without displaying the graphical installation manager.

Next Steps

 Caution

If you created a password XML file for the installation, be sure to delete it after the installation process has
completed. Leaving the password XML file on the server is a security risk.

If you have installed the Data Provisioning Agent on Amazon Web Services (AWS), set the cloud.deployment
parameter.

Open <DPAgent_root>/dpagentconfig.ini in a text editor and set the value:

cloud.deployment=AWS_

Proceed by configuring the agent as required for your landscape.

 Caution

On Linux, we recommend that you do not start the Data Provisioning Agent while logged in as the root
user. Instead, log in with the agent user, and then start the Data Provisioning Agent.

If you accidentally start the agent as the root user, see “Clean an Agent Started by the Root User” in the
Administration Guide.

Related Information

Connect to SAP HANA On-Premise with SSL [page 512]


Connect to SAP HANA on Cloud [page 86]
Clean an Agent Started by the Root User

Installation and Configuration Guide


46 PUBLIC Configure Smart Data Integration
2.4.2.2 Installation Logs

Your system logs the Data Provisioning Agent installation. There are two files written during installation.

● *.log: can be read using a text editor


● *.msg: XML format for display in the installation tool with the graphical user interface

The log files are stored in the following locations:

● On Windows, %TEMP%\hdb_dataprovagent_<timestamp>
● On Linux, /var/tmp/hdb_dataprovagent_<timestamp>

2.4.2.3 Default Installation Paths

The default installation paths are specific to the operating system on which the Data Provisioning Agent is
installed.

Platform Package Version Default Installation Path

Microsoft Windows x86, 64-bit 64-bit C:\usr\sap\dataprovagent

Linux x86, 64-bit 64-bit /usr/sap/dataprovagent

In this documentation, the variable <DPAgent_root> represents these root installation paths.

2.4.3 Manage Agents from the Data Provisioning Agent


Monitor

Use the Data Provisioning Agent Monitor to perform basic administration tasks such as registering, altering, or
dropping Data Provisioning Agents.

Prerequisites

The user must have the following roles or privileges to manage agents:

Table 3: Roles and Privileges

Action Role or Privilege

Add Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::CreateAgent
● System privilege: AGENT ADMIN

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 47
Action Role or Privilege

Alter Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::AlterAgent
● System privilege: AGENT ADMIN

Remove Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::DropAgent
● System privilege: AGENT ADMIN

Context

Use the following controls in the Agent Monitor table to perform an action.

Procedure

● Select Create Agent to register a new agent with the SAP HANA system.
a. Specify the name of the agent and relevant connection information.
b. If the agent uses a secure SSL connection, select Enable SSL.
c. If you want to assign the agent to an existing agent group, select the group under Agent Group.
d. Click Create Agent.

The new agent appears in the Agent Monitor table.


● Select Alter Agent to make connection configuration changes on an agent already registered in the SAP
HANA system.
a. Specify the new connection information for the agent. You can’t change the name or connection
protocol for an existing agent.
b. If the agent uses a secure SSL connection, check Enable SSL.
c. If you want to assign the agent to an existing agent group, select the group under Agent Group.
d. Click Alter Agent.

The updated agent information appears in the Agent Monitor table.


● Select Drop Agent to remove an agent from the SAP HANA system.
a. To drop any dependent objects automatically, such as registered adapters, choose CASCADE option.
You can’t remove an agent while it has dependent objects such as registered adapters. Remove the
adapters from the agent manually, or check CASCADE option.
b. Click Drop Agent.

The agent is removed from the Agent Monitor table. If the agent was assigned to an agent group, it’s also
removed from the agent group.

Task overview: Install the Data Provisioning Agent [page 36]

Previous task: Install the Data Provisioning Agent [page 42]

Installation and Configuration Guide


48 PUBLIC Configure Smart Data Integration
Related Information

Assign Roles and Privileges [page 25]

2.5 Configure the Data Provisioning Agent

Configure the Data Provisioning Agent before you can use adapters to connect to data sources, create remote
sources, and so on.

Configuring the Agent in Command-Line Interactive Mode [page 50]


Use the command-line configuration tool to connect to the SAP HANA server and configure the Data
Provisioning Agent and adapters.

Configuring the Agent in Command Line Batch Mode [page 69]


Use the command-line configuration tool to connect to the SAP HANA server and configure the Data
Provisioning Agent and adapters.

Configuring the Agent in Graphical Mode [Deprecated] [page 83]


Connect to the SAP HANA server and configure the agent and adapters with the Data Provisioning
Agent Configuration tool.

Managing Agent Groups [page 94]


Agent grouping provides failover and load-balancing capabilities by combining individual Data
Provisioning Agents installed on separate host systems.

Manage Agents from the Data Provisioning Agent Monitor [page 103]
Use the Data Provisioning Agent Monitor to perform basic administration tasks such as registering,
altering, or dropping Data Provisioning Agents.

Agent Adapter Framework Preferences [page 104]


The agent preferences provide advanced configuration options for the Data Provisioning Agent.

Agent Runtime Options [page 108]


Use the command-line configuration tool to manage advanced runtime options stored in the
dpagent.ini configuration file safely.

Replicating an Agent Configuration to Another Host [page 110]


There are items that you need to consider when moving to a different host from one where your agent
is configured.

Parent topic: Configure Smart Data Integration [page 24]

Previous: Install the Data Provisioning Agent [page 36]

Next task: Register Data Provisioning Adapters [page 111]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 49
Related Information

2.5.1 Configuring the Agent in Command-Line Interactive


Mode

Use the command-line configuration tool to connect to the SAP HANA server and configure the Data
Provisioning Agent and adapters.For example, you can use the configuration tool to view the agent and adapter
statuses and versions, manage custom and SAP-delivered adapters, and modify keystore paths.

At each menu in interactive mode, specify the number of the desired action or option and press Enter . At any
screen, you can press b to return to the previous menu or q to quit the configuration tool.

If the selected option requires input, the configuration tool displays any existing or default value in parentheses.
You can accept the existing or default value by pressing Enter to move to the next prompt.

 Note

Passwords are hidden from display in command-line interactive mode. If an option has an existing password,
the password displays as “*****”. You do not need to reenter the password unless the password has changed.

 Caution

When you are asked for input entry for an option, you cannot cancel or return to the previous menu. To
abort the operation without saving, you must press Ctrl + C to terminate the configuration tool.

Start the Configuration Tool [Command Line] [page 51]


Start the configuration tool in interactive mode to modify the agent configuration without a graphical
environment.

Connect to SAP HANA Cloud [Command Line] [page 52]


Connect to SAP HANA using JDBC when you are using an SAP HANA Cloud instance.

Connect to SAP HANA On-premise [Command Line] [page 55]


Specify connection information and administrator credentials when the SAP HANA system is located
on-premise.

Connect to the SAP HANA Service via JDBC WebSockets [Command Line] [page 56]
Connect to SAP HANA using JDBC WebSockets when you are using the SAP Cloud Platform, SAP
HANA service in the Cloud Foundry environment.

Connect to SAP HANA in the SAP Cloud Platform Neo Environment [Command Line] [page 62]
Specify connection information, user credentials, and SSL configuration information when SAP HANA
is deployed in the SAP Cloud Platform Neo environment.

Manage the Agent Service [Command Line] [page 64]


Use the command-line configuration tool to stop or start the Data Provisioning Agent service.

Register the Agent with SAP HANA [Command Line] [page 65]
Before you can use adapters deployed on the Data Provisioning Agent, you must register the agent with
SAP HANA.

Installation and Configuration Guide


50 PUBLIC Configure Smart Data Integration
Manage the HANA User for Agent Messaging Credentials [Command Line] [page 67]
If the password for the HANA User for Agent Messaging has changed or expired, you must update the
credentials in the agent secure storage.

Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store source database access credentials in the Data Provisioning Agent secure storage using batch
mode.

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command Line Batch Mode [page 69]


Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]

2.5.1.1 Start the Configuration Tool [Command Line]

Start the configuration tool in interactive mode to modify the agent configuration without a graphical
environment.

Prerequisites

The command-line agent configuration tool requires the DPA_INSTANCE environment variable to be set to the
installation root location (<DPAgent_root>).

For example, on Windows:

set DPA_INSTANCE=C:\usr\sap\dataprovagent

On Linux:

export DPA_INSTANCE=/usr/sap/dataprovagent

 Caution

Multiple instances of the Data Provisioning Agent may be installed on a single Linux host. Be sure that you
set DPA_INSTANCE to the instance that you want to modify before starting the configuration tool. If you do

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 51
not set the environment variable correctly, you may unintentionally modify the configuration of a different
agent instance.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --configAgent parameter.

○ On Windows, agentcli.bat --configAgent


○ On Linux, agentcli.sh --configAgent
3. (Optional) Select 1 to display the agent status.

Results

The command-line configuration tool opens.

2.5.1.2 Connect to SAP HANA Cloud [Command Line]

Connect to SAP HANA using JDBC when you are using an SAP HANA Cloud instance.

Prerequisites

● You have created an SAP HANA Cloud instance in the SAP Cloud Platform Cockpit.
● You have installed the Data Provisioning Agent to an on-premise or cloud-based host system.

 Note

SAP HANA Cloud requires Data Provisioning Agent version 2.4.2.4 or newer.

● You have whitelisted the IP address of the agent host system in the SAP HANA Cloud instance.
● You have an Agent Admin HANA User for connecting the agent configuration tool to SAP HANA Cloud and
performing administrative actions such as registering agents and adapters.
This user must have the following roles or privileges to perform the actions noted in the table below:

Table 4: Roles and Privileges


Action Role or Privilege

Register Agents and Adapters on SAP ○ System privilege: AGENT ADMIN


HANA Cloud ○ System privilege: ADAPTER ADMIN

Installation and Configuration Guide


52 PUBLIC Configure Smart Data Integration
Action Role or Privilege

Create the HANA User for Agent Messag­ ○ Object privilege: USERGROUP OPERATOR on the DEFAULT
ing (Optional) usergroup.

 Note
This privilege is required only when you want to create the HANA User
for Agent Messaging automatically as part of the configuration proc­
ess within the agent configuration tool.

 Note

On SAP HANA Cloud, the user DBADMIN already has the USERGROUP OPERATOR privilege and can be
used if you also assign the AGENT ADMIN and ADAPTER ADMIN system privileges.

For security reasons, you may wish to assign all three privileges to a different user. For more
information, see SAP HANA Cloud Administrator DBADMIN in the SAP HANA Cloud Administration
Guide.

● You have a HANA User for Agent Messaging for messaging between the agent and SAP HANA Cloud.
To create such a user manually, specify the DEFAULT usergroup and a non-expiring password when
creating the user.

CREATE USER <username> PASSWORD <password> NO FORCE_FIRST_PASSWORD_CHANGE SET


USERGROUP DEFAULT;

 Tip

If the Agent Admin HANA User has been granted the privileges indicated in the “Roles and Privileges”
table, it can create the HANA User for Agent Messaging during the configuration process. The
configuration tool creates the HANA User for Agent Messaging as a technical user with the no
expiration period for the password.

 Note

In general, the password for a new SAP HANA user expires according to the SAP HANA password
policy settings, the default for which is 182 days. To avoid agent disruptions in a production scenario,
treat a new HANA User for Agent Messaging as a technical user and ensure that its password does not
expire.

For more information about configuring the password policy for a technical user in SAP HANA, see the
SAP HANA Security Guide.

Procedure

1. Start the command-line agent configuration tool.


2. Choose SAP HANA Connection.
3. Choose Connect to SAP HANA Cloud Services (HCS) via JDBC.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 53
4. Specify true to use an encrypted connection over JDBC.

 Tip

An encrypted connection is always required when connecting to SAP HANA in a cloud-based


environment.

5. Specify the hostname and port for the SAP HANA Cloud instance.

For example:
○ Hostname: <instance_name>.hanacloud.ondemand.com
○ Port Number: 443
6. Specify the Agent Admin HANA User credentials for SAP HANA Cloud as prompted.
7. If HTTPS traffic from your agent host is routed through a proxy, specify any required proxy information as
prompted.
The agent uses the HTTPS protocol to communicate with SAP HANA Cloud.
8. Specify the credentials for the HANA User for Agent Messaging.
The HANA User for Agent Messaging is used only for messaging between the agent and SAP HANA Cloud,
and must be different from the Agent Admin HANA User used for agent administration tasks.
9. Specify whether to create a new HANA User for Agent Messaging.

○ Enter true to create a new user with the specified credentials.


○ Enter false if the specified credentials are for an existing user.

 Tip

Generally, you create this user only during the initial configuration of an agent instance. If you are
modifying the configuration of an existing agent instance, you usually do not need to create a user.

Results

The configuration tool creates the HANA User for Agent Messaging, if applicable, and connects to the SAP
HANA Cloud instance.

Related Information

SAP HANA Cloud Administration Guide


Managing SAP HANA Users
SAP HANA Cloud Administrator DBADMIN
Start the Configuration Tool [Command Line] [page 51]

Installation and Configuration Guide


54 PUBLIC Configure Smart Data Integration
2.5.1.3 Connect to SAP HANA On-premise [Command Line]

Specify connection information and administrator credentials when the SAP HANA system is located on-
premise.

Prerequisites

● The Agent Admin HANA User must have the following roles or privileges:

Table 5: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA System privilege: AGENT ADMIN

System privilege: ADAPTER ADMIN

● If the SAP HANA server is configured for SSL, the agent host must already be prepared for SSL before
connecting the agent configuration tool to the SAP HANA server. If you want to use TCP with SSL, but the
agent is not yet prepared, see Configure SSL for SAP HANA On-Premise [Command Line Batch] [page
509].

Procedure

1. Start the command-line agent configuration tool.


2. Select 5 to enter the SAP HANA Connection menu.
3. Select 2 to connect to SAP HANA via TCP.
4. Specify whether to use SSL over TCP.

○ If you want to use SSL and the agent has already been prepared, choose true.
○ If you do not want to use SSL or the agent has not already been prepared, choose false.

For more information about preparing the agent for SSL, see Configuring SSL [page 498].
5. Specify the hostname, port, and Agent Admin HANA User credentials for the SAP HANA server as
prompted.

 Tip

To determine the correct port number when SAP HANA is deployed in a multi-database configuration,
execute the following SQL statement:

SELECT DATABASE_NAME,SERVICE_NAME,PORT,SQL_PORT,(PORT + 2) HTTP_PORT


FROM SYS_DATABASES.M_SERVICES WHERE DATABASE_NAME='<DBNAME>' and
((SERVICE_NAME='indexserver' and COORDINATOR_TYPE= 'MASTER') or
(SERVICE_NAME='xsengine'))

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 55
Results

The configuration tool connects to the SAP HANA server.

Related Information

Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Start the Configuration Tool [Command Line] [page 51]
Assign Roles and Privileges [page 25]

2.5.1.4 Connect to the SAP HANA Service via JDBC


WebSockets [Command Line]

Connect to SAP HANA using JDBC WebSockets when you are using the SAP Cloud Platform, SAP HANA
service in the Cloud Foundry environment.

Prerequisites

● You are using the SAP Cloud Platform, SAP HANA service with the SAP HANA Data Provisioning Server
capability.
● You have installed the Data Provisioning Agent to an on-premise or cloud-based host system.
● The Agent Admin HANA User must have the following roles or privileges to perform the actions noted in
the table below:

Table 6: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA ○ System privilege: AGENT ADMIN


○ System privilege: ADAPTER ADMIN

Create the HANA User for Agent Messag­ ○ System privilege: USER ADMIN
ing (Optional)
 Note
These privileges are required only when you want to create the HANA
User for Agent Messaging as part of the configuration process within
the agent configuration tool.

You have an SAP HANA User for Agent Messaging for messaging between the agent and SAP HANA. To create
such a user manually:

1. Create the agent user (for example, AGTUSR) with a non-expiring password.

Installation and Configuration Guide


56 PUBLIC Configure Smart Data Integration
2. GRANT AGENT MESSAGING ON AGENT "<your_agent_name>" TO AGTUSR;

 Tip

If the Agent Admin HANA User has been granted the privileges indicated in the “Roles and Privileges” table,
it can create the HANA User for Agent Messaging during the configuration process. The configuration tool
creates the HANA User for Agent Messaging as a technical user with the no expiration period for the
password.

 Note

In general, the password for a new SAP HANA user expires according to the SAP HANA password policy
settings, the default for which is 182 days. To avoid agent disruptions in a production scenario, treat a new
HANA User for Agent Messaging as a technical user and ensure that its password does not expire.

For more information about configuring the password policy for a technical user in SAP HANA, see the SAP
HANA Security Guide.

Context

The Data Provisioning Agent connects to the SAP HANA service through JDBC WebSockets.

Procedure

1. Start the command-line agent configuration tool.


2. Choose SAP HANA Connection.
3. Choose Connect to SAP HANA via JDBC.
4. Specify true to use an encrypted connection over JDBC.

 Tip

An encrypted connection is always required when connecting to SAP HANA in a cloud-based


environment.

5. Specify true to use WebSockets instead of a Direct SQL connection.


6. Specify the WebSocket URL, host, and port for the SAP HANA service as prompted.

For example:
○ WebSocket URL: /service/<service_instance_id>
○ WebSocket Host: <instance_name>.dbaas.ondemand.com
○ WebSocket Port: 80
7. Specify the Agent Admin HANA User credentials for SAP HANA as prompted.
8. If HTTPS traffic from your agent host is routed through a proxy, specify any required proxy information as
prompted.
The agent uses the HTTPS protocol to communicate with the SAP HANA service.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 57
9. Specify the credentials for the HANA User for Agent Messaging.
The HANA User for Agent Messaging is used only for messaging between the agent and SAP HANA, and
must be different from the Agent Admin HANA User used to connect to SAP HANA.
10. Specify whether the HANA User for Agent Messaging is an existing user.

○ Enter true if the user already exists.


○ Enter false if you want the configuration tool to create a user with the specified credentials.

 Tip

Generally, you create this user only during the initial configuration of an agent instance. If you are
modifying the configuration of an existing agent instance, you usually do not need to create a user.

Results

The configuration tool creates the SAP HANA User for Agent Messaging, if applicable, and connects to the SAP
HANA server.

Related Information

JDBC Connection Properties [page 58]


Password Policy Configuration Options (SAP HANA Administration Guide)
Start the Configuration Tool [Command Line] [page 51]
Configuring SSL [page 498]
JDBC Connection Properties [page 58]

2.5.1.4.1 JDBC Connection Properties

When connecting to an SAP HANA database or to a remote source using JDBC, there are several connection
properties that you can configure.

Default Properties

The following table lists the default JDBC connection properties, which are case insensitive, available in the
agentcli tool and are written to the <DPAgent_root>\dpagentconfig.ini file.

Installation and Configuration Guide


58 PUBLIC Configure Smart Data Integration
Property Value Default Description

jdbc.communicationT <number> 330 Aborts communication after


imeout the specified timeout. Set­
ting this parameter to 0 disa­
bles the timeout.

jdbc.connections <number> 10 Specifies the maximum num­


ber of JDBC connections.

jdbc.enabled Boolean FALSE Specifies whether to use


JDBC for message communi­
cation.

jdbc.encrypt Boolean FALSE Enables or disables TLS/SSL


encryption.

jdbc.host <name> localhost Specifies the JDBC host


name.

jdbc.hostNameInCert <name> * Specifies the host name used


ificate to verify server’s identity.

The host name specified here


is used to verify the identity
of the server instead of the
host name with which the
connection was established.

For example, in a single-host


system, if a connection is es­
tablished from a client on the
same host as the server, a
mismatch would arise be­
tween the host named in the
certificate (actual host
name) and the host used to
establish the connection (lo­
calhost).

 Note
If you specify * as the
host name, this property
has no effect. Other wild­
cards aren’t permitted.

jdbc.port <number> 30015 Specifies the JDBC port


number.

jdbc.proxyHost <name> proxy Specifies the JDBC proxy


host name.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 59
Property Value Default Description

jdbc.proxyHttp Boolean FALSE When using a proxy, this pa­


rameter specifies whether
it’s an HTTP proxy (true) or a
SOCKS proxy (false).

 Note
There's no support for
WebSocket (HTTP/
HTTPS) connections
with a SOCKS proxy.
WebSocket connections
must either use no proxy
or an HTTP proxy. Non-
WebSocket (TCP/TLS,
via Direct SQL, for exam­
ple) connections can use
no proxy, a SOCKS
proxy, or an HTTP proxy.

jdbc.proxyPassword <String> Empty Specifies the JDBC proxy


password.

jdbc.proxyPort <number> 8080 Specifies the JDBC proxy


port number.

jdbc.proxyUsername <String> Empty Specifies the JDBC proxy


user name.

jdbc.reconnectRetri <number> 10 Specifies the maximum num­


es ber of connect retires.

jdbc.reconnectTime <number> 30 Specifies the amount of time


to wait before JDBC attempts
a new registration.

jdbc.retryMax <number> 10 Specifies the maximum num­


ber of send retries.

jdbc.retryTime <number> 5 Specifies the amount of time


to wait before resending the
message.

jdbc.sniHostname <name> Empty Specifies the name of the


host that is attempting to
connect at the start of the
TLS handshaking process.

jdbc.timeout <number> 60 Specifies the amount of time


to wait for an available JDBC
connection.

jdbc.timeUnit DAYS, HOURS, MICROSEC­ SECONDS Specifies the JDBC time unit.
ONDS, MILLISECONDS, MI­
NUTES, NANOSECONDS,
SECONDS

Installation and Configuration Guide


60 PUBLIC Configure Smart Data Integration
Property Value Default Description

jdbc.useProxy Boolean FALSE Specifies whether to use


proxy properties for the
JDBC connection.

jdbc.useProxyAuth Boolean FALSE Specifies whether to use


proxy authentication. If true,
you must provide a proxy
username and password.

jdbc.useWebsocketUR Boolean FALSE Specifies whether to use


L WebSocket properties for the
JDBC connection.

jdbc.validateCertif Boolean FALSE If set to true, specifies that


icate the server’s certificate is vali­
dated.

jdbc.websocketURL <websocket URL> Empty Specifies the JDBC Web­


Socket URL

jdbc.additionalPara <String> Empty Additional parameters to


meters pass to the JDBC driver.

Any property that isn’t sup­


ported in the
dpagentconfig.ini file
(that is, not listed here), but
is supported by the SAP
HANA JDBC driver, can be
specified using
jdbc.additionalPara
meters property.

Entries in the
jdbc.additionalPara
meters must be specified
with a comma delimiter when
there are multiple parame­
ters. For example, jdbc.addi­
tionalParameters=recon­
nect=TRUE,ignoreTopol­
ogy=FALSE

 Note
These additional proper­
ties aren’t prepended
with “jdbc”.

There are other SAP HANA-specific properties available in addition to the properties listed here. See the SAP
HANA Client Interface Programming Reference for SAP HANA Platform for more information.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 61
Related Information

[SAP HANA] JDBC Connection Properties

2.5.1.5 Connect to SAP HANA in the SAP Cloud Platform


Neo Environment [Command Line]

Specify connection information, user credentials, and SSL configuration information when SAP HANA is
deployed in the SAP Cloud Platform Neo environment.

 Caution

This topic applies only to SAP HANA in the SAP Cloud Platform Neo environment. For information about
connecting to the SAP Cloud Platform, SAP HANA service in the Cloud Foundry environment, see Connect
to the SAP HANA Service via JDBC WebSockets [Command Line] [page 56].

When SAP HANA is in the cloud, the agent initiates all communication. The agent polls the server to see if there
are any messages for the agent to act upon.

Prerequisites

● The Data Provisioning delivery unit must be imported to the SAP HANA system.
● The Agent Admin HANA User must have the following roles or privileges:

Table 7: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA ○ Application privilege:


sap.hana.im.dp.admin::Administrator
○ System privilege: AGENT ADMIN
○ System privilege: ADAPTER ADMIN

Create HANA User for Agent Messaging ○ System privilege: USER ADMIN
(Optional) ○ Object privilege: EXECUTE on
GRANT_APPLICATION_PRIVILEGE

 Note
These privileges are required only when you want to create the HANA
User for Agent Messaging as part of the configuration process within
the agent configuration tool.

● The HANA User for Agent Messaging must have the following roles or privileges:

Installation and Configuration Guide


62 PUBLIC Configure Smart Data Integration
Table 8: Roles and Privileges
Action Role or Privilege

Messaging between the agent and SAP Application privilege:


HANA sap.hana.im.dp.proxy::AgentMessaging

 Tip

If the Agent Admin HANA User has been granted the privileges indicated in the “Roles and Privileges”
table, it can create the HANA User for Agent Messaging during the configuration process. The
configuration tool creates the HANA User for Agent Messaging as a technical user with the no
expiration period for the password.

 Note

In general, the password for a new SAP HANA user expires according to the SAP HANA password
policy settings, the default for which is 182 days. To avoid agent disruptions in a production scenario,
treat a new HANA User for Agent Messaging as a technical user and ensure that its password does not
expire.

For more information about configuring the password policy for a technical user in SAP HANA, see the
SAP HANA Security Guide.

Procedure

1. Start the command-line agent configuration tool.


2. Choose SAP HANA Connection.
3. Choose Connect to SAP HANA on Cloud (HTTP/HTTPS).
4. Specify whether to use HTTPS when connecting to SAP HANA.

 Note

If the agent framework keystore does not already have the certificates for the SAP HANA server, the
configuration tool automatically downloads and imports them during configuration.

5. Specify the hostname, port, and Agent Admin HANA User credentials for SAP HANA as prompted.

The hostname should include the instance name. For example,


<your_instance_name>.hana.ondemand.com.
6. If there is a firewall between SAP HANA and the agent host, specify any required proxy information as
prompted.
7. Specify the credentials for the HANA User for Agent Messaging.
The HANA User for Agent Messaging is used only for messaging between the agent and SAP HANA, and
must be different from the Agent Admin HANA User used to connect to SAP HANA.
8. Specify whether the HANA User for Agent Messaging is an existing user.

○ Enter true if the user already exists.


○ Enter false if you want the configuration tool to create a user with the specified credentials.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 63
 Tip

Generally, you create this user only during the initial configuration of an agent instance. If you are
modifying the configuration of an existing agent instance, you usually do not need to create a user.

Results

The configuration tool creates the HANA User for Agent Messaging, if applicable, and connects to the SAP
HANA server.

Related Information

Password Policy Configuration Options (SAP HANA Administration Guide)


Download and Deploy the Data Provisioning Delivery Unit [page 33]
Start the Configuration Tool [Command Line] [page 51]

2.5.1.6 Manage the Agent Service [Command Line]

Use the command-line configuration tool to stop or start the Data Provisioning Agent service.

Procedure

1. Start the command-line agent configuration tool.


2. Select 2 to enter the Start or Stop Agent menu.
3. Select 1 to start the agent or 2 to stop the agent.

Results

The configuration tool indicates whether the agent service is running and the listening port in use by the agent.

Next Steps

On Windows, you can also manage the agent service from the standard Windows Services tool. The name of
the service is SAP_HANA_SDI_Agent_Service_Daemon_<instance_name>.

Installation and Configuration Guide


64 PUBLIC Configure Smart Data Integration
On Linux, you can also manage the agent with a shell script. The shell script is located at
<DPAgent_root>/bin/dpagent_servicedaemon.sh and supports the following commands:

● ./dpagent_servicedaemon.sh start
● ./dpagent_servicedaemon.sh stop

Related Information

Start the Configuration Tool [Command Line] [page 51]

2.5.1.7 Register the Agent with SAP HANA [Command


Line]

Before you can use adapters deployed on the Data Provisioning Agent, you must register the agent with SAP
HANA.

Prerequisites

● The Agent Admin HANA User must have the following roles or privileges:

Table 9: Roles and Privileges


Action Role or Privilege

Register adapter System privilege: AGENT ADMIN

● For SAP HANA on Cloud, the Agent XS HANA User must have the following roles or privileges:

Table 10: Roles and Privileges


Action Role or Privilege

Register adapter System privilege: AGENT ADMIN

Messaging between the agent and SAP Application privilege:


HANA on Cloud sap.hana.im.dp.proxy::AgentMessaging

Procedure

1. Start the command-line agent configuration tool and connect to SAP HANA.
2. Select 6 to enter the Agent Registration menu.
3. Select 1 to register the agent.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 65
4. Specify the agent connection information as prompted.

 Caution

When you are asked for input entry for an option, you cannot cancel or return to the previous menu. To
abort the operation without saving, you must press Ctrl + C to terminate the configuration tool.

○ If SAP HANA is not in the cloud, specify the agent name and hostname.
Ensure that the SAP HANA server can communicate with the agent host. Depending on the network
configuration, you may need to qualify the agent hostname fully.
Ensure that your firewall settings allow the connection from the SAP HANA server to the agent host on
the listener port. By default, the listener is port 5050.
○ If SAP HANA is in the cloud, specify the agent name.
When SAP HANA is in the cloud, the agent service restarts to complete the registration process.
5. Press Enter to continue.

Results

The agent is registered with SAP HANA. If SAP HANA is in the cloud, the agent service automatically restarts.

Next Steps

To unregister the agent, select 2 in the Agent Registration menu.

 Caution

Unregistering the agent from the SAP HANA server performs a cascade drop of the agent. As a result, any
remote subscriptions that use the agent are also deleted, even if they are active.

Related Information

Start the Configuration Tool [Command Line] [page 51]

Installation and Configuration Guide


66 PUBLIC Configure Smart Data Integration
2.5.1.8 Manage the HANA User for Agent Messaging
Credentials [Command Line]

If the password for the HANA User for Agent Messaging has changed or expired, you must update the
credentials in the agent secure storage.

Context

To set the new credentials in the agent secure storage, use the agent configuration tool in command-line
interactive mode.

Procedure

1. At the command line, navigate to <DPAgent_root>/bin.


2. Execute one of the following commands using the --setSecureProperty parameter:

On Windows, agentcli.bat --setSecureProperty

On Linux, ./agentcli.sh --setSecureProperty


3. If you want to use a different HANA User for Agent Messaging, choose Set HANA XS Username and enter
the new username as prompted.
4. Choose Set HANA XS Password and enter the new password as prompted.
5. Restart the Data Provisioning Agent.

 Caution

When the agent restarts, any real-time subscriptions configured on the agent are terminated and must
be reconfigured.

Related Information

Manage the Agent Service [Command Line] [page 64]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 67
2.5.1.9 Store Source Database Credentials in Data
Provisioning Agent [Command Line]

Store source database access credentials in the Data Provisioning Agent secure storage using batch mode.

Context

If you don't want to store credentials in SAP HANA, you can store them in the Data Provisioning Agent secure
storage.

Entering credentials in the Data Provisioning Agent requires three components: remote source name, user
name and password. This method of storing credentials also gives you more management flexibility by allowing
you to edit and delete whenever you want.

Procedure

1. Start the command-line agent configuration tool.


2. Select 4 to enter the Remote Source Credentials menu.
3. Select 2 to add credentials.
4. Enter the remote source name, user name, and password (and confirmation), and press Enter.

Results

You can now access these credentials to connect to a remote source through the Use Agent Stored Credential
remote source configuration parameter for your adapter. You can also use this editor to view, delete, and edit
credentials.

Related Information

SAP HANA Remote Source Configuration [page 444]


IBM DB2 Mainframe Remote Source Configuration [page 286]
DB2 Log Reader Remote Source Configuration [page 270]
Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

Installation and Configuration Guide


68 PUBLIC Configure Smart Data Integration
2.5.2 Configuring the Agent in Command Line Batch Mode

Use the command-line configuration tool to connect to the SAP HANA server and configure the Data
Provisioning Agent and adapters.For example, you can use the configuration tool to view the agent and adapter
statuses and versions, manage custom and SAP-delivered adapters, and modify keystore paths.

 Tip

Combine sequences of individual batch commands into scripts for tasks such as silent configuration with
no user interaction or automated configuration.

Execute Single Configuration Commands [page 70]


Execute single commands to perform individual configuration tasks, or automate agent configuration
by grouping multiple commands into a script.

Supported Configuration Functions [Batch] [page 71]


Perform configuration tasks by specifying a supported batch mode function.

Connecting to SAP HANA [Batch] [page 73]


Connect the Data Provisioning Agent to SAP HANA in batch mode by specifying parameters that
depend on your scenario.

Manage the Agent XS HANA User Credentials [Batch] [page 81]


If the Agent XS HANA User password has changed or expired, you may need to update the credentials
in the agent's secure storage.

Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store source database access credentials in the Data Provisioning Agent secure storage using batch
mode.

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 69
2.5.2.1 Execute Single Configuration Commands

Execute single commands to perform individual configuration tasks, or automate agent configuration by
grouping multiple commands into a script.

Prerequisites

The command-line agent configuration tool requires the DPA_INSTANCE environment variable to be set to the
installation root location (<DPAgent_root>).

For example, on Windows:

set DPA_INSTANCE=C:\usr\sap\dataprovagent

On Linux:

export DPA_INSTANCE=/usr/sap/dataprovagent

 Caution

Multiple instances of the Data Provisioning Agent may be installed on a single Linux host. Be sure that you
set DPA_INSTANCE to the instance that you want to modify before starting the configuration tool. If you do
not set the environment variable correctly, you may unintentionally modify the configuration of a different
agent instance.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Execute the command using the --configAgent parameter.
Specify the function to perform with the --function <function> parameter.

On Windows, agentcli.bat --configAgent --function <function>


[<additional_parameters>]

On Linux, ./agentcli.sh --configAgent --function <function>


[<additional_parameters>]

Results

The command executes without extra input.

Installation and Configuration Guide


70 PUBLIC Configure Smart Data Integration
2.5.2.2 Supported Configuration Functions [Batch]

Perform configuration tasks by specifying a supported batch mode function.

Table 11: Supported Functions


Function Description Parameters and Notes

adapterStatus Displays the status of adapters on


the agent instance  Restriction
Connect the configuration tool to SAP HANA before
using this function.

adapterVersions Displays the version of adapters (Optional) --adapter.name <adapter_name>


on the agent instance
 Note
<adapter_name> must match the name displayed
by adapterStatus. If you do not specify the --
adapter.name parameter, all adapter versions dis­
play.

agentComponentVer Displays the version for all compo­


sions nents of the agent instance

agentPreferences Sets adapter framework preferen­ --D<name>=<value>


ces
For preference details, see Agent Adapter Framework
Preferences [page 104]

agentStatus Displays the status of the agent in­


stance

agentVersion Displays the version of the agent


instance

configureAdapters Configures the SSL keystore used


Keystore by adapters on the agent instance

configureAdapters Configures the SSL truststore


Truststore used by adapters on the agent in­
stance

configureFramewor Configures the SSL keystore used


kKeystore by the agent framework  Note
If you do not specify the -
Dframework.keystore.key.password pa­
rameter, the keystore password is used for both the
keystore and individual keys. This value is checked
only if a key password was specified during key gener­
ation in the keytool utility.

connectHanaViaHTT Connects to the SAP HANA server For parameter details, see Connecting to SAP HANA
P using HTTP or HTTPS [Batch] [page 73]

connectHanaViaTCP Connects to an on-premise SAP For parameter details, see Connecting to SAP HANA
HANA server using TCP [Batch] [page 73]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 71
Function Description Parameters and Notes

deployAdapter Deploys a custom adapter on the --adapter.filepath <path_to_jar_file>


agent instance

pingAgent Pings the agent instance to verify


connectivity

registerAdapter Registers an adapter with the SAP --adapter.name <adapter_name>


HANA server
 Note
<adapter_name> must match the name displayed
by adapterStatus.

 Restriction
Connect the configuration tool to SAP HANA before
using this function.

registerAgent Registers the agent instance with -Dagent.name=<agent_name>


the SAP HANA server
For TCP only: -Dagent.hostname=<hostname>

 Restriction
Connect the configuration tool to SAP HANA before
using this function.

showAgentPreferen Displays agent framework prefer­


ces ences

showKeystores Displays all keystores for the agent


instance

startAgent Starts the agent service

stopAgent Stops the agent service

undeployAdapter Undeploys a custom adapter from --adapter.name <adapter_name>


the agent instance
 Note
<adapter_name> must match the name displayed
by adapterStatus.

unregisterAdapter Unregisters an adapter from the --adapter.name <adapter_name>


SAP HANA server
 Note
<adapter_name> must match the name displayed
by adapterStatus.

 Restriction
Connect the configuration tool to SAP HANA before
using this function.

Installation and Configuration Guide


72 PUBLIC Configure Smart Data Integration
Function Description Parameters and Notes

unregisterAgent Unregisters the agent instance


from the SAP HANA server  Restriction
Connect the configuration tool to SAP HANA before
using this function.

Accessing Help for Batch Functions

The configuration tool provides help for each supported command and function, including required and
optional parameters and usage information. To view the help for a command or function, append --help to
the command.

For example, to view the help for the connectHanaViaHttp configuration function:

agentcli.bat --configAgent --function connectHanaViaHttp --help

2.5.2.3 Connecting to SAP HANA [Batch]

Connect the Data Provisioning Agent to SAP HANA in batch mode by specifying parameters that depend on
your scenario.

To connect to the SAP HANA server in batch mode, use the connectHanaViaTcp or connectHanaViaHTTP
function and specify any additional parameters relevant to your system landscape.

Common Connection Parameters

Parameters related to the SAP HANA server and administrator user are required in all connection scenarios.

Table 12: Required Parameters


Parameter Description

-Dhana.server=<hostname> Hostname of the SAP HANA server

-Dhana.port=<port> Port used to connect to the SAP HANA server

-Dhana.admin.username=<username> Name of the Agent Admin HANA User that connects to the SAP
HANA server

- Path to the file that contains the Agent Admin HANA User password
Dhana.admin.password=<password_path
>

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 73
 Tip

To determine the correct port number when SAP HANA is deployed in a multi-database configuration,
execute the following SQL statement:

SELECT DATABASE_NAME,SERVICE_NAME,PORT,SQL_PORT,(PORT + 2) HTTP_PORT


FROM SYS_DATABASES.M_SERVICES WHERE DATABASE_NAME='<DBNAME>' and
((SERVICE_NAME='indexserver' and COORDINATOR_TYPE= 'MASTER') or
(SERVICE_NAME='xsengine'))

Related Information

Connecting to SAP HANA On-premise [Batch] [page 74]


Connect to SAP HANA via JDBC WebSockets or Direct SQL [Batch] [page 75]
Connect to SAP HANA in the SAP Cloud Platform Neo Environment [Batch] [page 79]

2.5.2.3.1 Connecting to SAP HANA On-premise [Batch]

Connect to SAP HANA on-premise with the connectHanaViaTcp function of the command-line configuration
tool. In addition to the common parameters, additional connection parameters are required.

Prerequisites

● The Agent Admin HANA User must have the following roles or privileges:

Table 13: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA System privilege: AGENT ADMIN

System privilege: ADAPTER ADMIN

● If the SAP HANA server is configured for SSL, the agent host must already be prepared for SSL.

Installation and Configuration Guide


74 PUBLIC Configure Smart Data Integration
More Connection Parameters

Table 14: More Parameters


Parameter Description

-Dframework.enableSSL=<value> Specifies whether the connection uses SSL encryption

Allowed values: true or false

Example: Connect to SAP HANA On-premise with TCP

agentcli.bat --configAgent --function connectHanaViaTcp


-Dframework.enableSSL=false -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<username> -Dhana.admin.password=<password_path>

Example: Connect to SAP HANA On-premise with TCP and SSL

agentcli.bat --configAgent --function connectHanaViaTcp


-Dframework.enableSSL=true -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<username> -Dhana.admin.password=<password_path>

 Note

The agent host must already be configured for SSL.

Related Information

Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]

2.5.2.3.2 Connect to SAP HANA via JDBC WebSockets or


Direct SQL [Batch]

Connect to SAP HANA via JDBC WebSockets or Direct SQL with the connectHanaViaJdbc function of the
command-line configuration tool. In addition to the required parameters, additional optional connection
parameters may be needed for your configuration.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 75
Prerequisites

● The Data Provisioning delivery unit must be imported to the SAP HANA system.
● The Agent Admin HANA User must have the following roles or privileges:

Table 15: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA ○ System privilege: AGENT ADMIN


○ System privilege: ADAPTER ADMIN

Create the HANA User for Agent Messag­ ○ System privilege: USER ADMIN
ing (Optional)
 Note
These privileges are required only when you want to create the HANA
User for Agent Messaging as part of the configuration process within
the agent configuration tool.

● You have an SAP HANA User for Agent Messaging for messaging between the agent and SAP HANA. To
create such a user manually:
1. Create the agent user (for example, AGTUSR) with a non-expiring password.
2. GRANT AGENT MESSAGING ON AGENT "<your_agent_name>" TO AGTUSR;

 Tip

If the Agent Admin HANA User has been granted the privileges indicated in the “Roles and Privileges”
table, it can create the HANA User for Agent Messaging during the configuration process. The
configuration tool creates the HANA User for Agent Messaging as a technical user with the no
expiration period for the password.

 Note

In general, the password for a new SAP HANA user expires according to the SAP HANA password
policy settings, the default for which is 182 days. To avoid agent disruptions in a production scenario,
treat a new HANA User for Agent Messaging as a technical user and ensure that its password does not
expire.

For more information about configuring the password policy for a technical user in SAP HANA, see the
SAP HANA Security Guide.

Required Connection Parameters

Table 16: Required Parameters


Parameter Description

-Dhana.admin.username=<username> Specifies the name of the Agent Admin HANA User that connects to
the SAP HANA server

Installation and Configuration Guide


76 PUBLIC Configure Smart Data Integration
Parameter Description

- Specifies the path to the file that contains the password for the
Dhana.admin.password=<password_path Agent Admin HANA User
>

-Dhana.xs.username=<username> Specifies the name of the HANA User for Agent Messaging

- Specifies the path to the file that contains the password for the
Dhana.xs.password=<path_to_password HANA User for Agent Messaging
>

Additional Connection Parameters

Table 17: Optional Parameters


Parameter Description

-Djdbc.encrypt=<value> Specifies whether to use an encrypted JDBC connection

Allowed values: true or false

Default: true

-Djdbc.useWebsocketURL=<value> Specifies whether to use JDBC WebSockets or Direct SQL

Allowed values: true or false

Default: true

To use Direct SQL to connect to SAP HANA, specify false.

-Djdbc.websocketURL=<value> Specifies the URL to use for the JDBC WebSockets connection

For example, /service/<service_instance_id>

-Djdbc.host=<value> Specifies the JDBC WebSocket host

For Direct SQL, specifies the hostname of the SAP HANA server.

-Djdbc.port=<value> Specifies the JDBC WebSocket port

For Direct SQL, specifies the port used to connect to the SAP HANA
server.

-Djdbc.useProxy=<value> Specifies whether to use a proxy for the JDBC WebSockets or Direct
SQL connection

Allowed values: true or false

Default: false

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 77
Parameter Description

-Djdbc.proxyHttp=<value> Specifies whether the proxy uses HTTP or SOCKS

Allowed values: true or false

Default: false

To use an HTTP proxy, specify true.

 Restriction
SOCKS proxies are not supported when using JDBC WebSock­
ets to connect to SAP HANA.

-Djdbc.proxyHost=<value> Specifies the host name of the HTTP or SOCKS proxy

-Djdbc.proxyPort=<value> Specifies the port used by the HTTP or SOCKS proxy

-Djdbc.useProxyAuth=<value> Specifies whether the proxy requires authentication

Allowed values: true or false

Default: false

-Djdbc.proxyUserName=<value> Specifies the user name to use for proxy authentication

-Djdbc.proxyPassword=<value> Specifies the path to the file that contains the password used for
proxy authentication

--hana.xs.createUser <value> Specifies whether or not the configuration program should create
an Agent XS HANA User

To use an existing Agent XS HANA User, specify false.

Example: Connect to SAP HANA via JDBC WebSockets and HTTP Proxy
without Authentication

agentcli.bat --configAgent --function connectHanaViaJdbc -


Dhana.admin.username=<username>
-Dhana.admin.password=<password_path> -Dhana.xs.username=<username>
-Dhana.xs.password=<password_path> -Djdbc.encrypt=false -
Djdbc.useWebSocketURL=true
-Djdbc.host=<hana_hostname> -Djdbc.port=<hana_sql_port>
-Djdbc.useProxy=true -Djdbc.proxyHttp=true -Djdbc.proxyHost=<http_proxy_hostname>
-Djdbc.proxyPort=<http_proxy_port> -Djdbc.useProxyAuth=false

Example: Connect to SAP HANA via Direct SQL and SOCKS Proxy with
Authentication

agentcli.bat --configAgent --function connectHanaViaJdbc -


Dhana.admin.username=<username>

Installation and Configuration Guide


78 PUBLIC Configure Smart Data Integration
-Dhana.admin.password=<password_path> -Dhana.xs.username=<username>
-Dhana.xs.password=<password_path> -Djdbc.encrypt=false -
Djdbc.useWebsocketURL=false
-Djdbc.host=<hana_hostname> -Djdbc.port=<hana_sql_port>
-Djdbc.useProxy=true -Djdbc.proxyHttp=false -
Djdbc.proxyHost=<socks_proxy_hostname>
-Djdbc.proxyPort=<socks_proxy_port> -Djdbc.useProxyAuth=true
-Djdbc.proxyUserName=<username> -Djdbc.proxyPassword=<password_path>

2.5.2.3.3 Connect to SAP HANA in the SAP Cloud Platform


Neo Environment [Batch]

Connect to SAP HANA on cloud with the connectHanaViaHttp function of the command-line configuration
tool. In addition to the common parameters, extra connection parameters are required.

Prerequisites

● The Data Provisioning delivery unit must be imported to the SAP HANA system.
● The Agent Admin HANA User must have the following roles or privileges:

Table 18: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA ○ Application privilege:


sap.hana.im.dp.admin::Administrator
○ System privilege: AGENT ADMIN
○ System privilege: ADAPTER ADMIN

Create Agent XS HANA User ○ System privilege: USER ADMIN


○ Object privilege: EXECUTE on
GRANT_APPLICATION_PRIVILEGE

● The Agent XS HANA User must have the following roles or privileges:

Table 19: Roles and Privileges


Action Role or Privilege

Messaging between the agent and SAP ○ Application privilege:


HANA on Cloud sap.hana.im.dp.proxy::AgentMessaging

 Tip

The configuration tool can create the Agent XS HANA User during the agent configuration process as
long as the Agent Admin HANA User has been granted the correct privileges.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 79
Extra Connection Parameters

Table 20: Extra Parameters


Parameter Description

-Dhana.useSSL=<value> Specifies whether the connection uses SSL encryption

Allowed values: true or false

-Dcloud.useProxy=<value> Specifies whether a proxy is required for the connection

Allowed values: true or false

-Dcloud.useProxyAuth=<value> Specifies whether proxy authorization is required

Allowed values: true or false

-Dhana.xs.username=<username> Name of the Agent XS HANA User for messaging between the Data
Provisioning Agent and the SAP HANA server

- Path to the file that contains the Agent XS HANA User password
Dhana.xs.password=<path_to_password
>

--hana.xs.createUser <value> Specifies whether or not the configuration program should create
an Agent XS HANA User

To use an existing Agent XS HANA User, specify false.

Example: Connect to SAP HANA on Cloud with HTTP

agentcli.bat --configAgent --function connectHanaViaHttp


-Dhana.useSSL=false -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<admin_username> -
Dhana.admin.password=<admin_password_path>
-Dhana.xs.username=<xs_username> -Dhana.xs.password=<xs_password_path> --
hana.xs.createUser false

Example: Connect to SAP HANA on Cloud with HTTP and Create Agent XS
HANA User

agentcli.bat --configAgent --function connectHanaViaHttp


-Dhana.useSSL=false -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<admin_username> -
Dhana.admin.password=<admin_password_path>
-Dhana.xs.username=<xs_username> -Dhana.xs.password=<xs_password_path> --
hana.xs.createUser true

Installation and Configuration Guide


80 PUBLIC Configure Smart Data Integration
Example: Connect to SAP HANA on Cloud with HTTPS

agentcli.bat --configAgent --function connectHanaViaHttp


-Dhana.useSSL=true -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<admin_username> -
Dhana.admin.password=<admin_password_path>
-Dhana.xs.username=<xs_username> -Dhana.xs.password=<xs_password_path> –-
hana.xs.createUser false

Example: Connect to SAP HANA on Cloud with HTTPS and Proxy

agentcli.bat --configAgent --function connectHanaViaHttp


-Dhana.useSSL=true -Dhana.server=<hostname> -Dhana.port=<port>
-Dhana.admin.username=<admin_username> -
Dhana.admin.password=<admin_password_path>
-Dhana.xs.username=<xs_username> -Dhana.xs.password=<xs_password_path> --
hana.xs.createUser false
-Dcloud.useProxyAuth=false -Dcloud.useProxy=true –DproxyHost=<proxy_hostname> –
DproxyPort=<proxy_port>

2.5.2.4 Manage the Agent XS HANA User Credentials


[Batch]

If the Agent XS HANA User password has changed or expired, you may need to update the credentials in the
agent's secure storage.

Context

Use the agent configuration tool in command-line interactive mode to set the new credentials in the agent's
secure storage.

Procedure

1. At the command line, navigate to <DPAgent_root>/bin.


2. Execute the commands using the --setSecureProperty parameter.
a. If you want to use a different Agent XS HANA User, specify the setHanaXsUsername function.

On Windows, agentcli.bat --setSecureProperty --function setHanaXsUsername --


file <username_file_path>

On Linux, ./agentcli.sh --setSecureProperty --function setHanaXsUsername --file


<username_file_path>

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 81
b. Specify the setHanaXsPassword to set the new password.

On Windows, agentcli.bat --setSecureProperty --function setHanaXsPassword --


file <password_file_path>

On Linux, ./agentcli.sh --setSecureProperty --function setHanaXsPassword --file


<password_file_path>
3. Restart the Data Provisioning Agent.

 Caution

When the agent restarts, any real-time subscriptions configured on the agent are terminated and you
may need to configure the real-time subscriptions again.

2.5.2.5 Store Source Database Credentials in Data


Provisioning Agent [Batch]

Store source database access credentials in the Data Provisioning Agent secure storage using batch mode.

Context

If you don't want to store credentials in SAP HANA, you can store them in the Data Provisioning Agent secure
storage.

Entering credentials in the Data Provisioning Agent requires three components: remote source name, user
name and password. This method of storing credentials also gives you more management flexibility by allowing
you to edit and delete whenever you want.

Procedure

1. List all remote credentials stored in Data Provisioning Agent.

bin/agentcli.sh --configAgent --function listCredentials

2. Add a new remote credential.

bin/agentcli.sh --configAgent --function addCredentials


-Dadd.remoteCredential.remoteSourceName=<Remote Source Name>
-Dadd.remoteCredential.username=<User Name>
-Dadd.remoteCredential.password=<Password File>

3. Edit a new remote credential.

bin/agentcli.sh --configAgent --function editCredentials


-Dedit.originalRemoteCredential.remoteSourceName=<Original Remote Source Name>
-Dedit.originalRemoteCredential.username=<Original User Name>
-Dedit.remoteCredential.remoteSourceName=<New Remote Source Name>

Installation and Configuration Guide


82 PUBLIC Configure Smart Data Integration
-Dedit.remoteCredential.username=<New User Name>
-Dedit.remoteCredential.password=<Password file including New Password>

4. Delete a credential.

bin/agentcli.sh --configAgent --function delCredentials


-Ddel.remoteCredential.remoteSourceName=<Remote Source Name>
-Ddel.remoteCredential.username=<User Name>

Results

You can now access these credentials to connect to a remote source through the Use Agent Stored Credential
remote source configuration parameter for your adapter.

Related Information

SAP HANA Remote Source Configuration [page 444]


IBM DB2 Mainframe Remote Source Configuration [page 286]
DB2 Log Reader Remote Source Configuration [page 270]
Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

2.5.3 Configuring the Agent in Graphical Mode [Deprecated]

Connect to the SAP HANA server and configure the agent and adapters with the Data Provisioning Agent
Configuration tool.

 Caution

The graphical interface for the Data Provisioning Agent Configuration tool is deprecated.

For the latest supported functionality, use the command-line interface in interactive or batch mode. For
more information, see:

● Configuring the Agent in Command-Line Interactive Mode [page 50]


● Configuring the Agent in Command Line Batch Mode [page 69]

The configuration tool allows you to perform the following administrative tasks:

Start and Connect the Configuration Tool [page 84]


Before you can use the configuration tool to register the agent or deploy and register adapters, you
must connect to the SAP HANA server.

Manage the Agent Service [page 90]


Use the configuration tool to stop or start the agent service.

Register the Agent with SAP HANA [page 91]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 83
Before you can use adapters deployed on the Data Provisioning Agent, you must register the agent with
SAP HANA.

Reconfigure the Java Runtime Environment [page 92]


The SAP JVM is bundled with the Data Provisioning Agent and used as the default Java Runtime
Environment. You can choose to update the version of the SAP JVM used by an installed agent or
replace it with a custom Java Runtime Environment.

Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]
Store source database access credentials in the Data Provisioning Agent secure storage using the DP
Agent Configuration Tool.

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Command Line Batch Mode [page 69]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]

2.5.3.1 Start and Connect the Configuration Tool

Before you can use the configuration tool to register the agent or deploy and register adapters, you must
connect to the SAP HANA server.

The steps required to connect the Data Provisioning Agent to the SAP HANA server vary depending on whether
the SAP HANA server is installed on-premise or in the cloud, and whether it is configured for secure SSL
connections.

Connect to SAP HANA On-premise [page 85]


Specify connection information and user credentials when the SAP HANA system is located on-
premise and does not require a secure SSL connection.

Connect to SAP HANA on Cloud [page 86]


Specify connection information, user credentials, and SSL configuration information when the SAP
HANA system is located in the cloud.

Related Information

Installation and Configuration Guide


84 PUBLIC Configure Smart Data Integration
2.5.3.1.1 Connect to SAP HANA On-premise

Specify connection information and user credentials when the SAP HANA system is located on-premise and
does not require a secure SSL connection.

Prerequisites

The Agent Admin HANA User must have the following roles or privileges:

Table 21: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA System privilege: AGENT ADMIN

System privilege: ADAPTER ADMIN

Procedure

1. Navigate to the <DPAgent_root>/configTool directory.


2. Start the configuration tool.

○ On Windows, run dpagentconfigtool.exe.


○ On Linux, run ./dpagentconfigtool.

 Note

Start the configuration tool using the Data Provisioning Agent installation owner. The installation owner
is the same user that is used to start the agent service.

3. Connect to the SAP HANA server.


a. Click Connect to HANA.
b. Specify the hostname, port, and Agent Admin HANA User credentials for the SAP HANA server.

 Tip

To determine the correct port number when SAP HANA is deployed in a multi-database
configuration, execute the following SQL statement:

SELECT DATABASE_NAME,SERVICE_NAME,PORT,SQL_PORT,(PORT + 2) HTTP_PORT


FROM SYS_DATABASES.M_SERVICES WHERE DATABASE_NAME='<DBNAME>' and
((SERVICE_NAME='indexserver' and COORDINATOR_TYPE= 'MASTER') or
(SERVICE_NAME='xsengine'))

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 85
Related Information

Default Installation Paths [page 47]


Assign Roles and Privileges [page 25]

2.5.3.1.2 Connect to SAP HANA on Cloud

Specify connection information, user credentials, and SSL configuration information when the SAP HANA
system is located in the cloud.

When SAP HANA is in the cloud, the agent initiates all communication. The agent polls the server to see if there
are any messages for the agent to act upon.

Prerequisites

● The Data Provisioning delivery unit must be imported to the SAP HANA system.
● The Agent Admin HANA User must have the following roles or privileges.

Table 22: Roles and Privileges


Action Role or Privilege

Connect to SAP HANA ○ Application privilege:


sap.hana.im.dp.admin::Administrator
○ System privilege: AGENT ADMIN
○ System privilege: ADAPTER ADMIN

Create Agent XS HANA User ○ System privilege: USER ADMIN


○ Object privilege: EXECUTE on
GRANT_APPLICATION_PRIVILEGE

● The Agent XS HANA User must have the following roles or privileges.

Installation and Configuration Guide


86 PUBLIC Configure Smart Data Integration
Table 23: Roles and Privileges
Action Role or Privilege

Messaging between the agent and SAP ○ Application privilege:


HANA on Cloud sap.hana.im.dp.proxy::AgentMessaging

 Note
The password for a new SAP HANA user expires according to the SAP
HANA system's password policy settings, the default for which is 182
days. To avoid agent disruptions in a production scenario, we recom­
mend that the Agent XS HANA User is a technical user with a pass­
word that does not expire.

For more information about configuring the password policy for a


technical user in SAP HANA, see the SAP HANA Security Guide.

 Tip

The configuration tool can create the Agent XS HANA User during the agent configuration process as
long as the Agent Admin HANA User has been granted the correct privileges. The configuration tool
creates the Agent XS HANA User as a technical user with the default maximum password lifetime for
the SAP HANA system.

Procedure

1. Import the Data Provisioning Delivery Unit.

For complete information, see Download and Deploy the Data Provisioning Delivery Unit.
2. Create or grant privileges to the Agent Admin HANA User and Agent XS HANA User.
a. Configure the Agent Admin HANA User.

This user connects to the SAP HANA system via the configuration tool to perform administrative tasks,
such as registering agents and registering adapters.

Create a user or grant an existing user the following privileges:


○ Application privilege sap.hana.im.dp.admin::Administrator
○ System privilege AGENT ADMIN
○ System privilege ADAPTER ADMIN
b. Configure the Agent XS HANA User.

The Agent XS HANA User is used only for messaging between the Data Provisioning Agent and SAP
HANA on Cloud. The system saves the credentials for this user in the Data Provisioning Agent's secure
store for use at runtime.

 Caution

It is strongly recommended that this user has only the minimally required application privilege, and
no additional administrative privileges.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 87
Create a user or grant an existing user the following privilege:
○ Application privilege sap.hana.im.dp.proxy::AgentMessaging

 Tip

The Data Provisioning Agent Configuration tool can create the Agent XS HANA User during the
agent configuration process. If you want the configuration tool to create the user, ensure that the
Agent Admin HANA User has the correct roles and privileges.

For complete information about creating users and granting permissions, see the SAP HANA
Administration Guide.
3. Connect to the SAP HANA server.
a. Click Connect to HANA.
b. Select HANA On Cloud.
c. Select Use HTTPS.
When you attempt to connect to HANA on Cloud with HTTPS for the first time, the configuration tool
allows you to automatically download and import the SAP HANA server certificates into the Data
Provisioning Agent keystore.

 Note

If you prefer not to import the server certificates by this method, you must manually download and
import the certificates. For more information, see Manually Configure SSL for HANA on Cloud.

d. Specify the hostname, HTTP(s) port, and Agent Admin HANA User credentials for the SAP HANA
server.

The hostname should include the instance name. For example,


<your_instance_name>.hana.ondemand.com.
e. If there is a firewall between the SAP HANA server and the agent, specify any required proxy
information.
f. Specify the Agent XS HANA User credentials if the user already exists.

The Agent XS HANA User is used only for messaging between the Data Provisioning Agent and the
SAP HANA server, and must be different from the Agent Admin HANA User that you used to connect to
the SAP HANA server.
○ Choose Create User if you want the configuration tool to create a user.

 Tip

To create a user from the configuration tool, the Agent Admin HANA User that you use to
connect to the SAP HANA system must have the correct roles and privileges.

○ Choose Update User Credentials if you already specified an Agent XS HANA User and want to
change the user's credentials.
4. Register the Data Provisioning Agent with SAP HANA by specifying the agent name and clicking Register.

The agent service is stopped and restarted.

Installation and Configuration Guide


88 PUBLIC Configure Smart Data Integration
Related Information

Default Installation Paths [page 47]


Assign Roles and Privileges [page 25]
Password Policy Configuration Options (SAP HANA Administration Guide)
Download and Deploy the Data Provisioning Delivery Unit [page 33]

(Optional) Manually Configure SSL for HANA on Cloud

If you do not want to automatically download the SAP HANA server certificates the first time you attempt to
connect to HANA on Cloud, you must manually download and import the certificates.

Procedure

1. Obtain and import the SAP HANA server root certificate.


a. Download the SAP HANA server certificate to a location on the Data Provisioning Agent host machine.

For complete information, see Download the SAP HANA Server Certificate.
b. Import the SAP HANA server root certificate into the agent keystore.

keytool -importcert -keystore cacerts -storepass <store_password> -file


<certificate_filename>.der -noprompt

 Note

You need the password for the Java keytool program to generate a keystore and import the SAP
HANA server certificate. For the password, commands, and additional information, see the
keytool.txt file located at <DPAgent_root>\ssl\keytool.txt.

 Tip

Change the default password for the keystore to safeguard your certificates.

2. Configure the Data Provisioning Agent for SSL.


a. Navigate to the <DPAgent_root>/configTool directory.
b. Start the configuration tool.
○ On Windows, run dpagentconfigtool.exe.
○ On Linux, run ./dpagentconfigtool.
c. Click Configure SSL.
d. Enter the relative path (ssl/cacerts) and password for the keystore that contains the SAP HANA
server certificate.

For the password, if you explicitly changed the keystore password, specify the new password here.
Otherwise, leave the default password as it is.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 89
e. Select Use SSL to communicate with HANA on Cloud and click Save.

Related Information

Download the SAP HANA Server Certificate [page 41]

2.5.3.2 Manage the Agent Service

Use the configuration tool to stop or start the agent service.

Procedure

1. Start the agent configuration tool.


2. Click Start Agent or Stop Agent.

Results

The configuration tool indicates whether the agent service is running and the listening port in use by the agent.

Next Steps

On Windows, you can also manage the agent service from the standard Windows Services tool. The name of
the service is SAP_HANA_SDI_Agent_Service_Daemon_<instance_name>.

On Linux, you can also manage the agent with a shell script. The shell script is located at
<DPAgent_root>/bin/dpagent_servicedaemon.sh and supports the following commands:

● ./dpagent_servicedaemon.sh start
● ./dpagent_servicedaemon.sh stop

Related Information

Start and Connect the Configuration Tool [page 84]

Installation and Configuration Guide


90 PUBLIC Configure Smart Data Integration
2.5.3.3 Register the Agent with SAP HANA

Before you can use adapters deployed on the Data Provisioning Agent, you must register the agent with SAP
HANA.

Prerequisites

● The Agent Admin HANA User must have the following roles or privileges.

Table 24: Roles and Privileges


Action Role or Privilege

Register adapter System privilege: AGENT ADMIN

● For SAP HANA on Cloud, the Agent XS HANA User must have the following roles or privileges.

Table 25: Roles and Privileges


Action Role or Privilege

Register adapter System privilege: AGENT ADMIN

Messaging between the agent and SAP Application privilege:


HANA on Cloud sap.hana.im.dp.proxy::AgentMessaging

Procedure

1. Start the agent configuration tool and connect to the SAP HANA server.
2. Click Register Agent.
3. Specify the agent connection information.

○ If SAP HANA is not in the cloud, specify the agent name and hostname.
Ensure that the SAP HANA server can communicate with the agent host. Depending on the network
configuration, you may need to qualify the agent hostname fully.
Ensure that your firewall settings allow the connection from the SAP HANA server to the agent host on
the listener port. By default, port 5050.
○ If SAP HANA is in the cloud, specify the agent name.
When SAP HANA is in the cloud, the agent service is restarted to complete the registration process.
4. Click Register.

Results

The agent is registered with SAP HANA. If SAP HANA is in the cloud, the agent service is automatically
restarted.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 91
Next Steps

To unregister the agent, click Unregister Agent.

 Caution

Unregistering the agent from the SAP HANA server performs a cascade drop of the agent. As a result, any
remote subscriptions that use the agent are also deleted, even if they are active.

Related Information

Start and Connect the Configuration Tool [page 84]

2.5.3.4 Reconfigure the Java Runtime Environment

The SAP JVM is bundled with the Data Provisioning Agent and used as the default Java Runtime Environment.
You can choose to update the version of the SAP JVM used by an installed agent or replace it with a custom
Java Runtime Environment.

Prerequisites

If you want to update your version of the SAP JVM, download the version of the SAP JVM that matches the
operating system and processor architecture used by the Data Provisioning Agent host.

Procedure

● Update the SAP JVM with a newer version.


a. Extract the downloaded .SAR file containing the latest SAP JVM to a temporary location.
b. Stop the Data Provisioning Agent service.
c. Delete or back up the entire contents of the <DPAgent_root>/sapjvm directory.
d. Copy the extracted .SAR contents from <temp_location>/sapjvm_<version>/jre into
<DPAgent_root>/sapjvm.
e. Restart the Data Provisioning Agent service.
● Replace the SAP JVM with a custom JRE. That is, any Java runtime other than the SAP JVM.
a. Stop the Data Provisioning Agent service.
b. In a text editor, open dpagent.ini and replace the value of the -vm setting with the path to the
custom JRE.

Installation and Configuration Guide


92 PUBLIC Configure Smart Data Integration
 Note

The -vm setting must be specified before the -vmargs setting in the dpagent.ini file, and -vm
and its setting must be entered on different lines. Additionally, do not use quotes around the path
even if the path contains spaces.

Table 26: Example Replacement


Platform Original Value New Value

Windows -vm -vm


C:\usr\sap\dataprovagent\sapjvm C:\Program Files\Java\jre7\bin
\bin

Linux -vm -vm


/usr/sap/dataprovagent/ /usr/java/jdk1.7.0_71/jre/lib/
sapjvm/lib/amd64/server amd64/server

c. Restart the Data Provisioning Agent service.

Related Information

Manage the Agent Service [page 90]


Software Download [page 39]

2.5.3.5 Store Source Database Credentials in Data


Provisioning Agent [Graphical Mode]

Store source database access credentials in the Data Provisioning Agent secure storage using the DP Agent
Configuration Tool.

Context

If you don't want to store credentials in SAP HANA, you can store them in the Data Provisioning Agent secure
storage.

Entering credentials in the Data Provisioning Agent requires three components: remote source name, user
name, and password. This method of storing credentials also gives you more management flexibility by
allowing you to edit and delete whenever you want.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 93
Procedure

1. Open the Data Provisioning Agent Configuration Tool.

2. Choose Configure Remote Source Credentials .


3. Click Add Credentials
4. In the Add Credentials window, add the remote source name, user name, and password, and then click OK.

Results

You can now access these credentials to connect to a remote source through the Use Agent Stored Credential
remote source configuration parameter for your adapter. You can also use this editor to view, delete, and edit
credentials.

Related Information

SAP HANA Remote Source Configuration [page 444]


IBM DB2 Mainframe Remote Source Configuration [page 286]
DB2 Log Reader Remote Source Configuration [page 270]
Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

2.5.4 Managing Agent Groups

Agent grouping provides failover and load-balancing capabilities by combining individual Data Provisioning
Agents installed on separate host systems.

 Restriction

Failover is not supported for initial and batch load requests. Restart the initial load following a failure due to
agent unavailability.

 Restriction

Load balancing is supported only for initial loads. It is not supported for changed-data capture (CDC)
operations.

Planning considerations

Before configuring agents in a group, review the following considerations and limitations:

Installation and Configuration Guide


94 PUBLIC Configure Smart Data Integration
● For real-time replication failover, each agent in a group must be installed on a different host system.
● All agents in a group must have identical adapter configurations.
● All agents in a group must use the same communication protocol. You cannot mix on-premise agents
(TCP) and cloud-based agents (HTTP) in a single group.

Failover Behavior in an Agent Group [page 95]


When an agent node in an agent group is inaccessible for longer than the configured heartbeat interval,
the Data Provisioning Server chooses a new active agent within the group. It then resumes replication
for any remote subscriptions active on the original agent.

Load Balancing in an Agent Group [page 96]


With multiple agents in an agent group, you can choose to have the agent for the initial loads selected
randomly, selected from the list of agents in a round-robin fashion, or not load balanced.

Create or Remove an Agent Group [page 97]


You can create an agent group or remove an existing group in the Data Provisioning Agent Monitor.

Manage Agent Nodes in an Agent Group [page 98]


You can manage the agent nodes that belong to an agent group in the Data Provisioning Agent Monitor.

Add Adapters to an Agent Group [page 99]


Before you can create remote sources in an agent group, you must add adapters to the group in the
SAP HANA Web-based Development Workbench.

Configure Remote Sources in an Agent Group [page 100]


To receive the benefits of failover from an agent group, you must configure your remote sources in the
agent group.

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Command Line Batch Mode [page 69]
Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]

2.5.4.1 Failover Behavior in an Agent Group

When an agent node in an agent group is inaccessible for longer than the configured heartbeat interval, the
Data Provisioning Server chooses a new active agent within the group. It then resumes replication for any
remote subscriptions active on the original agent.

Initial and batch load requests to a remote source configured on the agent group are routed to the first
available agent in the group.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 95
 Restriction

Failover is not supported for initial and batch load requests. Restart the initial load following a failure due to
agent unavailability.

Although no user action is required for automatic failover within an agent group, you may choose to monitor
the current agent node information.

● To query the current master agent node name for a remote source:

SELECT AGENT_NAME FROM "SYS"."M_REMOTE_SOURCES_" WHERE "REMOTE_SOURCE_OID" =


(SELECT REMOTE_SOURCE_OID FROM "SYS"."REMOTE_SOURCES_" WHERE
REMOTE_SOURCE_NAME = '<remote_source_name>');

● To query a list of all agent and agent group names:

SELECT AGENT_NAME,AGENT_GROUP_NAME FROM SYS."AGENTS";

 Caution

If all nodes in an agent group are down, replication cannot continue and must be recovered after one or
more agent nodes are available.

Restarting Agent Nodes in an Agent Group

Restarting nodes in an agent group does not impact active replication tasks.

For the master agent node, stopping or restarting the agent triggers the agent group failover behavior and a
new active master node is selected.

2.5.4.2 Load Balancing in an Agent Group

With multiple agents in an agent group, you can choose to have the agent for the initial loads selected
randomly, selected from the list of agents in a round-robin fashion, or not load balanced.

 Note

Agent grouping provides load balancing for initial loads only. Load balancing is not supported for changed-
data capture (CDC) operations.

Load balancing is governed by the 'agent_group'.'load_balance_mode' index server parameter and


supports the following modes:

● none: No load balancing is performed.


● random: The agent is chosen randomly.
● round_robin: The chosen agent is the next in the list of available agents after the previously chosen agent.

Installation and Configuration Guide


96 PUBLIC Configure Smart Data Integration
For example, to select the agent for initial loads randomly:

ALTER SYSTEM ALTER CONFIGURATION ('indexserver.ini','SYSTEM') SET


('agent_group', 'load_balance_mode') = 'random' WITH RECONFIGURE;

2.5.4.3 Create or Remove an Agent Group

You can create an agent group or remove an existing group in the Data Provisioning Agent Monitor.

Prerequisites

The user who creates or removes the agent group must have the following roles or privileges:

Table 27: Roles and Privileges


Action Role or Privilege

Create agent group ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::CreateAgentGroup
● System privilege: AGENT ADMIN

Remove agent group ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::DropAgentGroup
● System privilege: AGENT ADMIN

Context

Use the buttons in the Agent Group table to create or remove an agent group.

Procedure

● Click Create to create an agent group.


Specify the name for the new agent group, and click Create Agent Group.
The new agent group appears in the Agent Group table.
● Select the agent group and click Drop to remove an existing agent group.

 Note

When you remove an agent group, any agent nodes for the group are removed from the group first.
Agents cannot be removed from the group if there are active remote subscriptions.

Any agent nodes are removed from the group, and the group is removed from the Agent Group table.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 97
Related Information

CREATE AGENT GROUP Statement [Smart Data Integration] [page 539]


DROP AGENT GROUP Statement [Smart Data Integration] [page 552]

2.5.4.4 Manage Agent Nodes in an Agent Group

You can manage the agent nodes that belong to an agent group in the Data Provisioning Agent Monitor.

Prerequisites

The user must have the following roles or privileges to manage agent nodes:

Table 28: Roles and Privileges


Action Role or Privilege

Create agent ● Role: sap.hana.im.dp.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::CreateAgent
● System privilege: AGENT ADMIN

Add agent to agent group ● Role: sap.hana.im.dp.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::AlterAgent
● System privilege: AGENT ADMIN

Remove agent from agent group ● Role: sap.hana.im.dp.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::AlterAgent
● System privilege: AGENT ADMIN

Context

Use the buttons in the Agent Monitor and Agent Group tables to perform the action.

 Tip

Select an agent group in the Agent Group table to display its nodes in the Agent Monitor table.

Procedure

● To register a new agent with the SAP HANA system and add it to an existing agent group, click Create
Agent.

Installation and Configuration Guide


98 PUBLIC Configure Smart Data Integration
When specifying the parameters for the agent, select the agent group from the Agent Group list.

The new agent appears in the Agent Monitor table.


● To modify the group assignment for an existing agent, click Alter Agent.

○ Select the new agent group from the Agent Group list.
If you are assigning the agent to a different group, select the empty entry for Enable SSL to avoid
connection issues when the group is changed.
○ To remove the agent from an agent group, select the empty entry from the Agent Group list.

The group for the agent is displayed in the Agent Monitor table.
● To add multiple existing agents to an agent group, select the group in the Agent Group table and click Add
Agents.
a. Select the agents that you want to add to the group.
b. Click Add Agents.
The selected agents are assigned to the agent group and all associated entries in the Agent Monitor and
Agent Group tables are updated.

Related Information

Manage Agents from the Data Provisioning Agent Monitor [page 103]
CREATE AGENT Statement [Smart Data Integration] [page 537]
ALTER AGENT Statement [Smart Data Integration] [page 527]

2.5.4.5 Add Adapters to an Agent Group

Before you can create remote sources in an agent group, you must add adapters to the group in the SAP HANA
Web-based Development Workbench.

Prerequisites

The user who adds an adapter must have the following roles or privileges:

Table 29: Roles and Privileges


Action Role or Privilege

Add adapter to agent group System privilege: ADAPTER ADMIN

Procedure

1. Open the SQL console in the SAP HANA Web-based Development Workbench.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 99
2. If you do not know the agent names, query the system for a list of agents and agent groups.

SELECT AGENT_NAME,AGENT_GROUP_NAME FROM SYS."AGENTS";

3. Create the adapter on the first agent node.

CREATE ADAPTER "<adapter_name>" AT location agent "<agent1_name>";

4. Add the agent to each additional agent node in the agent group.

ALTER ADAPTER "<adapter_name>" ADD location agent "<agent#_name>";

2.5.4.6 Configure Remote Sources in an Agent Group

To receive the benefits of failover from an agent group, you must configure your remote sources in the agent
group.

Configure Remote Sources in the Web-based Development


Workbench

Procedure

● To create a new remote source in an agent group:

a. In the Catalog editor, right-click the Provisioning Remote Sources folder, and choose New
Remote Source.
b. Enter the required configuration information for the remote source, including the adapter name.
c. In the Location dropdown, choose agent group, and select the agent group name.
d. Click Save.
● To add an existing remote source to an agent group:

a. In the Catalog editor, select the remote source in the Provisioning Remote Sources folder.
b. In the Location dropdown, choose agent group, and select the agent group name.
c. Click Save.

Related Information

Create a Remote Source in the Web-Based Development Workbench

Installation and Configuration Guide


100 PUBLIC Configure Smart Data Integration
Configure Remote Sources in the SQL Console

Procedure

1. Open the SQL console in the SAP HANA studio or Web-based Development Workbench.
2. Execute the CREATE or ALTER REMOTE SOURCE statement in the SQL console.

○ To create a new remote source in the group:

CREATE REMOTE SOURCE <source_name> ADAPTER <adapter_name> AT LOCATION


AGENT GROUP <group_name> <configuration_clause> <credential_clause>

○ To add an existing remote source to the group:

ALTER REMOTE SOURCE <source_name> ADAPTER <adapter_name> AT LOCATION AGENT


GROUP <group_name> <configuration_clause> <credential_clause>

 Note

If you are changing only the location for the remote source, you can omit the ADAPTER and
CONFIGURATION clauses:

ALTER REMOTE SOURCE <source_name> AT LOCATION AGENT GROUP <group_name>


<credential_clause>

Related Information

CREATE REMOTE SOURCE Statement [Smart Data Integration] [page 542]


ALTER REMOTE SOURCE Statement [Smart Data Integration] [page 528]

Alter Remote Source Clauses

When you use ALTER REMOTE SOURCE to modify a remote source, you must specify the configuration and
credential details as XML strings.

Example Credential Clause

WITH CREDENTIAL TYPE 'PASSWORD' USING '<CredentialEntry name="credential">


<user><username></user>
<password><password></password>
</CredentialEntry>'

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 101
Example Configuration Clause

CONFIGURATION '<?xml version="1.0" encoding="UTF-8"?>


<ConnectionProperties name="configurations">
<PropertyGroup name="generic">
<PropertyEntry name="map_char_types_to_unicode">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database">
<PropertyEntry name="cdb_enabled">false</PropertyEntry>
<PropertyEntry name="pds_use_tnsnames">false</PropertyEntry>
<PropertyEntry name="pds_host_name"><db_hostname></PropertyEntry>
<PropertyEntry name="pds_port_number">1521</PropertyEntry>
<PropertyEntry name="pds_database_name">ORCL</PropertyEntry>
<PropertyEntry name="cdb_service_name"></PropertyEntry>
<PropertyEntry name="pds_service_name"></PropertyEntry>
<PropertyEntry name="pds_tns_filename"></PropertyEntry>
<PropertyEntry name="pds_tns_connection"></PropertyEntry>
<PropertyEntry name="cdb_tns_connection"></PropertyEntry>
<PropertyEntry name="_pds_tns_connection_with_cdb_enabled"></
PropertyEntry>
<PropertyEntry name="pds_byte_order"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="schema_alias_replacements">
<PropertyEntry name="schema_alias"></PropertyEntry>
<PropertyEntry name="schema_alias_replacement"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security">
<PropertyEntry name="pds_use_ssl">false</PropertyEntry>
<PropertyEntry name="pds_ssl_sc_dn"></PropertyEntry>
<PropertyEntry name="_enable_ssl_client_auth">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="jdbc_flags">
<PropertyEntry name="remarksReporting">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc">
<PropertyGroup name="databaseconf">
<PropertyEntry name="pdb_archive_path"></PropertyEntry>
<PropertyEntry name="pdb_supplemental_logging_level">table</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="parallelscan">
<PropertyEntry name="lr_parallel_scan">false</PropertyEntry>
<PropertyEntry name="lr_parallel_scanner_count"></PropertyEntry>
<PropertyEntry name="lr_parallel_scan_queue_size"></
PropertyEntry>
<PropertyEntry name="lr_parallel_scan_range"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader">
<PropertyEntry name="skip_lr_errors">false</PropertyEntry>
<PropertyEntry name="lr_max_op_queue_size">1000</PropertyEntry>
<PropertyEntry name="lr_max_scan_queue_size">1000</PropertyEntry>
<PropertyEntry name="lr_max_session_cache_size">1000</
PropertyEntry>
<PropertyEntry name="scan_fetch_size">10</PropertyEntry>
<PropertyEntry name="pdb_dflt_column_repl">true</PropertyEntry>
<PropertyEntry name="pdb_ignore_unsupported_anydata">false</
PropertyEntry>
<PropertyEntry name="pds_sql_connection_pool_size">15</
PropertyEntry>
<PropertyEntry name="pds_retry_count">5</PropertyEntry>
<PropertyEntry name="pds_retry_timeout">10</PropertyEntry>
</PropertyGroup>
</PropertyGroup>
</ConnectionProperties>'

Installation and Configuration Guide


102 PUBLIC Configure Smart Data Integration
 Note

You cannot change user names while the remote source is suspended.

2.5.5 Manage Agents from the Data Provisioning Agent


Monitor

Use the Data Provisioning Agent Monitor to perform basic administration tasks such as registering, altering, or
dropping Data Provisioning Agents.

Prerequisites

The user must have the following roles or privileges to manage agents:

Table 30: Roles and Privileges

Action Role or Privilege

Add Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::CreateAgent
● System privilege: AGENT ADMIN

Alter Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::AlterAgent
● System privilege: AGENT ADMIN

Remove Data Provisioning Agent ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::DropAgent
● System privilege: AGENT ADMIN

Context

Use the following controls in the Agent Monitor table to perform an action.

Procedure

● Select Create Agent to register a new agent with the SAP HANA system.
a. Specify the name of the agent and relevant connection information.
b. If the agent uses a secure SSL connection, select Enable SSL.
c. If you want to assign the agent to an existing agent group, select the group under Agent Group.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 103
d. Click Create Agent.

The new agent appears in the Agent Monitor table.


● Select Alter Agent to make connection configuration changes on an agent already registered in the SAP
HANA system.
a. Specify the new connection information for the agent. You can’t change the name or connection
protocol for an existing agent.
b. If the agent uses a secure SSL connection, check Enable SSL.
c. If you want to assign the agent to an existing agent group, select the group under Agent Group.
d. Click Alter Agent.

The updated agent information appears in the Agent Monitor table.


● Select Drop Agent to remove an agent from the SAP HANA system.
a. To drop any dependent objects automatically, such as registered adapters, choose CASCADE option.
You can’t remove an agent while it has dependent objects such as registered adapters. Remove the
adapters from the agent manually, or check CASCADE option.
b. Click Drop Agent.

The agent is removed from the Agent Monitor table. If the agent was assigned to an agent group, it’s also
removed from the agent group.

Task overview: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Command Line Batch Mode [page 69]
Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]
Assign Roles and Privileges [page 25]

2.5.6 Agent Adapter Framework Preferences

The agent preferences provide advanced configuration options for the Data Provisioning Agent.The method for
accessing and modifying agent preferences depends on the configuration mode that you use.

Installation and Configuration Guide


104 PUBLIC Configure Smart Data Integration
Graphical Mode

Choose Config Preferences in the Data Provisioning Agent Configuration tool, and then select Adapter
Framework.

Command-Line Interactive Mode

Use the Set Agent Preferences action in the Agent Preferences menu in interactive mode.

For example, to set the agent logging level to ALL:

1. Select 3 to enter the Agent Preferences menu.


2. Select 2 to set the value of a preference.
3. Select the menu index for logging level, and enter ALL when prompted for the new value.

Command-Line Batch Mode

Use the agentPreferences function of the command-line configuration tool.

For example, to set the agent logging level to ALL:

--function agentPreferences -Dframework.log.level=ALL

Available Agent Preferences

By default, the agent is configured to start in TCP mode and monitor port 5050 for requests from SAP HANA.

Table 31: Agent Preferences


Key Description Default Value

Framework listener port Port the agent monitors for requests from the SAP 5050
HANA server
framework.listenerPort
The Framework listener port should be SSL-ena­
bled for security.

Admin port Local port used for internal communication be­ 5051
tween the agent and the agent configuration tool
framework.adminport
Do not enable the admin port within a firewall; the
port should be blocked from outside access to pre­
vent unauthorized changes on the agent.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 105
Key Description Default Value

Worker thread pool Number of worker threads 10

framework.threadPoolSize

Polling timeout Length of time to perform a blocking wait on queue 10

framework.pollingTimeout

Polling timeout unit Unit used by the polling timeout SECONDS

framework.timeUnit

Max data size in bytes Maximum amount of data to fetch 100000000

framework.maxDataSize

Row fetch size (max) Maximum number of browse nodes or rows to fetch 1000
from an adapter
framework.fetchSize

Row fetch size (min) Minimum number of rows to fetch from an adapter 10

framework.min.fetchSize

Max number of retries Maximum number of times the agent tries to con­ 10
nect after a registration or ping failure
framework.retry.maxTries

Time to wait before retry The amount of time to wait before retrying 30

framework.retry.waitTime

Shared Directory for Agent Group Shared directory for the agent group to which this None
agent instance belongs, if any
framework.clusterSharedDir

Logging level Type of logging to perform for the agent: TRACE

framework.log.level ● TRACE
● DEBUG
● ERROR
● ALL

Log max backup Number of log files to keep 10

framework.log.maxBackupIndex

Log file max file size Maximum file size in MB or KB that the log file 10 MB
should use
framework.log.maxFileSize

Trace message max size When tracing is enabled, the specific number of 1024
characters in a trace message after which the mes­
framework.trace.length sage is truncated

Trace ping message When tracing is enabled, specifies printing of the false
ping message
framework.trace.pingMessage

Trace all data Enables printing the content of the data rows sent false
to server
framework.trace.data

Installation and Configuration Guide


106 PUBLIC Configure Smart Data Integration
Key Description Default Value

Max HTTP Connection per route Maximum number of connections the internal 20
HTTP client can create
cloud.defaultMaxPerRoute

Max available HTTP connection Maximum number of connections 20

cloud.maxTotal

Proxy type Type of proxy being used http

proxyType

Proxy Host Hostname of the proxy being used

proxyHost

Proxy Port Port used by the proxy

proxyPort

Non-Proxy Hosts

nonProxyHosts

Read-only Adapters List of adapters to operate in read-only mode.

framework.readOnlyAdapters

Maximum open socket connections

framework.so.maxOpenConnection

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Command Line Batch Mode [page 69]
Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Runtime Options [page 108]
Replicating an Agent Configuration to Another Host [page 110]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 107
2.5.7 Agent Runtime Options

Use the command-line configuration tool to manage advanced runtime options stored in the dpagent.ini
configuration file safely.
Agent runtime options are typically used when troubleshooting an agent issue or optimizing agent
performance.

The method for accessing and modifying the agent runtime options depends on the configuration mode that
you use.

Command-Line Interactive Mode

Start the configuration tool with the --configAgentIniFile parameter and select the option that you want
to modify.

The configuration tool prompts you for any information required for the runtime option that you are modifying.

Command-Line Batch Mode

Use the --configAgentIniFile parameter and specify the function for the agent runtime option that you
want to modify, as well as any additional parameters required by the function.

For example, to change the maximum amount of memory available to the agent to 16 GB on Windows:

agentcli.bat –-configAgentIniFile --function setDPAgentMemory -


Ddpagent.vm.xmx=16g

Supported Runtime Options

Table 32: Agent Runtime Options


Option and Function Description and Parameters

Clear DPAgent Cache on Next Start When enabled, the next time the agent is restarted, any cached
agent, OSGi, and Eclipse runtime data is removed and the caches are
reinitialized.

 Caution
Do not enable this option unless instructed to do so by SAP Sup­
port.

Installation and Configuration Guide


108 PUBLIC Configure Smart Data Integration
Option and Function Description and Parameters

Switch Java Virtual Machine Updates the version of the SAP JVM used by an installed agent, or re­
places the SAP JVM with a custom Java Runtime Environment
changeDefaultJVM
The SAP JVM is bundled with the Data Provisioning Agent and used
as the default Java Runtime Environment

-Ddpagent.vm.directory=<jvm_path>

Switch DPAgent Log Directory Modifies the location of the root directory where all agent-related log
files are generated
changeLogDirectory
The default root log path is <DPAgent_root>/log.

-Ddpagent.log.directory=<log_root_path>

Change DPAgent Max Available Memory Modify the maximum amount of memory that the agent can use

setDPAgentMemory -Ddpagent.vm.vmx=<amount>

For example, for 16 GB, specify 16g.

Enable Remote Debugging Assists SAP Support in troubleshooting agent-related issues

enableRemoteDebugging -Ddpagent.remoteDebugging.port=<port_number>

-Ddpagent.remoteDebugging.suspend=<value>

Available values: true or false

 Caution
Do not enable this option unless instructed to do so by SAP Sup­
port.

Inject System Property Enables runtime JVM system properties

injectSystemProperty -Ddpagent.system.key=<value>

-Ddpagent.system.value=<value>

 Caution
Do not enable this option unless instructed to do so by SAP Sup­
port.

Revert dpagent.ini to original state Removes any changes to the agent runtime options and reverts the
dpagent.ini to its original state.
setCleanParameter

Parent topic: Configure the Data Provisioning Agent [page 49]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 109
Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]


Configuring the Agent in Command Line Batch Mode [page 69]
Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Replicating an Agent Configuration to Another Host [page 110]

2.5.8 Replicating an Agent Configuration to Another Host

There are items that you need to consider when moving to a different host from one where your agent is
configured.

If you are migrating to a different host, keep the following rules in mind:

● The agent install path must be the same. You cannot migrate to a different path because the path is
hardcoded in many places.
● The host operating system should be the same. For example, you cannot migrate a configuration from
Linux to Windows.
● If you are migrating an agent that was configured to talk to SAP HANA on cloud, you cannot have both
agents running afterwards. SAP HANA does not support communication with two agents using the same
configuration.

If the agent is the same version as the one on the old machine, then you can migrate the following objects:

● Folders: Camel, configuration/com.sap.hana.dp.adapterframework, LogReader, sec,


secure_storage, ssl, lib
● Files: dpagentconfig.ini, dpagent.ini

If the agents are different versions, then you can migrate the following objects:

● Folders: sec, secure_storage, ssl, lib


● Files: dpagentconfig.ini

 Note

After the migration, be sure to update the dpagentconfig.ini file by editing the agent.hostname
parameter to match the host the agent is now on.

Parent topic: Configure the Data Provisioning Agent [page 49]

Related Information

Configuring the Agent in Command-Line Interactive Mode [page 50]

Installation and Configuration Guide


110 PUBLIC Configure Smart Data Integration
Configuring the Agent in Command Line Batch Mode [page 69]
Configuring the Agent in Graphical Mode [Deprecated] [page 83]
Managing Agent Groups [page 94]
Manage Agents from the Data Provisioning Agent Monitor [page 103]
Agent Adapter Framework Preferences [page 104]
Agent Runtime Options [page 108]

2.6 Register Data Provisioning Adapters

After configuring the Data Provisioning Agent, register adapters.

Prerequisites

● Install and configure the data provisioning agent.


● If necessary, download and install any necessary JDBC libraries. For information about the proper JDBC
library for your source, see the SAP HANA smart data integration Product Availability Matrix (PAM).

Procedure

1. Register the adapter.


2. Configure the source system to which the adapter connects.
For information about the remote source configuration steps necessary for each adapter, see “Configure
Data Provisioning Adapters”.

Next Steps

Create a remote source in SAP HANA.

 Caution

The OData adapter isn’t part of the Data Provisioning Agent installation. The OData adapter is installed with
the SAP HANA server and requires configuration that can’t be done using the Data Provisioning Agent
Configuration tool.

 Restriction

When the target table is made with a column store and the option CS_DATA_TYPENAME is set to
ST_MEMORY_LOB, then the in-memory size is limited to less than 1 GB. To prevent this limitation, set the
option to LOB. This solution applies to all adapters.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 111
Task overview: Configure Smart Data Integration [page 24]

Previous: Configure the Data Provisioning Agent [page 49]

Next task: Create a Remote Source [page 117]

Related Information

Register Adapters with SAP HANA [page 112]


Register Adapters with SAP HANA [Command Line] [page 114]
Manage Adapters from the Data Provisioning Agent Monitor [page 115]
Configure Data Provisioning Adapters [page 153]
OData [page 344]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

2.6.1 Register Adapters with SAP HANA

Before you can connect to remote sources using an adapter, you must register the adapter with SAP HANA.

Prerequisites

The HANA administrator user must have the following roles or privileges:

Table 33: Roles and Privileges


Action Role or Privilege

Register an adapter System privilege: ADAPTER ADMIN

Application privilege: sap.hana.im.dp.admin::Administrator

 Note
This application privilege is required only for SAP HANA in the cloud.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

Installation and Configuration Guide


112 PUBLIC Configure Smart Data Integration
Procedure

1. Start the Data Provisioning Agent Configuration tool and connect to SAP HANA.
2. For custom adapters, click Deploy Adapter and point to the adapter JAR files.

 Note

Data provisioning adapters delivered by SAP are automatically deployed on the agent during agent
installation.

3. Select the adapter to register and click Register Adapter.


4. Configure the source system to which the adapter connects, if necessary.

For example, log reader adapters require source configuration to enable real-time replication.

For complete information about source system configuration, see the relevant section for each adapter in
“Configure Data Provisioning Adapters”.

Results

The selected adapter is registered with SAP HANA and can be selected when creating a remote source.

Next Steps

 Note

For SAP HANA in the cloud, you must restart the agent service to complete the registration of adapters. If
the registration succeeds and the restart of the service fails, or the registration of all adapters fails, then the
registration is rolled back.

Related Information

Configure Data Provisioning Adapters [page 153]


Start and Connect the Configuration Tool [page 84]
SAP ECC Adapter Preferences [page 427]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 113
2.6.2 Register Adapters with SAP HANA [Command Line]

Before you can connect to remote sources using an adapter, you must register the adapter with SAP HANA.

Prerequisites

The HANA administrator user must have the following roles or privileges:

Table 34: Roles and Privileges


Action Role or Privilege

Register an adapter System privilege: ADAPTER ADMIN

Application privilege: sap.hana.im.dp.admin::Administrator

 Note
This application privilege is required only for SAP HANA in the cloud.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

Procedure

1. Start the command-line agent configuration tool and connect to SAP HANA.
2. Select 8 to enter the Custom Adapters menu.

 Note

Data provisioning adapters delivered by SAP are automatically deployed on the agent during agent
installation.

a. Select 1 to deploy a custom adapter.


b. Specify the location of the adapter's JAR files.
c. Select b to return to the main menu.
3. To enter the Adapter Registration menu, select 7.
4. To register an adapter, select 2.
5. Specify the name of the adapter to register with SAP HANA.

 Note

The adapter name must match the name displayed by the Display Adapters option.

Installation and Configuration Guide


114 PUBLIC Configure Smart Data Integration
6. Configure the source system to which the adapter connects, if necessary.

For example, log reader adapters require source configuration to enable real-time replication.

For complete information about source system configuration, see the relevant section for each adapter in
“Configure Data Provisioning Adapters”.

Results

The selected adapter is registered with SAP HANA and can be selected when creating a remote source.

Next Steps

 Note

For SAP HANA in the cloud, you must restart the agent service to complete the registration of adapters. If
the registration succeeds and the restart of the service fails, or the registration of all adapters fails, then the
registration is rolled back.

Related Information

Configure Data Provisioning Adapters [page 153]


Start the Configuration Tool [Command Line] [page 51]
SAP ECC Adapter Preferences [page 427]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

2.6.3 Manage Adapters from the Data Provisioning Agent


Monitor

Use the Data Provisioning Agent Monitor to perform basic administration tasks, such as adding adapters to or
removing adapters from a Data Provisioning Agent instance.

Prerequisites

The user must have the following roles or privileges to manage adapters:

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 115
Table 35: Roles and Privileges

Action Role or Privilege

Add adapter ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::AddLocationToAdapter
● System privilege: ADAPTER ADMIN

Remove adapter ● Role: sap.hana.im.dp.monitor.roles::Operations


● Application privilege: sap.hana.im.dp.monitor::RemoveLocationFromAdapter
● System privilege: ADAPTER ADMIN

Update adapters ● Role: sap.hana.im.dp.monitor.roles::Operations


● System privilege: ADAPTER ADMIN

Context

Use the buttons in the Agent Monitor and Agent Adapter Mapping tables to perform an action.

Procedure

● To add adapters to an agent instance, select the agent and click Add Adapters in the Agent Monitor table.
a. Select the desired adapters from the list of adapters deployed on the agent instance.
b. Click Add Adapters.

The selected adapters appear in the Adapter Agent Mapping table.


● To remove an adapter from an agent instance, select the adapter and click Remove Location in the Adapter
Agent Mapping table.
a. If the adapter is registered on only one agent instance, you can remove it with CASCADE option.
b. Click Remove Location.

The adapter is removed from the Adapter Agent Mapping table.


● To update all adapters for an agent, select the agent and click Update Adapters in the Agent Monitor.
All adapters registered for the selected agent are refreshed, and any new capabilities can be used by SAP
HANA.
● To update a single adapter, select the adapter and click Update in the Adapter Agent Mapping table.
The selected adapter is refreshed, and any new capabilities can be used by SAP HANA.

Related Information

Assign Roles and Privileges [page 25]

Installation and Configuration Guide


116 PUBLIC Configure Smart Data Integration
2.7 Create a Remote Source

Using SAP HANA smart data integration, you set up an adapter that can connect to your source database, then
create a remote source to establish the connection.

Prerequisites

● The user who creates the remote source must have the following roles or privileges:

Table 36: Roles and Privileges


Action Role or Privilege

Create a remote source System privilege: CREATE REMOTE SOURCE

● The Data Provisioning Server must be enabled.


● The Data Provisioning Agent must be installed and configured.
● The adapter must be configured and registered with SAP HANA.

Context

You can create a remote source in more than one way.

Create a Remote Source in the Web-Based Development Workbench [page 118]


In SAP HANA smart data integration, you can create a remote source with the Web-based Development
Workbench user interface.

Create a Remote Source in the SQL Console [page 119]


In SAP HANA smart data integration, you can create a remote source using the SQL console.

Create Credentials for a Secondary User [page 120]


The syntax for creating secondary user credentials for SAP HANA smart data integration adapters is
different from the syntax for SAP HANA system adapters.

Configure a Grantor for the HDI Container [page 121]


To build and execute flowgraphs and replication tasks in SAP Web IDE, first configure the grantor
privilege.

Task overview: Configure Smart Data Integration [page 24]

Previous task: Register Data Provisioning Adapters [page 111]

Next: Set Up Data Provisioning Monitoring [page 124]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 117
Related Information

2.7.1 Create a Remote Source in the Web-Based Development


Workbench

In SAP HANA smart data integration, you can create a remote source with the Web-based Development
Workbench user interface.

Prerequisites

The user who creates the remote source must have the following roles or privileges:

Table 37: Roles and Privileges


Action Role or Privilege

Create a remote source ● System privilege: CREATE REMOTE SOURCE

Procedure

1. In the Web-based Development Workbench Catalog editor, expand the Provisioning node.
2. Right-click the Remote Sources folder and choose New Remote Source.
3. Enter the required information including the adapter and Data Provisioning Agent names.
Regarding user credentials, observe the following requirements:
○ A remote source created with a secondary user can be used only for querying virtual tables.
○ If the remote source is used for designing a .hdbreptask or .hdbflowgraph enabled for real time,
use technical user.
○ If you create a remote subscription using the CREATE REMOTE SUBSCRIPTION SQL statement, use
technical user.
4. Select Save.

Related Information

Configure Data Provisioning Adapters [page 153]


CREATE REMOTE SOURCE Statement [Smart Data Integration] (SAP HANA SQL and System Views
Reference) [page 542]

Installation and Configuration Guide


118 PUBLIC Configure Smart Data Integration
2.7.2 Create a Remote Source in the SQL Console

In SAP HANA smart data integration, you can create a remote source using the SQL console.

Prerequisites

The user who creates the remote source must have the following roles or privileges:

Table 38: Roles and Privileges


Action Role or Privilege

Create a remote source ● System privilege: CREATE REMOTE SOURCE

Context

To create a remote source using the SQL console, you must know the connection information for your source.
For an existing remote source, the connection information is in an XML string in the CONFIGURATION
statement.

For your adapter, refer to the remote source configuration topic for that adapter in this guide to see its sample
SQL code. Change the variables to the correct values for your remote source.

The example at the end of this topic illustrates the basic CONFIGURATION connection information XML string
for a Microsoft SQL Server adapter.

After you create the remote source:

● If you’ve recently updated the Data Provisioning Agent, the connection information XML string could also
have been updated for your adapter. Therefore, refresh the adapter to get up-to-date connection
information.
● To view the connection information for an existing remote source, execute SELECT * FROM
"PUBLIC"."REMOTE_SOURCES". In the resulting view, look in the CONNECTION_INFO column.

 Tip

To ensure you can view the entire XML string in the CONNECTION_INFO column, in your SAP HANA
preferences enable the setting Enable zoom of LOB columns.

● To view all of the configuration parameters for a given adapter type, execute SELECT * FROM
"PUBLIC"."ADAPTERS". In the resulting view, look in the CONFIGURATION column. This information can
be useful if you want to, for example, determine the PropertyEntry name for a given parameter in the user
interface, shown as displayName. For example:

<PropertyEntry name="pds_database_name" displayName="Database


Name"><database_name></PropertyEntry>
<PropertyEntry name="pdb_dcmode" displayName="Database Data Capture
Mode">MSCDC</PropertyEntry>

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 119
Example

CREATE REMOTE SOURCE "MySQLServerSource" ADAPTER "MssqlLogReaderAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="data_type_conversion" displayName="Data Type Conversion">
<PropertyEntry name="map_char_types_to_unicode" displayName="Always Map
Character Types to Unicode">false</PropertyEntry>
<PropertyEntry name="map_time_to_timestamp" displayName="Map SQL Server Data
Type Time to Timestamp">true</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_server_name" displayName="Host">myserver.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">1433</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc" displayName="CDC Properties">
<PropertyEntry name="pdb_dcmode" displayName="Database Data Capture
Mode">MSCDC</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader" displayName="LogReader">
<PropertyEntry name="skip_lr_errors" displayName="Ignore log record
processing errors">false</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
'WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>'

Related Information

Configure Data Provisioning Adapters [page 153]


Update the Data Provisioning Agent [page 145]
CREATE REMOTE SOURCE Statement [Smart Data Integration] [page 542]

2.7.3 Create Credentials for a Secondary User

The syntax for creating secondary user credentials for SAP HANA smart data integration adapters is different
from the syntax for SAP HANA system adapters.

The syntax for creating secondary user credentials for SAP HANA smart data integration adapters is as follows.

create credential for user <user_name> component 'SAPHANAFEDERATION'


purpose <remote_source_name> type 'PASSWORD' using
<CredentialEntry name="credential">
<user><user_name></user>
<password><password></password>

Installation and Configuration Guide


120 PUBLIC Configure Smart Data Integration
</CredentialEntry>

2.7.4 Configure a Grantor for the HDI Container

To build and execute flowgraphs and replication tasks in SAP Web IDE, first configure the grantor privilege.

Prerequisites

To configure the grantor privilege, you must have one or more remote sources already configured.

Procedure

1. In SAP HANA, create a grantor database user with the rights to grant privileges to others.

If necessary, create the grantor user and role, and grant the role to the user.

 Note

Grant the role with ADMIN OPTION.

For example:

CREATE USER GEN_GRANTOR_USER PASSWORD Welcome1 NO


FORCE_FIRST_PASSWORD_CHANGE;
CREATE ROLE GEN_GRANTOR_ROLE;
GRANT GEN_GRANTOR_ROLE TO GEN_GRANTOR_USER WITH ADMIN OPTION;

2. Grant the following privileges on the remote sources to the grantor role.
○ CREATE VIRTUAL TABLE
○ CREATE VIRTUAL FUNCTION
○ CREATE REMOTE SUBSCRIPTION
○ LINKED DATABASE
○ PROCESS REMOTE SUBSCRIPTION EXCEPTION
○ ALTER
○ DROP
3. For the SAP HANA Service, use the SAP Cloud Platform cockpit to create a user-provided grantor service.
a. In the SAP Cloud Platform cockpit, navigate to your space and create a user-provided service instance.
b. Specify the name of the service credentials.

For example, a service named “remote_system_grant_service” with the following credentials:

{
"host": "<hostname>",
"port": "<port_number>",
"certificate": "<host_certificate>",

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 121
"user": "GEN_GRANTOR_USER",
"password": "Welcome1",
"driver": "com.sap.db.jdbc.Driver",
"tags": [
"hana"
]
}

For more information, see Create User-Provided Service Instances Using the Cockpit .
4. For SAP HANA on-premise, log into SAP HANA as XSA_ADMIN and create a user-provided grantor service.
a. Log in using the XS command-line interface.
For example:

xs login -a https://<hostname>:<port> --skip-ssl-validation -u XSA_ADMIN -


p <password> -s SAP

b. If you use a different space for your SAP Web IDE project, change the space. Otherwise, the default is
“SAP”.

For example, to change to the “PROD” space:

xs t -s PROD

c. Create a user-provided service (CUPS).

Create a service for the grantor database user with a service name of your choice.

For example, with a service named “remote_system_grant_service”:

xs cups remote_system_grant_service -p
"{\"host\":\"hostname\",\"port\":\"port_number\",\"user\":
\"GEN_GRANTOR_USER\",\"password\":\"
Welcome1\",\"driver\":\"com.sap.db.jdbc.Driver\",\"tags\":[\"hana\"]}"

5. Add the grantor service to the database module in your SAP Web IDE project.

In the MTA development descriptor (mta.yaml), add the grantor service as a resource and build the project.

modules:
- name: hdb1
type: hdb
path: hdb1
requires:
- name: hdi_hdb1
properties:
TARGET_CONTAINER: ~{hdi-container-name}
- name: grant_service
resources:
- name: hdi_hdb1
properties:
hdi-container-name: ${service-name}
type: com.sap.xs.hdi-container
- name: grant_service
type: org.cloudfoundry.existing-service
parameters:
service-name: remote_system_grant_service

6. Create a grantor file in your project.

 Note

First create a database module in your project if one doesn’t already exist.

Installation and Configuration Guide


122 PUBLIC Configure Smart Data Integration
a. Right-click src and choose New - File.

Specify the filename with an extension of “hdbgrants”. For example, grants.hdbgrants.

 Note

If you’re creating the dictionary for object search, the ALTER privilege is required.

b. In the grantor file, specify the grantor service name and any remote sources that you want to use.

For example, for a remote source named “HanaRemoteSource”:

{
"remote_system_grant_service": {
"object_owner": {
"roles": [
"GEN_GRANTOR_ROLE"
],
"global_object_privileges": [{
"name":"HanaRemoteSource",
"type":"REMOTE SOURCE",
"privileges":[
"CREATE VIRTUAL TABLE", "CREATE REMOTE SUBSCRIPTION"
]
}]
},
"application_user": {
"roles": [
"GEN_GRANTOR_ROLE"
]
}
}
}

7. Build the database module.

 Tip

To avoid errors, build starting from the database module instead of right-clicking the hdbgrants file and
choosing Build Selected File.

Next Steps

After you have successfully built the module, you can create virtual table (hdbvirtualtable), flowgraph
(hdbflowgraph), and replication task (hdbreptask) objects in the SAP Web IDE space.

Related Information

GRANT Statement (Access Control) (SAP HANA SQL and System Views Reference)

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 123
2.8 Set Up Data Provisioning Monitoring

After you install SAP HANA smart data integration, you must take several actions to enable and access the
monitoring user interfaces for Data Provisioning Agents, remote subscriptions, and tasks.

These actions allow you to access the Data Provisioning monitors by either typing the URL directly in your
browser or through links in SAP HANA cockpit.

Grant Roles to Users [page 124]


Grant the appropriate roles to users who perform the various tasks in the Data Provisioning monitors.

Parent topic: Configure Smart Data Integration [page 24]

Previous task: Create a Remote Source [page 117]

Next: Enabling Enterprise Semantic Services [page 125]

Related Information

Download and Deploy the Data Provisioning Delivery Unit [page 33]
Monitoring Data Provisioning in the SAP HANA Web-based Development Workbench

2.8.1 Grant Roles to Users

Grant the appropriate roles to users who perform the various tasks in the Data Provisioning monitors.

Prerequisites

Ensure that you’ve been granted the SYSTEM privilege USER ADMIN to be able to create, alter, or delete users.

Procedure

1. Log in to SAP HANA studio with a user name that has been granted the USER ADMIN system privilege.
2. Grant the role sap.hana.im.dp.monitor.roles::Monitoring to those that perform monitoring tasks.
a. In the Systems view, expand your SAP HANA server name and expand Security.
b. Double-click the user name.
c. On the Granted Roles tab, click the + icon in the upper left corner.

Installation and Configuration Guide


124 PUBLIC Configure Smart Data Integration
d. On the Select Roles dialog, type dp in the search string box.
e. Select role sap.hana.im.dp.monitor.roles::Monitoring and click OK.
This role sap.hana.im.dp.monitor.roles::Monitoring allows the user to access the user interfaces of SAP
HANA Data Provisioning monitoring.

Next Steps

Users can access the monitors from SAP HANA cockpit or view the monitors directly by entering the following
URLs in a web browser:

● <host name>:80<2 digit instance number>/sap/hana/im/dp/monitor/?


view=DPAgentMonitor
● <host name>:80<2 digit instance number>/sap/hana/im/dp/monitor/?
view=DPSubscriptionMonitor
● <host name>:80<2 digit instance number>/sap/hana/im/dp/monitor/?
view=IMTaskMonitor

2.9 Enabling Enterprise Semantic Services

Enterprise Semantic Services provides an API to enable searching for publication artifacts or run-time objects
based on their metadata and contents. It is optional for SAP HANA smart data integration.

To enable Enterprise Semantic Services, an administrator does the following high-level tasks:

● Downloads the SAP HANA Enterprise Semantic Services delivery unit and installs it on the SAP HANA
platform
● Grants roles and privileges to users
● Publishes datasets to the Enterprise Semantic Services knowledge graph, or in the case of an application
that has already been configured to call the Enterprise Semantic Services REST API, the application
populates the knowledge graph

Setting Up the SAP HANA Instance for Enterprise Semantic Services [page 126]
The Enterprise Semantic Services component supports both on-premise multitenant and SAP HANA
cloud platform deployments.

Download Enterprise Semantic Services Delivery Unit [page 128]


Download the Enterprise Semantic Services delivery unit and deploy it to enable semantic searches of
data sources.

Importing the Enterprise Semantic Services Delivery Unit [page 128]


To install Enterprise Semantic Services (ESS), import the downloaded ESS delivery unit.

Install or Upgrade Enterprise Semantic Services (install.html) [page 130]


After downloading and importing the Enterprise Semantic Services (ESS) delivery unit, install this
component to enable semantic searches of data sources.

Grant Enterprise Semantic Services Roles and Privileges to Users [page 132]

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 125
After installing Enterprise Semantic Services, grant the necessary roles to the SAP HANA users who
will interact directly or indirectly with Enterprise Semantic Services.

Uninstall Enterprise Semantic Services [page 133]


You can permanently uninstall Enterprise Semantic Services, for example in the case of an upgrade.

Parent topic: Configure Smart Data Integration [page 24]

Previous: Set Up Data Provisioning Monitoring [page 124]

Next: Enable SAP HANA Smart Data Integration REST API [page 133]

Related Information

SAP HANA Enterprise Semantic Services JavaScript API Reference


SAP HANA Enterprise Semantic Services REST API Reference

2.9.1 Setting Up the SAP HANA Instance for Enterprise


Semantic Services

The Enterprise Semantic Services component supports both on-premise multitenant and SAP HANA cloud
platform deployments.

For details on supported versions, see the applicable Product Availability Matrix.

Related Information

On-Premise Multitenant Deployment [page 127]


SAP HANA smart data quality and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 1.0
SAP HANA smart data quality and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Installation and Configuration Guide


126 PUBLIC Configure Smart Data Integration
2.9.1.1 On-Premise Multitenant Deployment

For a multitenant deployment, Enterprise Semantic Services requires the SAP HANA script server and access
to multitenant database containers.

Prerequisites

● A SAP HANA instance has been installed with multiple containers


● At least one tenant database container has been created. For example, DB0.

Procedure

1. Add the scriptserver service to the tenant database.

For example, in the Web-based Development Workbench or SAP HANA studio, enter the following SQL
statement:

ALTER DATABASE DB0 ADD 'scriptserver';

 Note

If the SAP HANA smart data quality component is already installed, then the scriptserver service has
already been added.

2. Configure HTTP access to multitenant database containers.

See the SAP HANA Administration Guide.

Related Information

Configure HTTP(S) Access to Tenant Databases via SAP HANA XS Classic (SAP HANA Administration Guide)
Port Assignment in Tenant Databases (SAP HANA Administration Guide)

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 127
2.9.2 Download Enterprise Semantic Services Delivery Unit

Download the Enterprise Semantic Services delivery unit and deploy it to enable semantic searches of data
sources.

Procedure

1. Go to the SAP Software Download Center .


2. Click Access Downloads, under either Installations & Upgrades or Support Packages & Patches.
3. In the search box at the top of the page, enter hanaimess.
4. From the list of available downloads, select the desired version. See the Product Availablity Matrix >
Product Infrastructure Dependency pages for a version of Enterprise Semantic Services that is compatible
with your product version.
5. Click the Add Selected Items to Download Basket icon.
6. Select Download Basket and select the ZIP file to download it.
7. Within the downloaded ZIP file, locate the .tgz file and click Extract to put it into a folder of your choice.

Related Information

SAP HANA smart data integration Product Availability Matrix

2.9.3 Importing the Enterprise Semantic Services Delivery


Unit

To install Enterprise Semantic Services (ESS), import the downloaded ESS delivery unit.

You can import the delivery using one of two interfaces:

● SAP HANA studio


● SAP HANA Application Lifecycle Management

Related Information

Import the ESS Delivery Unit with SAP HANA Studio [page 129]
Import the ESS Delivery Unit with SAP HANA Application Lifecycle Management [page 129]

Installation and Configuration Guide


128 PUBLIC Configure Smart Data Integration
2.9.3.1 Import the ESS Delivery Unit with SAP HANA
Studio

How to import the Enterprise Semantic Services (ESS) delivery unit using SAP HANA studio.

Prerequisites

You have already downloaded the ESS delivery unit.

Procedure

1. Log in to SAP HANA studio as user SYSTEM.

2. In the upper left corner, click File Import .


3. On the Import dialog, type delivery unit into the search box for Select an import source.
4. Click Next.
5. Select <your SAP HANA Server name> for the target system, and click Next.
6. Select the HANAIMESS.tgz file that you downloaded.
7. Click Finish.
8. In Job Log view, the status should be Completed successfully.

2.9.3.2 Import the ESS Delivery Unit with SAP HANA


Application Lifecycle Management

How to import the Enterprise Semantic Services (ESS) delivery unit using SAP HANA Application Lifecycle
Management.

Prerequisites

You have already downloaded the ESS delivery unit.

Context

For multitenant database deployment, import the delivery unit on a tenant database, not on the system
database.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 129
Procedure

1. If not already granted, grant the role sap.hana.xs.lm.roles::Administrator to the user name you will use to
log in to SAP HANA Application Lifecycle Management.

a. In SAP HANA studio Systems view, expand the name of your SAP HANA server and choose Security
Users System .
b. On the Granted Roles tab, click the green + icon in the upper left corner.
c. On the Select Roles dialog, type lm in the search string box.
d. Select role sap.hana.xs.lm.roles::Administrator and click OK.
2. Open SAP HANA Application Lifecycle Management by entering the following URL in a web browser:
<host name>:80<2-digit instance number>/sap/hana/xs/lm
3. Log in with the user name you authorized in step 1.
The first time you log in, a pop-up window appears asking you to enter a name for this server.
4. On the Home tab, click the Delivery Units tile.
5. Click Import.
6. Click Browse, navigate to where you downloaded the delivery unit, select the .tgz file, and click Open.
7. Click Import.

Results

After successful import, the name of the delivery unit displays in the list on the left.

2.9.4 Install or Upgrade Enterprise Semantic Services


(install.html)

After downloading and importing the Enterprise Semantic Services (ESS) delivery unit, install this component
to enable semantic searches of data sources.

Prerequisites

If you are upgrading ESS:

● Upgrade your SAP HANA instance if you need to upgrade to a new SPS revision.
● If installed, uninstall the DEMO delivery unit.
● If you are upgrading from a version earlier than 1.0 SP03 Rev0 (1.3.0), first unininstall Enterprise Semantic
Services.

Installation and Configuration Guide


130 PUBLIC Configure Smart Data Integration
Context

● If you have ESS version SPS01 Patch 1, also known as 1.0 SP00 Rev1, or earlier, follow the procedure that
requires the installation script install.xsjs.
● If you have ESS version SPS01 Patch 2, also known as 1.0 SP01 Rev2, or later, follow this procedure, which
requires the installation script install.html.

Procedure

1. Access the ESS installation URL using the following structure:


○ For SAP HANA 1.0:
http://<hostname>:port>/sap/hana/im/ess/setup/install.html
○ For SAP HANA 2.0:
http://<tenant db name>.<hostname>:port>/sap/hana/im/ess/setup/install.html
Refer to the SAP HANA Administration Guide for more information on HTTP access requirements regarding
SSL, port numbers, and multitentnant database containers.
2. Log in with the SYSTEM user. If the SYSTEM user is not available, then use any other administrative user
and assign it the sap.hana.im.ess.roles.setup::SE_Installer role for the duration of the
installation.
3. On the Welcome page, click Run ESS Setup.

You can monitor the details of the installation status.


4. Enter a password for ESS technical users and click Submit.
5. Ensure the _HANA_IM_ESS, _HANA_IM_ESS_CTID and _HANA_IM_ESS_PROFILING technical users have
been created by the installation script in SAP HANA.

Results

Successful installation is indicated with the message Setup completed including a status table that lists each
setting.

At any point in the installation you can monitor its status by accessing the install.html URL. Any errors display
with messages for corrective actions.

Related Information

Uninstall Enterprise Semantic Services [page 133]


Maintaining HTTP Access to SAP HANA (SAP HANA Administration Guide)

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 131
2.9.5 Grant Enterprise Semantic Services Roles and
Privileges to Users

After installing Enterprise Semantic Services, grant the necessary roles to the SAP HANA users who will
interact directly or indirectly with Enterprise Semantic Services.

Procedure

1. Log in to SAP HANA with a user name that has the EXECUTE privilege on the GRANT_ACTIVATED_ROLE
procedure on the Object Privileges of the user.
2. In the Systems view, expand Security in one of the following database names:

○ If you are installing on SAP HANA Version 1.0, select <your SYSTEM database name> and expand
Security.
○ If you are installing on SAP HANA Version 2.0, select<your TENANT database name> and expand
Security.
3. Grant the appropriate role to each user by following these steps:
a. Double-click the user name.
b. On the Granted Roles tab, click the “+” icon in the upper left corner.
c. On the Select Roles dialog, type ess in the search string box.
d. Select the appropriate role for this user and click OK.

Option Description

sap.hana.im.ess.roles::Administrator For users who will access the Enterprise Semantic Services Adminis­
tration user interface

sap.hana.im.ess.roles::Publisher For users who will access the Enterprise Semantic Services publica­
tion API to define content to be published in the knowledge graph.

sap.hana.im.ess.roles::User For users who will access the Enterprise Semantic Services con­
sumption (read-only) APIs such as Search, Autocomplete, and con­
tent-type identification (CTID).

4. Alternatively, you can open the SQL console of the SAP HANA studio and execute the following statements:

CALL
"_SYS_REPO"."GRANT_ACTIVATED_ROLE"( 'sap.hana.im.ess.roles::Administrator ',
'<USER_NAME> ')

CALL "_SYS_REPO"."GRANT_ACTIVATED_ROLE"( 'sap.hana.im.ess.roles::Publisher ',


'<USER_NAME> ')

CALL "_SYS_REPO"."GRANT_ACTIVATED_ROLE"( 'sap.hana.im.ess.roles::User ',


'<USER_NAME> ')

Installation and Configuration Guide


132 PUBLIC Configure Smart Data Integration
2.9.6 Uninstall Enterprise Semantic Services

You can permanently uninstall Enterprise Semantic Services, for example in the case of an upgrade.

Prerequisites

● If SAP Agile Data Preparation is installed, uninstall it first.


● Add the role sap.hana.im.ess.role::Administrator to the SYSTEM user or the user performing the uninstall.

Procedure

1. Remove the delivery unit.


a. Enter the following URL in a web browser:

http://<<your_HANA_instance:port>>/sap/hana/xs/lm
b. Choose Products Delivery Units .
c. Select HANA_IM_ESS.
d. Click Delete.
e. Click the checkbox including objects and packages.
f. Confirm the deletion.
2. Remove the ESS users.

In the Web-based Development Workbench or SAP HANA studio, drop the Enterprise Semantic Services
users. For example, in SAP HANA studio, enter the following SQL statements:

DROP USER _HANA_IM_ESS CASCADE;


DROP USER _HANA_IM_ESS_PROFILING CASCADE;
DROP USER _HANA_IM_ESS_CTID CASCADE

3. Remove the schema.

In the Web-based Development Workbench or SAP HANA studio, drop the HANA_IM_ESS schema. For
example, in SAP HANA studio, enter the following SQL statement:

DROP SCHEMA SAP_HANA_IM_ESS CASCADE;

2.10 Enable SAP HANA Smart Data Integration REST API

Use the SAP HANA smart data integration REST API to programmatically execute and monitor flowgraphs and
to process data for interactive data transformation within your application.

For more information, see the SAP HANA Smart Data Integration REST API Developer Guide.

Installation and Configuration Guide


Configure Smart Data Integration PUBLIC 133
Parent topic: Configure Smart Data Integration [page 24]

Previous: Enabling Enterprise Semantic Services [page 125]

Installation and Configuration Guide


134 PUBLIC Configure Smart Data Integration
3 Configure Smart Data Quality

To take advantage of SAP HANA smart data quality functionality, you must perform a few tasks.

Procedure

1. Add the scriptserver service to the SAP HANA tenant database.


2. Download and deploy the smart data quality directories.
3. Configure the operation cache.
4. Set monitoring alerts to inform you when the directories expire.

Related Information

Directories [page 135]


Add or Remove Services in a Tenant Database (SAP HANA Administration Guide)
Configuring the Operation Cache
Creating Monitoring Alerts
Monitoring Alerts (SAP HANA Administration Guide)

3.1 Directories

Download and deploy directories to take advantage of smart data quality functionality.

Context

The Cleanse and Geocode nodes rely on reference data found in directories that you download and deploy to
the SAP HANA server.

If reference data isn’t provided, the Cleanse node performs parsing, but doesn’t perform assignment.
Additionally, you’re able to create and activate flowgraphs that include the Geocode node, but their execution
fails.

You may need to download multiple directories, depending on your license agreement.

Installation and Configuration Guide


Configure Smart Data Quality PUBLIC 135
 Note

Before you install your directories, stop the Script Server, and then restart it once the installation is
complete. Make sure that you don’t have any running flowgraph tasks.

Related Information

Install or Update Directories on the SAP HANA Host Using Lifecycle Manager [page 136]
Install or Update Directories from a Web Browser Using Lifecycle Manager [page 138]
Integrate Existing Directories into Lifecycle Manager [page 141]
Uninstall Directories [page 144]
Address Directories & Reference Data

3.1.1 Install or Update Directories on the SAP HANA Host


Using Lifecycle Manager

Follow these steps the first time you install the directories on an SAP HANA host or update the directories after
you have a release-dated folder.

Procedure

1. Log into the SAP HANA machine.


2. Create a new folder for the directories. For example, <filepath>/Directories.

 Note

The default location is where SAP HANA is installed. Choose a different directory path, so the
directories and reference data are separate from the SAP HANA installation. If you decide to uninstall
SAP HANA with the directories in the default path, then the directories are uninstalled also.

3. Set the directory folder owner to sudo chown <sid>adm:sapsys/Directories.

 Note

In this document, when referring to the “sidadm”, the “sid” is lowercase. When referring to the “SID”,
the “SID” is uppercase.

4. Open the SAP HANA Platform Lifecycle Management Web site https://<hostname>:1129/lmsl/
HDBLCM/<SID>/index.html. Log in with your <sidadm> user name and password.
5. Click Download Components and specify the download mode as Download Archives on the SAP HANA
Host, and then click Next.
6. Enter your user ID and password, and click Next.

Installation and Configuration Guide


136 PUBLIC Configure Smart Data Quality
Your user ID begins with an “S” followed by 10 digits and is tied to an account with active directories. For
example, “S0123456789”.

7. Click Show Components Installable and Updatable Components .

8. Select Component Type Address Directories and Reference Data .


The list of directories that you can update or install appears. Select the directory and reference data to
install or update. Click Next.
9. If you’re updating the directories, you can skip this step because the path is already set. Otherwise, enter
the directory path that you created in steps 2. Click Next.
The directories are in a compressed file that must be extracted. You can specify the same extract directory
as the download directory.

 Note

10. Verify the settings in the summary, then click Download.


11. After you’ve downloaded and extracted the directories, click Prepare Update.
12. On the Select Components window, choose the data to install or update and click Next.
13. In the Specify Authorization window, enter the system administrator password, database user name, and
database user password. Click Next until you get to the Define Reference Data Properties window.
14. In the Define Reference Data Properties window, set the installation path for address directories and
reference data. For example, <filepath>/Directories/installed. The location you specify here is
the reference data path. Click Next.
15. On the Review & Confirm window, verify that the information is correct and then click Update.
16. Click Close to return to the Lifecycle Manager window.
17. (Optional) To verify that the directory is installed, open SAP HANA Studio and connect to the SYSTEM
database.

18. Right-click on the system name and select Configuration and Monitoring Open Administration .
19. On the Configuration tab, enter dq in the filter and press Enter.

The dq_reference_data_path is set with the reference data path you defined under the Default column.
This path automatically has a dated folder at the end. For example, <filepath>/Directories/
2017-07/.
20.(Optional) To delete old directory data, open a file browser and navigate to the directory location. Select
the old release-dated folder and press Delete.

 Caution

Some directory data is updated monthly and other directory data is updated quarterly. Therefore, the
monthly release folders can contain a link to the directories in an older release folder rather than to the
actual directory data. Before deleting, be sure that those directories aren’t in use.

21. Configure the operations cache to improve performance. See "Configuring the Operation Cache" in the
SAP HANA Smart Data Integration and Smart Data Quality Administration Guide.
22. Set alerts to be notified of when the directories expire. Configure monitoring alerts from SAP HANA
cockpit. For more information, see “Monitoring Alerts” in the SAP HANA Administration Guide.

Installation and Configuration Guide


Configure Smart Data Quality PUBLIC 137
Related Information

Configuring the Operation Cache


Creating Monitoring Alerts

3.1.2 Install or Update Directories from a Web Browser Using


Lifecycle Manager

Follow these steps the first time you install the directories using a web browser or update the directories using
a web browser after you have a release-dated folder.

Procedure

1. Log into the SAP HANA machine.


2. Create a new folder for the directories. For example, <filepath>/Directories.

 Note

The default location is where SAP HANA is installed. Choose a different directory path, so the
directories and reference data are separate from the SAP HANA installation. If you decide to uninstall
SAP HANA with the directories in the default path, then the directories are uninstalled also.

3. Set the directory folder owner to sudo chown <sid>adm:sapsys/Directories.

 Note

In this document, when referring to the “sidadm”, the “sid” is lowercase. When referring to the “SID”,
the “SID” is uppercase.

4. Open the SAP HANA Platform Lifecycle Management Web site https://<hostname>:1129/lmsl/
HDBLCM/<SID>/index.html. Log in with your <sidadm> user name and password.
5. Click Download Components and specify the download mode as Download Archives via the Web Browser,
and then click Next.
6. Enter your user ID and password, and click Next.

Your user ID begins with an “S” followed by 10 digits and is tied to an account with active directories. For
example, “S0123456789”.

7. Click Show Components Installable and Updatable Components .

8. Select Component Type Address Directories and Reference Data .


The list of directories that you can install or update appears. Select the directory and reference data to
install or update. Click Next.
9. Click Download. If there are multiple directories, click Download All. Wait for the directories to complete
downloading.

Installation and Configuration Guide


138 PUBLIC Configure Smart Data Quality
10. Click Upload/Extract Components.
11. Choose one of the methods:

○ The Archives are Accessible from the SAP HANA Host. Copy the Address Directories to a location that
can be accessed by the <sidadm>. We recommend that the <sidadm> creates this directory, so the
permissions are correct.
○ Upload Archives to the SAP HANA Host. See the steps for uploading archives in the topic Upload
Archives to the SAP HANA Host [page 140].
12. Enter the shared location.

 Note

If the location box turns red, either there’s an invalid path or the location doesn’t have the required
permission for the <sidadm>.

13. Click Next to extract the Address Directories.

 Note

If the location box turns red, either there’s an invalid path or the location doesn’t have the required
permission for the <sidadm>.

14. Review and confirm the information, and then click Next.
15. Click Close after the Upload/Extract Components is finished.
16. Click Install or Update Additional Components.
17. Click Add Software Locations.
18. Enter the path to the extracted folder from the previous step, and then click Search also in Subfolder. Click
Next.
19. Select the Address Directories that you want to install or click Select All.

 Note

If a warning about “too loose permissions” is shown, you may ignore the message.

20.Enter the system administrator password, database user name, and database user password in the Specify
Authorization window.
21. Set the installation path for address directories and reference data in the Define Reference Data Properties
window. For example, <filepath>/Directories/installed. The location you specify here is the
reference data path. Click Next.
22. Verify that the information is correct on the Review & Confirm window, and then click Update.
23. Click Close to return to the Lifecycle Manager window.

Next Steps

To verify that the directories are installed:

1. Open SAP HANA Studio and connect to the SYSTEM database.


2. Right-click the system name and select Configuration and Monitoring Open Administration .

Installation and Configuration Guide


Configure Smart Data Quality PUBLIC 139
3. Type dq in the filter on the Configuration tab, and then press Enter.
The dq_reference_data_path is set with the reference data path you defined under the Default column. This
path automatically has a dated folder at the end. For example, <filepath>/Directories/2017-07/.
4. If you use Operation Caches, we recommend that you restart them:

 Sample Code

ALTER SYSTEM ALTER CONFIGURATION ('scriptserver.ini', 'SYSTEM') SET

('adapter_operation_cache', 'enable_adapter_operation_cache') = 'no' WITH


RECONFIGURE

 Sample Code

ALTER SYSTEM ALTER CONFIGURATION ('scriptserver.ini', 'SYSTEM') SET

('adapter_operation_cache', 'enable_adapter_operation_cache') = 'yes' WITH


RECONFIGURE

Related Information

Upload Archives to the SAP HANA Host [page 140]

3.1.2.1 Upload Archives to the SAP HANA Host

If you installed or updated directories from a web browser using Lifecycle Manager and want to upload the
archives to the SAP HANA Host, follow these steps.

Procedure

1. Click Select Archives for Upload. Enter the path to the location where the Address Directories were
downloaded and select all ZIP files.
2. Click Upload.
3. Confirm the Temporary Extract Path, and then click Next.

 Note

Make a note of this path, because you’ll use it when adding software locations.

4. Click Extract, and then Close.


5. Click Install or Update Additional Components.

Installation and Configuration Guide


140 PUBLIC Configure Smart Data Quality
6. Click Add Software Locations, and enter the Temporary Extract Path from the earlier step.
7. Click the Search also in subfolders checkbox, and then click Add.
8. Click Next.
9. Click the Address Directories you want to install or click Select All, and then click Next.

 Note

If a warning about “too loose permissions” is shown, you can ignore the message.

10. Enter the system administrator password, database user name, and database user password in the Specify
Authorization.
11. Set the installation path for address directories and reference data in the Define Reference Data Properties
window. For example, <filepath>/Directories/installed. The location you specify here is the
reference data path. Click Next.
12. Verify that the information is correct on the Review & Confirm window, and then click Update.
13. Click Close to return to the Lifecycle Manager window.

Next Steps

You can verify that the directories are installed by following the instructions at the end of the Install or Update
Directories from a Web Browser Using Lifecycle Manager [page 138] topic.

3.1.3 Integrate Existing Directories into Lifecycle Manager

If you downloaded your directories from the Support Portal using Download Manager, use this procedure to
update your directories.

Prerequisites

You’ve downloaded your directories from the Support Portal.

Context

Lifecycle Manager organizes your reference data to make installing and updating your directories easier by
creating release-dated folders.

Installation and Configuration Guide


Configure Smart Data Quality PUBLIC 141
Procedure

1. Open SAP HANA Studio and connect to the SYSTEM database.


2. On the Configuration tab, enter dq in the filter, and press Enter.

○ If a path is empty for the System and Databases columns, then continue to the next step.
○ If the paths for the System and Databases columns are different from each other, then update the
System column to be the master reference data path by double-clicking the value in the System
column. In the System section, enter the path in the New Value option. Delete any paths in the New
Value option under the Databases section.

 Note

If you have multiple tenants that require different reference data paths, you can manage them
outside of SAP HANA Lifecycle Manager.

3. Log into the SAP HANA machine.


4. Create a new folder for the directories. For example, <filepath>/Directories.

 Note

Choose a different directory path from the location where SAP HANA is installed. Separate locations
ensure that the directories and reference data are separate from the SAP HANA installation. If you
decide to uninstall SAP HANA with the directories in the same path as SAP HANA, then the directories
are uninstalled also.

5. Set the directory folder owner to sudo chown <sid> adm:sapsys/Directories.

 Note

In this document, when referring to the “sidadm”, the “sid” is lowercase. When referring to the “SID”,
the “SID” is uppercase.

6. Open the SAP HANA Platform Lifecycle Management Web site https://<hostname>:1129/lmsl/HDBLCM/
<SID>/index.html. Log in with your <sidadm> username and password.
7. Click Download Components and specify the download mode.
8. Enter your user ID and password, and click Next.

Your user ID begins with an “S”, followed by 10 digits, and it’s tied to an account with active directories. For
example, “S0123456789”.

9. Click Show Components Installable and Updatable Components .

10. Select Component Type Address Directories and Reference Data .


The list of directories that you can update or install appears. Select the directory and reference data to
install or update. Click Next.
11. If you’re updating the directories, you can skip this step, because the path is already set. Otherwise, enter
the directory path that you created in steps 4 through 5. Click Next.
The directories are in a compressed file that must be extracted. You can specify the same extract directory
as the download directory.

 Note

Installation and Configuration Guide


142 PUBLIC Configure Smart Data Quality
12. Verify the settings in the summary, then click Download.
13. After you’ve downloaded and extracted the directories, click Prepare Update.
14. On the Select Components window, choose the data to install or update and click Next.
15. In the Specify Authorization window, enter the system administrator password, database user name, and
database user password. Click Next until you get to the Define Reference Data Properties window.
16. In the Define Reference Data Properties window, set the installation path for address directories and
reference data. For example, <filepath>/Directories/installed. Use the path that you specified at
the beginning of this procedure. The location you specify here is the reference data path. Click Next.

 Note

If you have set the path at the beginning of this procedure, you may not see this window.

17. On the Review & Confirm window, verify that the information is correct and then click Update.
18. Click Close to return to the Lifecycle Manager window.
19. (Optional) To verify that the directory is installed, open SAP HANA Studio and connect to the SYSTEM
database.
20.(Optional) On the Configuration tab, enter dq in the filter and press Enter.

The dq_reference_data_path is set with the reference data path you defined under the Default column.
This path automatically has a dated folder at the end. For example, <filepath>/Directories/
2017-07/.
21. (Optional) To delete old directory data, open a file browser, and navigate to the directory location. Select
the old release-dated folder and press Delete.

 Caution

Some directory data is updated monthly and other directory data is updated quarterly. Therefore, the
monthly release folders may contain a link to the directories in an older release folder, rather than to
the actual directory data. Before deleting, be sure that those directories aren’t in use.

22. Configure the operations cache to improve performance. See "Configuring the Operation Cache" in the
SAP HANA Smart Data Integration and Smart Data Quality Administration Guide.
23. Set alerts to be notified of when the directories expire. Configure monitoring alerts from the SAP HANA
cockpit. For more information, see “Monitoring Alerts” in the SAP HANA Administration Guide.

Related Information

Configuring the Operation Cache


Creating Monitoring Alerts

Installation and Configuration Guide


Configure Smart Data Quality PUBLIC 143
3.1.4 Uninstall Directories

When you’re finished using the directory information, you can uninstall the directories from the system.

Procedure

1. Open SAP HANA Studio and connect to the SAP HANA Server as the SYSTEM user.

2. Right-click the system name and select Configuration and Monitoring Open Administration .
3. Click the Configuration tab and type dq in the Filter option.
The dq_reference_data_path in the scriptserver.ini file appears in the list. Make a note of the
system path. For example, /<filepath>/Directories/installed/2017-05/.
4. Right-click dq_reference_data_path, and then click Delete.
5. Select the system, and then click Delete.
6. Open a file browser and delete the folder that was in the dq_reference_data_path.

7. (Optional) To verify that the directories were deleted, click View System Information Installed
Components .

Installation and Configuration Guide


144 PUBLIC Configure Smart Data Quality
4 Update Smart Data Integration

When updating your SAP HANA Smart Data Integration landscape to a new version, consider the steps that
must be taken for each component.

Update the Data Provisioning Agent [page 145]


Update the Data Provisioning Agent by running the installation program in update mode.

Install or Upgrade Enterprise Semantic Services (install.html) [page 148]


After downloading and importing the Enterprise Semantic Services (ESS) delivery unit, install this
component to enable semantic searches of data sources.

Related Information

4.1 Update the Data Provisioning Agent

Update the Data Provisioning Agent by running the installation program in update mode.

Prerequisites

Before you update the Data Provisioning Agent, ensure that your SAP HANA server has already been updated
to the same revision.

If your agent has remote source subscriptions for real-time data capture, you must also suspend capture
before upgrading the agent. To suspend active remote source subscriptions, use the SQL console in the SAP
HANA Studio or Web-based Development Workbench:

ALTER REMOTE SOURCE <remote_source_name> SUSPEND CAPTURE

 Note

To verify the success of the upgrade for log reader adapters, set the adapter framework logging level to
INFO. To change the adapter framework logging level, choose Preferences Adapter Framework
Logging Level in the SAP HANA Data Provisioning Agent Configuration tool.

Installation and Configuration Guide


Update Smart Data Integration PUBLIC 145
Procedure

1. Download and extract the software to an empty directory.


2. Stop the existing SAP HANA Data Provisioning Agent service.
○ On Windows, use the Services manager in Control Panel.
○ On Linux, navigate to <DPAgent_root>/bin, and run ./dpagent_service.sh stop.

 Note

Stop the service using the Data Provisioning Agent installation owner. The installation owner is the
same user that is used to start the agent service.

3. Navigate to the directory where you unpacked the software.


4. Call the installation manager.

○ On Windows, right-click on hdbsetup.exe and choose Run as administrator.


○ On Linux, run ./hdbsetup.
Use the same user and privileges as the original installation owner.
For example, if sudo was used during the original installation, log in as the installation owner and run
sudo ./hdbsetup. If you call the installation manager with a different user or privileges, the existing
installation may not be recognized.

 Tip

To upgrade the agent in command-line mode, use hdbinst.exe on Windows or ./hdbinst on Linux.

5. Choose Update SAP HANA Data Provisioning Agent and select the path of the existing agent that you want
to update.

In command-line mode, enter the number of the existing agent as listed by the installation program.
6. On Windows, specify the unique agent name and the agent service username and password.
You can specify a new unique name or use the same one as before, but it must be different than any names
already used by other agent instances on the same host system.
7. On Linux, start the agent service.

 Tip

On Windows, the agent service is re-created and started automatically.

 Note

Start the service using the Data Provisioning Agent installation owner. The installation owner is the
same user that is normally used to start the agent service.

a. Navigate to the <DPAgent_root>/bin directory.


b. Run ./dpagent_service.sh start.
8. Apply new adapter capabilities.

To allow SAP HANA to detect any new adapter capabilities, use the SQL console.
a. Retrieve a list of the adapters configured in your environment.

select * from "SYS"."ADAPTERS" where "IS_SYSTEM_ADAPTER" like 'FALSE'

Installation and Configuration Guide


146 PUBLIC Update Smart Data Integration
b. Refresh each adapter listed by the previous command.

ALTER ADAPTER "<adapter_name>" REFRESH AT LOCATION AGENT"<agent_name>"

 Note

If you have multiple agents in your SAP HANA environment, refresh each adapter only a single time
with an upgraded agent. Refreshing the adapters with each agent isn’t necessary.

Results

The Data Provisioning Agent is updated to the new version.

Next Steps

 Tip

After updating the Data Provisioning Agent, we recommend that you review the update log file for any
errors, and take any necessary corrective actions.

If you suspended capture for remote source subscriptions on the agent, you can now resume capture.

 Caution

Before resuming capture, you must first upgrade all agents in your SAP HANA environment. If you haven’t
upgraded all agents, do that first and then return to this section.

After all agents have been upgraded, use the SQL console to resume capture:

ALTER REMOTE SOURCE <remote_source_name> RESUME CAPTURE

Repeat the command for each remote source subscription in your environment.

 Tip

After you resume a remote source subscription, additional automatic upgrade steps take approximately 10
minutes to complete. To verify that the process has completed successfully, view the Data Provisioning
Agent framework log:

● When the adapter upgrade has been completed, you should see the message
<remote_source_name> has been upgraded successfully.
● When the real-time replication has been resumed, you should see the message
<remote_source_name> is resumed successfully.

Installation and Configuration Guide


Update Smart Data Integration PUBLIC 147
4.2 Install or Upgrade Enterprise Semantic Services
(install.html)

After downloading and importing the Enterprise Semantic Services (ESS) delivery unit, install this component
to enable semantic searches of data sources.

Prerequisites

If you are upgrading ESS:

● Upgrade your SAP HANA instance if you need to upgrade to a new SPS revision.
● If installed, uninstall the DEMO delivery unit.
● If you are upgrading from a version earlier than 1.0 SP03 Rev0 (1.3.0), first unininstall Enterprise Semantic
Services.

Context

● If you have ESS version SPS01 Patch 1, also known as 1.0 SP00 Rev1, or earlier, follow the procedure that
requires the installation script install.xsjs.
● If you have ESS version SPS01 Patch 2, also known as 1.0 SP01 Rev2, or later, follow this procedure, which
requires the installation script install.html.

Procedure

1. Access the ESS installation URL using the following structure:


○ For SAP HANA 1.0:
http://<hostname>:port>/sap/hana/im/ess/setup/install.html
○ For SAP HANA 2.0:
http://<tenant db name>.<hostname>:port>/sap/hana/im/ess/setup/install.html
Refer to the SAP HANA Administration Guide for more information on HTTP access requirements regarding
SSL, port numbers, and multitentnant database containers.
2. Log in with the SYSTEM user. If the SYSTEM user is not available, then use any other administrative user
and assign it the sap.hana.im.ess.roles.setup::SE_Installer role for the duration of the
installation.
3. On the Welcome page, click Run ESS Setup.

You can monitor the details of the installation status.


4. Enter a password for ESS technical users and click Submit.
5. Ensure the _HANA_IM_ESS, _HANA_IM_ESS_CTID and _HANA_IM_ESS_PROFILING technical users have
been created by the installation script in SAP HANA.

Installation and Configuration Guide


148 PUBLIC Update Smart Data Integration
Results

Successful installation is indicated with the message Setup completed including a status table that lists each
setting.

At any point in the installation you can monitor its status by accessing the install.html URL. Any errors display
with messages for corrective actions.

Related Information

Uninstall Enterprise Semantic Services [page 133]


Maintaining HTTP Access to SAP HANA (SAP HANA Administration Guide)

Installation and Configuration Guide


Update Smart Data Integration PUBLIC 149
5 Uninstall Smart Data Integration

To uninstall SAP HANA Smart Data Integration, perform the required uninstallation tasks for each component
in the landscape.

Uninstall the Data Provisioning Agent [page 150]


Uninstall the Data Provisioning Agent from a host system using the uninstallation manager.

Uninstall Enterprise Semantic Services [page 152]


You can permanently uninstall Enterprise Semantic Services, for example in the case of an upgrade.

Related Information

5.1 Uninstall the Data Provisioning Agent

Uninstall the Data Provisioning Agent from a host system using the uninstallation manager.

Context

The uninstallation manager supports graphical and command-line modes on Windows and Linux platforms.

Procedure

● Uninstall the agent from a Windows host in graphical mode.


Call the uninstallation manager from the Control Panel:

Programs and Features SAP HANA Data Provisioning Agent Uninstall


● Uninstall the agent from a Windows host in command-line mode.
a. Navigate to the <DPAgent_root>/install directory.

For example, C:\usr\sap\dataprovagent\install.


b. Call the installation manager.
hdbuninst.exe --path "<DPAgent_root>"
● Uninstall the agent from a Linux host in graphical or command-line mode.

Installation and Configuration Guide


150 PUBLIC Uninstall Smart Data Integration
a. Navigate to the <DPAgent_root>/install directory.

For example, /usr/sap/dataprovagent/install.


b. Call the uninstallation manager.
○ For graphical mode: ./hdbuninst --main
SDB::Install::App::Gui::Uninstallation::main --path "<DPAgent_root>"
○ For command-line mode: ./hdbuninst --path "<DPAgent_root>"

 Tip

To ensure that all installation entries are removed correctly, use the same user and privileges as the
original installation owner.

For example, if sudo was used during the original installation, log in as the installation owner and
run sudo ./hdbuninst <...>.

Results

The Data Provisioning Agent is uninstalled from the system.

Next Steps

After uninstalling the agent, several files and directories generated by the agent during runtime are left in place.
If you choose, you can safely remove these remaining files and directories manually.

Remove the following files and directories from <DPAgent_root>:

● configTool/
● configuration/
● install/
● log/
● LogReader/
● workspace/

Installation and Configuration Guide


Uninstall Smart Data Integration PUBLIC 151
5.2 Uninstall Enterprise Semantic Services

You can permanently uninstall Enterprise Semantic Services, for example in the case of an upgrade.

Prerequisites

● If SAP Agile Data Preparation is installed, uninstall it first.


● Add the role sap.hana.im.ess.role::Administrator to the SYSTEM user or the user performing the uninstall.

Procedure

1. Remove the delivery unit.


a. Enter the following URL in a web browser:

http://<<your_HANA_instance:port>>/sap/hana/xs/lm
b. Choose Products Delivery Units .
c. Select HANA_IM_ESS.
d. Click Delete.
e. Click the checkbox including objects and packages.
f. Confirm the deletion.
2. Remove the ESS users.

In the Web-based Development Workbench or SAP HANA studio, drop the Enterprise Semantic Services
users. For example, in SAP HANA studio, enter the following SQL statements:

DROP USER _HANA_IM_ESS CASCADE;


DROP USER _HANA_IM_ESS_PROFILING CASCADE;
DROP USER _HANA_IM_ESS_CTID CASCADE

3. Remove the schema.

In the Web-based Development Workbench or SAP HANA studio, drop the HANA_IM_ESS schema. For
example, in SAP HANA studio, enter the following SQL statement:

DROP SCHEMA SAP_HANA_IM_ESS CASCADE;

Installation and Configuration Guide


152 PUBLIC Uninstall Smart Data Integration
6 Configure Data Provisioning Adapters

Data provisioning adapters can connect to a variety of sources to move data into SAP HANA, and well as other
use cases.

The adapters in the following table are delivered with the Data Provisioning Agent. For information about
configuring your adapter, see the documentation about each adapter in this guide.

 Note

Before configuring your adapters and remote sources, make sure that the Data Provisioning Agent is
configured and that the necessary JDBC libraries are installed.

For information about using adapters for replication or transformation, see the Modeling Guide for SAP HANA
Smart Data Integration and SAP HANA Smart Data Quality.

If the source you’re using isn’t covered by the adapters listed, use the Adapter SDK to create custom adapters
to suit your needs. See the Adapter SDK Guide for SAP HANA Smart Data Integration for more information.

See the Product Availability Matrix for information about supported versions.

Adapter Name Description

ABAPAdapter Retrieves data from virtual tables through RFC for ABAP tables and ODP extractors. It also pro­
vides change data capture for ODP extractors.

ASEAdapter Retrieves data from SAP ASE. It can also receive changes that occur to tables in real time. You
can also write back to a virtual table.

AseECCAdapter Retrieves data from an SAP ERP system running on SAP ASE. It can also receive changes that
occur to tables in real time.

BWAdapter This adapter is available for use only with SAP Agile Data Preparation.

CamelAccessAdapter Retrieves data from a Microsoft Access source. The Camel Access adapter is a predelivered
component that is based on the Apache Camel adapter.

CamelFacebookAdapter The Camel Facebook adapter is a predelivered component that is based on the Apache Camel
adapter. Use the Camel Facebook component to connect to and retrieve data from Facebook.

CamelInformixAdapter Retrieves data from an Informix source. It can also write back to an Informix virtual table. The
Camel Informix adapter is a predelivered component that is based on the Camel adapter.

CamelJdbcAdapter The Camel JDBC adapter is a predelivered component that is based on the Apache Camel
adapter.

Use the Camel JDBC adapter to connect to most databases for which SAP HANA smart data
integration doesn’t already provide a predelivered adapter.

In general, the Camel JDBC adapter supports any database that has SQL-based data types and
functions, and a JDBC driver.

CassandraAdapter Retrieves data from an Apache Cassandra remote source. You can also write to an Apache Cas­
sandra target.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 153
Adapter Name Description

CloudDataIntegrationA­ This adapter is available for use only with SAP Data Warehouse Cloud.
dapter

DB2ECCAdapter Retrieves data from an SAP ERP system running on IBM DB2. It can also receive changes that
occur to tables in real time. The only difference between this adapter and the DB2LogReaderA­
dapter is that this adapter uses the data dictionary in the SAP ERP system when browsing met­
adata.

DB2LogReaderAdapter Retrieves data from IBM DB2. It can also receive changes that occur to tables in real time. You
can also write back to a virtual table.

DB2MainframeAdapter Retrieves data from IBM DB2 for z/OS. IBM DB2 iSeries, formerly known as AS/400, is also
supported.

ExcelAdapter Retrieves data from Microsoft Excel.

You can also access SharePoint source data.

FileAdapter Retrieves data from formatted text files. You can also write back to a virtual table.

You can also access SharePoint source data, as well as write to an HDFS target file.

FileAdapterDatastore File datastore adapters use the SAP Data Services engine as the underlying technology to read
from a wide variety of sources.
SFTPAdapterDatastore

HanaAdapter This adapter provides real-time changed-data capture capability in order to replicate data from
a remote SAP HANA database to a target SAP HANA database. You can also write back to a
virtual table. Use this adapter to extract data from an ECC on an SAP HANA source.

HiveAdapter Retrieves data from HADOOP.

ImpalaAdapter Retrieves data from an Apache Impala source. The Apache Impala adapter is a predelivered
component that is based on the Apache Camel adapter.

MssqlECCAdapter Retrieves data from an SAP ERP system running on Microsoft SQL Server. It can also receive
changes that occur to tables in real time. The only difference between this adapter and the
MssqlLogReaderAdapter is that this adapter uses the data dictionary in the SAP ERP system
when browsing metadata.

MssqlLogReaderAdapter Retrieves data from Microsoft SQL Server. It can also receive changes that occur to tables in
real time, be it through log reading or triggers. You can also write back to a virtual table.

ODataAdapter Retrieves data from an OData service. You can also write to an OData target.

OpenConnectorAdapter This adapter is available for use only with SAP Data Warehouse Cloud.

OracleECCAdapter Retrieves data from an SAP ERP system running on Oracle. It can also receive changes that oc­
cur to tables in real time. The only difference between this adapter and the OracleLogReaderA­
dapter is that this adapter uses the data dictionary in the SAP ERP system when browsing met­
adata.

OracleLogReaderAdapter Retrieves data from Oracle. It can also receive changes that occur to tables in real time, be it
through log reading or triggers. You can also write back to a virtual table.

OutlookAdapter Retrieves data from Microsoft Outlook.

PostgreSQLLogReaderA­ Use this adapter to batch-load or replicate change data in real time from a PostgreSQL data­
dapter base to SAP HANA.

Installation and Configuration Guide


154 PUBLIC Configure Data Provisioning Adapters
Adapter Name Description

SDIDB2MainframeLog­ This adapter provides real-time replication functionality for DB2 for z/OS sources.
ReaderAdapter
 Note
This adapter is referred to in the documentation as “SDI DB2 Mainframe” adapter. Also,
this adapter is similar to the “DB2 Mainframe” adapter, in name and functionality. The
main difference between this adapter and the “DB2 Mainframe” adapter is that the “SDI
DB2 Mainframe” adapter supports real-time replication.

SoapAdapter This adapter is a SOAP web services client that can talk to a web service using the HTTP proto­
col to download the data. The SOAP adapter uses virtual functions instead of virtual tables to
expose server-side operations as it closely relates to how the operation is invoked.

TeradataAdapter Retrieves data from Teradata. It can also receive changes that occur to tables in real time. You
can also write back to a virtual table.

TwitterAdapter Retrieves data from Twitter. It can also receive new data from Twitter in real time.

 Note

Data provisioning adapters allow specifying virtual IP addresses for source systems as a parameter for the
remote source, and they allow changing the virtual IP addresses when the remote source is suspended.

Strong Encryption for Security and Authentication

If you’re using either TSL/SSL or Kerberos, and you require stronger encryption than 128-bit key length, you
must update the existing JCE policy files.

Related Information

Configure Adapter Preferences [page 156]


Custom Adapters [page 157]
Apache Camel Facebook [page 158]
Apache Camel Informix [page 160]
Apache Camel JDBC [page 163]
Apache Camel Microsoft Access [page 169]
Apache Cassandra [page 172]
Apache Impala [page 181]
File [page 187]
File Datastore Adapters [page 222]
Hive [page 244]
IBM DB2 Log Reader [page 254]
IBM DB2 Mainframe [page 283]
Microsoft Excel [page 288]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 155
Microsoft Outlook [page 299]
Microsoft SQL Server Log Reader [page 301]
OData [page 344]
Oracle Log Reader [page 349]
PostgreSQL Log Reader [page 396]
SAP ABAP [page 405]
SAP ASE [page 419]
SAP ECC [page 424]
SAP HANA [page 442]
SDI DB2 Mainframe [page 460]
SOAP [page 478]
Teradata [page 481]
Twitter [page 491]
Modeling Guide for SAP HANA Smart Data Integration and SAP HANA Smart Data Quality
Adapter Functionality
Update JCE Policy Files for Stronger Encryption [page 518]
Data Provisioning Adapter SDK Guide
SAP HANA Smart Data Integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Register Data Provisioning Adapters [page 111]

6.1 Configure Adapter Preferences

Use the configAdapters function of the Data Provisioning Agent configuration tool to adjust adapter settings
specific to your sources.

Procedure

1. At the command line, navigate to <DPAgent_root>/bin.


2. Start the configuration tool with the configAdapters parameter.

○ On Windows, agentcli.bat --configAdapters


○ On Linux, ./agentcli.sh --configAdapters
3. Select 2 to enter the Set Adapter Preferences menu.

 Note

Select 1 if you want to display the current preferences instead of changing the configured values.

4. Select the entry for the adapter that you want to configure.
5. Specify values for the preferences for your adapter.

Installation and Configuration Guide


156 PUBLIC Configure Data Provisioning Adapters
6.1.1 Configure Adapter Preferences in Discrete Command
Mode

Use the configAdapters function of the Data Provisioning Agent configuration tool to adjust adapter settings
specific to your sources.

Configure one or more adapter preferences by specifying the adapter configuration function and the adapter
preferences as additional function parameters.

For example, to configure adapter preferences for the File Adapter:

./agentcli.sh --configAdapters --function setFileAdapter -


DAdapterHashedToken.password=<password_file>

./agentcli.sh --configAdapters --function setFileAdapter -


DUI.config.rootdir=<root_directory> -
DUI.config.fileformatdir=<file_format_directory> -
DAdapterHashedToken.password=<password_file>

 Note

For security, you must use a password file to set passwords in discrete command mode. Save the password
in a file and specify the location of the file as the value for the password preference.

Available Adapter Functions and Preferences

● To display a list of available adapter configuration functions, use the help function.

./agentcli.sh --configAdapters --help

The configuration tool displays the configuration function for each available adapter.
● To display a list of available preferences for an adapter, specify the adapter function name with the help
parameter.

./agentcli.sh --configAdapters --function <adapter_function> --help

The configuration tool displays the available configuration preferences, prerequisites, and a configuration
example for the specified adapter.

6.2 Custom Adapters

Use the Adapter SDK to create your own custom adapters.

The adapters described in this document that come installed with the Data Provisioning Agent were created
using the Adapter SDK.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 157
You can use the Adapter SDK to create your own custom adapters to connect to virtually any source. An
administrator then registers the custom adapter on the appropriate agent.

Related Information

Data Provisioning Adapter SDK Guide


Register Data Provisioning Adapters [page 111]

6.3 Apache Camel Facebook

Overview of this SAP HANA Smart Data Integration adapter’s features and functionality

The Apache Camel Facebook adapter is created based on Camel Adapter. The adapter uses the Facebook
component (http://camel.apache.org/facebook.html) to access Facebook APIs. Facebook data of the
configured Facebook user such as friends, families, and movies, are exposed to SAP HANA server by virtual
tables by the Camel Facebook Adapter.

This adapter supports the following functionality:

● Virtual table as a source


● CAP_SELECT

Related Information

Set up the Camel Facebook Adapter [page 158]


Camel Facebook Adapter Remote Source Configuration [page 159]

6.3.1 Set up the Camel Facebook Adapter

By default, Camel Facebook Adapter is not available in Data Provisioning Agent. To use it, you must perform
setup tasks.

Procedure

1. Open <DPAgent_root>/camel/adapters.xml and uncomment the configuration of Camel Facebook


Adapter.

<Adapter type="CamelFacebookAdapter" displayName="Camel Facebook Adapter">

Installation and Configuration Guide


158 PUBLIC Configure Data Provisioning Adapters
<RemoteSourceDescription>
<PropertyGroup name="configuration" displayName="Configuration"/>
<CredentialEntry name="app_credential" displayName="App Credential"
userDisplayName="App ID" passwordDisplayName="App Secret"/>
<CredentialEntry name="user_credential" displayName="User Credential"
userDisplayName="User ID" passwordDisplayName="User Access Token"/>
</RemoteSourceDescription>
<Capabilities>
CAP_SELECT,
CAP_WHERE,
CAP_SIMPLE_EXPR_IN_WHERE,
CAP_EXPR_IN_WHERE,
CAP_NESTED_FUNC_IN_WHERE,
CAP_METADATA_DICTIONARY,
CAP_METADATA_ATTRIBUTE
</Capabilities>
<RouteTemplate>facebook.xml</RouteTemplate>
</Adapter>

2. Download the Facebook Component JAR file, which is located in the Apache Camel ZIP file, and put it in the
<DPAgent_root>/camel/lib directory.
3. Download Facebook4J, and put it in the <DPAgent_root>/camel/lib directory.

 Note

See the SAP HANA Smart Data Integration Product Availability Matrix for information about version
compatibility with these downloads.

Related Information

Product Availability Matrix


Facebook4J
Apache Camel downloads

6.3.2 Camel Facebook Adapter Remote Source Configuration

Configuration settings for accessing a Camel Facebook source. Also included is sample code for creating a
remote source using the SQL console.

The Camel Facebook adapter has the following remote source configuration parameters. You use all of these
parameters to configure Facebook component options; See <DPAgent_root>/camel/facebook.xml. If you
need to specify non-default values for Facebook component options, you can add more remote source
parameters in the adapter configuration in adapters.xml, and update the Facebook component bean in
<DPAgent_root>/camel/facebook.xml accordingly. See http://camel.apache.org/facebook.html for a
complete list of these options.

Facebook requires the use of OAuth for all client application authentication. To use the Camel Facebook
adapter with your account, you need to create a new application within Facebook at https://
developers.facebook.com/apps and grant the application access to your account. The Facebook
application's ID and secret allow access to Facebook APIs that do not require a current user. A user access

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 159
token is required for APIs that require a logged in user. You can find more information about obtaining a user
access token at https://developers.facebook.com/docs/facebook-login/access-tokens/ .

Category Option Description

App Credential App ID Facebook application ID

App Secret Facebook application Secret

User Credential User ID Facebook user ID

User Access Token The user access token.

Example

 Sample Code

CREATE REMOTE SOURCE "MyFacebookSource" ADAPTER "CamelFacebookAdapter" AT


LOCATION AGENT "MyAgent" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configuration">
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="app_credential">
<user>myappuserid</user>
<password>myappusertoken</password>
</CredentialEntry>
<CredentialEntry name="user_credential">
<user>myuserid</user>
<password>myusertoken</password>
</CredentialEntry>';

Related Information

Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.4 Apache Camel Informix

Use the Camel Informix adapter to connect to an IBM Informix remote source.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

This adapter supports using a virtual table as a source.

Installation and Configuration Guide


160 PUBLIC Configure Data Provisioning Adapters
Related Information

Set Up the Camel Informix Adapter [page 161]


Camel Informix Remote Source Configuration [page 162]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.4.1 Set Up the Camel Informix Adapter

By default, Camel Informix Adapter is not available in Data Provisioning Agent. To use it, you must perform
setup tasks.

Procedure

1. Open <DPAgent_root>/camel/adapters.xml and uncomment the configuration of Camel Informix


Adapter.

<Adapter type="CamelDatabaseAdapter" displayName="Camel database Adapter">


<RemoteSourceDescription>
<PropertyGroup name="configuration" displayName="Configuration">
<PropertyEntry name="host" displayName="Host"
description="Host name" isRequired="true"/>
<PropertyEntry name="port" displayName="Port"
description="Port number" isRequired="true"/>
<PropertyEntry name="dbname" displayName="Database"
description="Database Name" isRequired="true"/>
<PropertyEntry name="servername" displayName="Server Name"
description="Server Name" isRequired="false"/>
<PropertyEntry name="delimident" displayName="delimident"
description="delimident" isRequired="false"/>
</PropertyGroup>
<CredentialEntry name="db_credential" displayName="Credential"
userDisplayName="user" passwordDisplayName="password"/>
</RemoteSourceDescription>
<Capabilities>
<Informix List of Capabilities>
</Capabilities>
<RouteTemplate>jdbc.xml</RouteTemplate>
</Adapter>

2. Copy <DPAgent_root>/camel/samples/sample-jdbc.xml to <DPAgent_root>/camel/ and


rename to jdbc.xml.
3. Download camel-jdbc.jar from http://camel.apache.org/download.html , and copy it to the
<DPAgent_root>/camel/lib directory.
4. Download the Informix jdbc driver ifxjdbc.jar , and put it in the <DPAgent_root>/camel/lib
directory.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 161
6.4.2 Camel Informix Remote Source Configuration

Configure the following options in SAP HANA smart data access to configure your connection to an Informix
remote source. Also included is sample code for creating a remote source using the SQL console.

Category Option Description

Configuration Host Host name

Port Port number

Database Name Database name

Server Name Server name

Delimident If set to True, the Informix database object name is enclosed with
double quotation marks.

Configuration > Secur­ Use Agent Stored Creden­ Set to True to use credentials that are stored in the DP Agent secure
ity tial
storage.

The default value is False.

Credentials Credentials Mode Technical user or Secondary user

Select one of the choices depending on the purpose of the remote


source you want to create.

User Credential User The Informix user name

Password The Informix user name's password

Example

 Sample Code

CREATE REMOTE SOURCE "MyInformixSource" ADAPTER "CamelInformixAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="generic" displayName="Generic">
<PropertyEntry name="instance_name" displayName="Instance Name"
isRequired="true">MyInformixSource</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="host" displayName="Host"
isRequired="true">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="port" displayName="Port Number" isRequired="true">32566</
PropertyEntry>
<PropertyEntry name="dbname" displayName="Database Name"
isRequired="true">mydb</PropertyEntry>
<PropertyEntry name="servername" displayName="Server name"
isRequired="true">myserver</PropertyEntry>

Installation and Configuration Guide


162 PUBLIC Configure Data Provisioning Adapters
<PropertyEntry name="delimident" displayName="delimident"
isRequired="true">true</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="db_credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.5 Apache Camel JDBC

Use the Camel JDBC adapter to connect to most databases for which SAP HANA smart data integration does
not already provide a pre-delivered adapter.

In general, the Camel JDBC adapter supports any database that has SQL-based data types and functions, and
a JDBC driver.

If you are using MS Access or IBM Informix, use the Camel adapters specific to those databases.

Adapter Functionality

This adapter supports the following functionality:

● SELECT, INSERT, UPDATE, and DELETE


● Virtual table as a source
● Virtual table as a target using a Data Sink node in a flowgraph

Related Information

Set up the Camel JDBC Adapter [page 164]


Camel JDBC Remote Source Configuration [page 166]
Connect to MySQL Using the Camel JDBC Adapter [page 168]
Disable Adapter Write-back Functionality [page 168]
Apache Camel Microsoft Access [page 169]
Apache Camel Informix [page 160]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 163
6.5.1 Set up the Camel JDBC Adapter

By default, Camel JDBC Adapter is not available in Data Provisioning Agent. To use it, you must perform setup
tasks.

Procedure

1. Open <DPAgent_root>/camel/adapters.xml and uncomment the configuration of Camel JDBC


Adapter.

<Adapter type="CamelJdbcAdapter" displayName="Camel Jdbc Adapter">


<RemoteSourceDescription>
<PropertyGroup name="configuration" displayName="Configuration">
<PropertyEntry name="dbtype" displayName="Database Type"
description="Database Type" defaultValue="other" isRequired="true">
<Choices>
<Choice name="access" displayName="Access"/>
<Choice name="informix" displayName="Informix"/>
<Choice name="other" displayName="Other"/>
</Choices>
</PropertyEntry>
<PropertyEntry name="filepath" displayName="Access file path"
description="Access file path" isRequired="false">
<Dependencies>
<Dependency name="dbtype" value="access"/>
</Dependencies>
</PropertyEntry>
<PropertyEntry name="filename" displayName="Access file name"
description="Access file name" isRequired="false">
<Dependencies>
<Dependency name="dbtype" value="access"/>
</Dependencies>
</PropertyEntry>
<PropertyEntry name="host" displayName="Host"
description="Host name" isRequired="false"/>
<PropertyEntry name="port" displayName="Port"
description="Port number" isRequired="false"/>
<PropertyEntry name="dbname" displayName="Database"
description="Database Name" isRequired="false"/>
<PropertyEntry name="servername" displayName="Server Name"
description="Server Name" isRequired="false"/>
<PropertyEntry name="delimident" displayName="delimident"
description="delimident" defaultValue="false" isRequired="false"/>
<Choices>
<Choice name="true" displayName="True"/>
<Choice name="false" displayName="False"/>
</Choices>
<PropertyEntry name="driverClass" displayName="JDBC Driver
Class" description="JDBC Driver Class" isRequired="false"/>
<PropertyEntry name="url" displayName="JDBC URL"
description="JDBC URL" isRequired="false"/>
</PropertyGroup>
<CredentialEntry name="db_credential" displayName="Credential"
userDisplayName="user" passwordDisplayName="password"/>
</RemoteSourceDescription>
<Capabilities>
CAP_AND_DIFFERENT_COLUMNS,
CAP_TRUNCATE_TABLE,
CAP_LIKE,
CAP_IN,
CAP_AND,

Installation and Configuration Guide


164 PUBLIC Configure Data Provisioning Adapters
CAP_OR,
CAP_DISTINCT,
CAP_HAVING,
CAP_ORDERBY,
CAP_ORDERBY_EXPRESSIONS,
CAP_GROUPBY,
CAP_SELECT,
CAP_INSERT,
CAP_UPDATE,
CAP_DELETE,
CAP_EXCEPT,
CAP_INTERSECT,
CAP_AGGREGATES,
CAP_AGGREGATE_COLNAME,
CAP_DIST_AGGREGATES,
CAP_INSERT_SELECT,
CAP_JOINS,
CAP_JOINS_OUTER,
CAP_BI_SUBSTRING,
CAP_BI_NOW,
CAP_BI_UPPER,
CAP_BI_LOWER,
CAP_BI_LCASE,
CAP_BI_UCASE,
CAP_BI_CONCAT,
CAP_BI_LTRIM,
CAP_BI_RTRIM,
CAP_BI_TRIM,
CAP_WHERE,
CAP_SIMPLE_EXPR_IN_PROJ,
CAP_EXPR_IN_PROJ,
CAP_NESTED_FUNC_IN_PROJ,
CAP_SIMPLE_EXPR_IN_WHERE,
CAP_EXPR_IN_WHERE,
CAP_NESTED_FUNC_IN_WHERE,
CAP_SIMPLE_EXPR_IN_INNER_JOIN,
CAP_EXPR_IN_INNER_JOIN,
CAP_NESTED_FUNC_IN_INNER_JOIN,
CAP_SIMPLE_EXPR_IN_LEFT_OUTER_JOIN,
CAP_EXPR_IN_LEFT_OUTER_JOIN,
CAP_NESTED_FUNC_IN_LEFT_OUTER_JOIN,
CAP_SIMPLE_EXPR_IN_ORDERBY,
CAP_EXPR_IN_ORDERBY,
CAP_NESTED_FUNC_IN_ORDERBY,
CAP_NONEQUAL_COMPARISON,
CAP_OR_DIFFERENT_COLUMNS,
CAP_PROJECT,
CAP_BI_SECOND,,
CAP_BI_MINUTE,
CAP_BI_HOUR,
CAP_BI_MONTH,
CAP_BI_YEAR,
CAP_BI_COT,
CAP_BI_ABS,
CAP_BI_ACOS,
CAP_BI_ASIN,
CAP_BI_ATAN,
CAP_BI_ATAN2,
CAP_BI_CEILING,
CAP_BI_COS,
CAP_BI_EXP,
CAP_BI_FLOOR,
CAP_BI_LN,
CAP_BI_CEIL,
CAP_BI_LOG,
CAP_BI_MOD,
CAP_BI_POWER,
CAP_BI_SIGN,

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 165
CAP_BI_SIN,
CAP_BI_SQRT,
CAP_BI_TAN,
CAP_BI_ROUND,
CAP_BI_ASCII,
CAP_BI_RIGHT,
CAP_BI_LEFT,
CAP_BI_TO_BIGINT,
CAP_BI_TO_DECIMAL,
CAP_BI_TO_DOUBLE,
CAP_BI_TO_REAL,
CAP_BI_TO_SMALLINT,
CAP_BI_TO_INT,
CAP_BI_TO_INTEGER
CAP_BI_COALESCE,
CAP_BI_IFNULL,
CAP_BI_NULLIF,
CAP_BIGINT_BIND
</Capabilities>
<RouteTemplate>jdbc-general.xml</RouteTemplate>
</Adapter>
</Adapters>

2. Download the appropriate JDBC file, and copy it to the <DPAgent_root>/camel/lib directory.

6.5.2 Camel JDBC Remote Source Configuration

Configure the following options to create a connection to a remote database. Also included is sample code for
creating a remote source using the SQL console.

Category Option Description

Configuration Database Type Specifies the type of database to which you will connect.

JDBC Driver Class Specifies the JDBC driver class for the database you are us­
ing.

JDBC URL Specifies the URL for the JDBC driver.

Configuration > Security Use Agent Stored Credential Set to True to use credentials that are stored in the Data Pro­
visioning Agent secure storage.

The default value is False.

Credentials Credentials Mode Remote sources support two types of credential modes to
access a remote source: technical user and secondary cre­
dentials.

● Technical User: A valid user and password in the remote


database. This valid user is used by anyone using the re­
mote source.
● Secondary User: A unique access credential on the re­
mote source assigned to a specific user.

User Credentials Database user name Specifies the database user name.

Database user password Specifies the password for the database user.

Installation and Configuration Guide


166 PUBLIC Configure Data Provisioning Adapters
Example SQL Configuration for Netezza

CREATE REMOTE SOURCE "MyNetezzaSource" ADAPTER "CamelJdbcAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configuration">
<PropertyEntry name="dbtype" displayName="Database Type"
isRequired="true">netezza</PropertyEntry>
<PropertyEntry name="driverClass" displayName="JDBC Driver Class"
isRequired="false">org.netezza.Driver</PropertyEntry>
<PropertyEntry name="url" displayName="JDBC URL"
isRequired="false">jdbc:netezza://<host name>:<port number>/<database name></
PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="db_credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry

Example SQL Configuration for Vertica

CREATE REMOTE SOURCE "MyVerticaSource" ADAPTER "CamelJdbcAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configuration">
<PropertyEntry name="dbtype" displayName="Database Type"
isRequired="true">vertica</PropertyEntry>
<PropertyEntry name="driverClass" displayName="JDBC Driver Class"
isRequired="false">com.vertica.jdbc.Driver</PropertyEntry>
<PropertyEntry name="url" displayName="JDBC URL"
isRequired="false">jdbc:vertica://<host name>:<port number>/<database name></
PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="db_credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry

Related Information

Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 167
6.5.3 Connect to MySQL Using the Camel JDBC Adapter

You can connect to MySQL using the Camel JDBC adapter.

Procedure

1. To allow MySQL to treat double quotes (") as an identifier quote character, append the property string ?
sessionVariables=sql_mode=ANSI_QUOTES to the JDBC URL parameter in the remote source
configuration.
2. Download and place the mysql-connector-java-<version>-bin.jar file under <DPAgent_root>/
camel/lib folder. If there is no /lib folder, create one.
3. Restart the Data Provisioning Agent.

Related Information

SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Camel JDBC Remote Source Configuration [page 166]

6.5.4 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

Installation and Configuration Guide


168 PUBLIC Configure Data Provisioning Adapters
For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.6 Apache Camel Microsoft Access

Read Microsoft Access data.

The Apache Camel Microsoft Access adapter is created based on Camel Adapter. Using the adapter, you can
access Microsoft Access database data via virtual tables.

 Note

The Camel Access adapter can be used only when the Data Provisioning Agent is installed on Microsoft
Windows.

This adapter supports the following functionality:

● Virtual table as a source

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 169
Related Information

Set Up the Camel Microsoft Access Adapter [page 170]


Microsoft Access Remote Source Configuration [page 170]

6.6.1 Set Up the Camel Microsoft Access Adapter

Set up the Camel Microsoft Access adapter.

Context

By default, Camel Microsoft Access adapter is not available in Data Provisioning Agent. To use it, you must do
the following:

Procedure

1. In Microsoft Access, in the Tables window, right-click MSysObjects, and select Navigation Options to show
system objects.
2. In the Info window of Microsoft Access, right-click the Users and Permissions button, and select User and
Group Permissions to give an admin user all permissions on MSysObjects.
3. Enable macros in the Microsoft Access Trust Center.
4. Run the following command:

Sub currentuser()
strDdl = "GRANT SELECT ON MSysObjects TO Admin;"
CurrentProject.Connection.Execute strDdl
End Sub

5. Open <DPAgent_root>/camel/adapters.xml and uncomment the configuration of


CamelAccessAdapter.
Uncomment the following:

<Adapter type="CamelAccessAdapter" displayName="Camel access Adapter">


...
</Adapter>

6.6.2 Microsoft Access Remote Source Configuration

Configure the following options in smart data access to configure your connection to a Microsoft Access
remote source. Also included is sample code for creating a remote source using the SQL console.

Installation and Configuration Guide


170 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Configuration Access File Path Specifies the path to the Microsoft Access database file.

Access File Name Specifies the name of the Microsoft Access database file.

Configuration > Se­ Use Agent Stored Creden­ Set to True to use credentials that are stored in the DP Agent secure
curity tial
storage.

The default value is False.

Credentials Credentials Mode Technical user or Secondary user

Select one of the choices depending on the purpose of the remote


source you want to create.

User The user name for the Microsoft Access account.

Password The password for the Microsoft Access account.

Example

 Sample Code

CREATE REMOTE SOURCE "MyAccessSource" ADAPTER "CamelAccessAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="table" displayName="table">
<PropertyEntry name="filepath" displayName="Access file path">C:/access_data</
PropertyEntry>
<PropertyEntry name="filename" displayName="Access file name">database1.mdb</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="db_credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 171
6.7 Apache Cassandra

Apache Cassandra is a free and open-source distributed NoSQL database management system designed to
handle large amounts of data across many commodity servers, providing high availability with no single point of
failure.

The Cassandra adapter is specially designed for accessing and manipulating data from Cassandra Database.

 Note

The minimum supported version of Apache Cassandra is 1.2.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● Virtual table as a target using a Data Sink node in a flowgraph
● Kerberos authentication
● SSL support

In addition, this adapter supports the following capabilities:

● SELECT, INSERT, DELETE, UPDATE, WHERE, DISTINCT, LIMIT, ORDERBY

Related Information

Cassandra SSL Configuration [page 172]


Enable Kerberos Authentication [page 175]
Cassandra Remote Source Configuration [page 177]
Disable Adapter Write-back Functionality [page 180]
SAP HANA Smart Data Integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.7.1 Cassandra SSL Configuration

Configure SSL for connecting to your Cassandra remote source.

To enable SSL, on Cassandra you must import the server certificates and enable client authentication.

Installation and Configuration Guide


172 PUBLIC Configure Data Provisioning Adapters
Related Information

Enable SSL on Cassandra [page 173]


Enable Client Authentication [page 174]
Update JCE Policy Files for Stronger Encryption [page 518]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Connect to SAP HANA On-Premise with SSL [page 512]

6.7.1.1 Enable SSL on Cassandra

You must enable SSL on your Cassandra remote source before you can connect to it.

Procedure

1. Prepare the server certificates.


2. Edit the cassandra.yaml file as follows:

client_encryption_options:
enabled: true
optional: false
keystore: .keystore
keystore_password: Sybase123
require_client_auth: false
truststore: .truststore
truststore_password: Sybase123
# More advanced defaults below:
protocol: ssl
store_type: JKS
cipher_suites: [TLS_RSA_WITH_AES_128_CBC_SHA,
TLS_RSA_WITH_AES_256_CBC_SHA]

3. Export the certificates from all Cassandra nodes and copy them to the Data Provisioning Agent host.

keytool -export -alias dse_node0 -file dse_node0.cer -keystore .keystore

4. Import the certificates into the Data Provisioning Agent truststore.

$ keytool -import -v -trustcacerts -alias dse_node0 -file dse_node0.cer -


keystore <installation_path>/ssl/cacerts
$ keytool -import -v -trustcacerts -alias dse_node1 -file dse_node1.cer -
keystore <installation_path>/ssl/cacerts

5. Restart Cassandra.
6. In the SAP HANA smart data integration Cassandra remote source configuration options, set Use SSL to
True, and set Use Client Authentication as desired.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 173
Related Information

Cassandra Remote Source Configuration [page 177]


Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]

6.7.1.2 Enable Client Authentication

Enable client authentication when you are using SSL.

Context

To enable client authentication, you must edit a Cassandra file and properly configure your remote source.

Procedure

1. Edit the cassandra.yaml file.

client_encryption_options:
enabled: true
optional: false
keystore: .keystore
keystore_password: Sybase123
require_client_auth: true
truststore: .truststore
truststore_password: Sybase123
# More advanced defaults below:
protocol: ssl
store_type: JKS
cipher_suites: [TLS_RSA_WITH_AES_128_CBC_SHA,
TLS_RSA_WITH_AES_256_CBC_SHA]
# More advanced defaults below:
protocol: ssl
store_type: JKS
cipher_suites: [TLS_RSA_WITH_AES_128_CBC_SHA,
TLS_RSA_WITH_AES_256_CBC_SHA]

2. Generate the private and public key pair for the Data Provisioning Agent node.

keytool -genkey -alias dpagent -keyalg RSA -keystore cacerts

Leave the key password the same as the keystore password, and export the public key.

keytool -export -alias dpagent -file dpagent.cer -keystore cacerts

3. Copy the dpagent.cer file to each Cassandra node, and import it into the Cassandra truststore.

keytool -import -v -trustcacerts -alias dpagent -file dpagent.cer -


keystore .truststore

Installation and Configuration Guide


174 PUBLIC Configure Data Provisioning Adapters
4. Restart Cassandra.
5. Enable client authentication when creating a remote source by setting the Use Client Authentication
parameter to True.

Related Information

Cassandra Remote Source Configuration [page 177]

6.7.2 Enable Kerberos Authentication

The Cassandra adapter by default allows user name and password authentication. However, you can improve
security by enabling Kerberos authentication.

Procedure

1. On each node, confirm DNS is working:

$ hostname
node1.example.com

2. On each node, confirm that NTP is configured and running:

$ ntpq -p
remote refid st t when poll reach delay offset
jitter
==============================================================================
*li506-17.member 209.51.161.238 2 u 331 1024 377 80.289 1.384 1.842
-tock.eoni.com 216.228.192.69 2 u 410 1024 377 53.812 1.706 34.692
+time01.muskegon 64.113.32.5 2 u 402 1024 377 59.378 -1.635 1.840
-time-a.nist.gov .ACTS. 1 u 746 1024 151 132.832 26.931 55.018
+golem.canonical 131.188.3.220 2 u 994 1024 377 144.080 -1.732 20.072

3. Install the Kerberos client software.

RHEL-based systems

$ sudo yum install krb5-workstation krb5-libs krb5-pkinit-openssl

Debian-based systems

$ sudo apt-get install krb5-user krb5-config krb5-pkinit

SUSE systems

$ sudo zypper install krb5-client

4. Edit the /etc/krb5.conf file to add the KDC domain configuration.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 175
5. Create a user for the client.

cassandra@cqlsh:dp_test> create user 'cass@EXAMPLE.COM' with password


'Sybase123' superuser;

6. Prepare the keytab for each Cassandra node.

addprinc -randkey cassandra/node1.example.com


addprinc -randkey HTTP/node1.example.com
addprinc -randkey cassandra/node2.example.com
addprinc -randkey HTTP/node2.example.com

ktadd -k dse.keytab cassandra/FQDN
ktadd -k dse.keytab HTTP/FQDN

7. Copy keytabs to the related Cassandra nodes, and edit the dse.yaml file.

kerberos_options:
keytab: resources/dse/conf/dse.keytab
service_principal: cassandra/_HOST@EXAMPLE.COM
http_principal: HTTP/_HOST@EXAMPLE.COM
qop: auth

8. Edit the cassandra.yaml file.

authenticator: com.datastax.bdp.cassandra.auth.KerberosAuthenticator

9. Restart Cassandra.
10. Prepare the keytab for the DP Agent. The principal must have the value of the user created previously in
this procedure.

addprinc -randkey cass@EXAMPLE.COM


ktadd -k dpagent.keytab cass@EXAMPLE.COM

11. Copy the dpagent.keytab file to the DP Agent host, and create your remote source.

Related Information

Cassandra Remote Source Configuration [page 177]


Update JCE Policy Files for Stronger Encryption [page 518]

Installation and Configuration Guide


176 PUBLIC Configure Data Provisioning Adapters
6.7.3 Cassandra Remote Source Configuration

Configure the following options for a connection to an Apache Cassandra remote source. Also included is
sample code for creating a remote source using the SQL console.

Category Option Description

Connection Hosts The list of host names and ports Cassandra used to connect to
the Cassandra cluster.

The hosts and ports should be provided in the following format:

host1[:port1]
[,host2[:port2],host3[:port3]...]

If the port number is not provided for a host, the default port
9042 will be used for the host.

Only one host is needed to discover the cluster topology, but it is


usually a good idea to provide more so the driver can revert if the
first one is down.

Authentication Mechanism User Name and Password (Default): Use user name and pass­
word to perform the authentication.

Kerberos: Use Kerberos to perform the authentication.

Paging Status Specify whether to enable paging when getting the results of a
query from Cassandra. The default value is On.

Read Timeout (milliseconds) Specify the number of milliseconds the driver waits for a re­
sponse from a given Cassandra node, before considering it unre­
sponsive.

Connect Timeout (milliseconds) Specify the number of milliseconds the driver waits to establish a
new connection to a Cassandra node before giving up.

Data Type Conver­ Map TEXT/VARCHAR to Cassandra data types TEXT and VARCHAR are mapped to
sion NVARCHAR (5000) NCLOB in HANA, which makes it impossible to use these col­
umns as query conditions in a WHERE clause. Set the value to
True to map to NVARCHAR instead. The default value is False.

Map ASCII to VARCHAR (5000) The Cassandra data type ASCII is mapped to CLOB in HANA,
which makes it impossible to use these columns as query condi­
tions in a WHERE clause. Set the value to True to map to VAR­
CHAR instead. The default value is False.

Load Balancing Pol­ Use Round Robin Policy Specify whether to use the Round Robin Policy. The default value
icy is False.

You can use either Round Robin Policy or DC Aware Round Robin
Policy, but not both.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 177
Category Option Description

Use DC Aware Round Robin Pol­ Specify whether to use the DC Aware Round Robin Policy. The
icy default value is False.

You can use either DC Aware Round Robin Policy or DC Aware


Round Robin Policy, but not both.

Use Token Aware Policy Specify whether to use the Token Aware Policy. The default value
is False.

Either Round Robin Policy or DC Aware Round Robin Policy must


be used as your child policy if this parameter is set to True.

Use Latency Aware Policy Specify whether to use the Latency Aware Policy. The default
value is False.

Either Round Robin Policy or DC Aware Round Robin Policy must


be used as your child policy if this parameter is set to True.

Security Use SSL Specify whether to connect to Cassandra using SSL. The default
value is False.

Use Client Authentication Specify whether to connect to Cassandra using client authenti­
cation. The default value is False.

This parameter works only if Use SSL is set to True.

Use Agent Stored Credential Set to True to use credentials that are stored in the DP Agent se­
cure storage.

Kerberos Realm Optional when using Kerberos. Authenticate using a principal


from this realm instead of the systems default realm. The Realm
option must be used together with the Key Distribution Center
(KDC).

KDC Optional when using Kerberos. The address of the KDC to be


used with the specified Realm, which has to be used together
with Realm.

Service Name The SASL protocol name to use, which should match the user
name of the Kerberos service principal used by the DSE server.

Use Keytab Set this to True if you want the module to get the technical user's
key from the keytab. The default value is False.

If Key Tab is not set, then the module locates the keytab from the
Kerberos configuration file. If it is not specified in the Kerberos
configuration file, then the module looks for the file
<user.home><file.separator>krb5.keytab.

Keytab Set this to the file name of the keytab to get the technical user's
secret key.

Installation and Configuration Guide


178 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Use Ticket Cache Set this to true if you want the ticket-granting ticket (TGT) to be
obtained from the ticket cache. Set this option to False if you do
not want this module to use the ticket cache. The default value is
False.

This module searches for the ticket cache in the following loca­
tions:

● On Solaris and Linux, in /tmp/krb5cc_<uid>, where the


uid is a numeric user identifier.
● If the ticket cache is not available in /tmp/
krb5cc_<uid>, or if you are on a Windows platform, the
module looks for the cache as
<user.home><file.separator>krb5cc_<user.
name>. You can override the ticket cache location by using
the Ticket Cache parameter.
● For Windows, if a ticket cannot be retrieved from the file
ticket cache, the module uses Local Security Authority
(LSA) API to get the TGT.

Ticket Cache Set this to the name of the ticket cache that contains the user's
TGT. If this is set, Use Ticket Cache must also be set to true; oth­
erwise, a configuration error is returned.

Credentials Credentials Mode Select Technical user or Secondary user depending on the pur­
pose of the remote source you want to create.

User The user used to connect to Cassandra database. If Kerberos is


used, the user should be the client principal and also a Cassan­
dra user.

Password The password of the Cassandra user.

SQL

CREATE REMOTE SOURCE "cassandra_rs" ADAPTER "CassandraAdapter" AT LOCATION AGENT


"CassandraAgent" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="connection" displayName="Connection">
<PropertyEntry name="hosts" displayName="Host names and
ports">oakl00548161a.amer.global.corp.sap</PropertyEntry>
<PropertyEntry name="auth_mech" displayName="Authentication
Mechanism">user_password</PropertyEntry>
<PropertyEntry name="paging_status" displayName="Paging Status">true</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="load_balancing_policy" displayName="Load Balancing
Policy">

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 179
<PropertyEntry name="use_rr_policy" displayName="Use Round Robin
Policy">false</PropertyEntry>
<PropertyEntry name="use_dc_aware_rr_policy" displayName="Use DC Aware
Round Robin Policy">false</PropertyEntry>
<PropertyEntry name="shuffle_replicas" displayName="Shuffle
Replicas">true</PropertyEntry>
<PropertyEntry name="use_latency_aware_policy" displayName="Use Latency
Aware Policy">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security">
<PropertyEntry name="use_ssl" displayName="Use SSL">false</PropertyEntry>
<PropertyEntry name="use_client_auth">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="kerberos" displayName="Kerberos">
<PropertyEntry name="krb_realm" displayName="Realm"
allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_kdc" displayName="KDC"
allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_protocol" displayName="Protocol"
allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_use_keytab" displayName="Use Key Tab"
allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_keytab" displayName="Key Tab" description="Key
Tab" allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_use_ticket_cache" displayName="Use Ticket
Cache" allowAlterWhenSuspended="true"></PropertyEntry>
<PropertyEntry name="krb_ticket_cache" displayName="Ticket Cache"
allowAlterWhenSuspended="true"></PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>cassandra</user>
<password>cassandra</password >
</CredentialEntry>';

Related Information

Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Enable SSL on Cassandra [page 173]
Enable Client Authentication [page 174]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.7.4 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Installation and Configuration Guide


180 PUBLIC Configure Data Provisioning Adapters
Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.8 Apache Impala

The Apache Impala adapter is a data provisioning adapter that is used to access Apache Impala tables.

An Impala table can be internal table, external table, or partition table. Impala tables could be stored as data
files with various file formats. Also, they can be Kudu tables stored by Apache Kudu. Different table types have

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 181
different sets of operations to support. For example, tables stored as data files do not support UPDATE and
DELETE SQL, as well as PRIMARY KEY. However, Kudu tables support them.

An Impala table type is transparent to the Impala adapter. The Impala adapter supports all of these types of
tables and cares about column metadata only. The Impala adapter supports operations that are legal to the
back end Impala table.

Required JDBC Drivers

The Impala adapter requires you to install the Impala JDBC connector in DPAgent. Follow the steps below to
install the Impala JDBC connector:

1. Download the latest Impala JDBC connector from https://www.cloudera.com/downloads/connectors/


impala/jdbc.html .
2. From that ZIP file, unzip Cloudera_ImpalaJDBC41_<version_number>.zip , and put all jar files into
the <DPAgent_root>/lib/impala directory. Create the directory if it does not exist.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● SELECT, WHERE, JOIN, DISTINCT, TOP, LIMIT, ORDER BY, GROUP BY

Related Information

Apache Impala Remote Source Configuration [page 182]


Kerberos Realm and KDC [page 186]
Update JCE Policy Files for Stronger Encryption [page 518]

6.8.1 Apache Impala Remote Source Configuration

Configure the following options for a connection to an Apache Impala remote source. Also included is sample
code for creating a remote source using the SQL console.

Category Option Description

Connection Host Impala host name or IP address.

Impala server port. Default value is 21050.

Installation and Configuration Guide


182 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Authentication mechanism that is used to connect to the Im­


pala Server. Choose from the following values:

● No Authentication (0 in SQL)
● Kerberos (1 in SQL)
● User Name (The LDAP bind name) (2 in SQL)
● User Name and Password (Default) (Used for LDAP au­
thentication) (3 in SQL)

Security Enable SSL Encryption Specify whether to connect to Impala Server using SSL.

 Note
The CA certificate for the remote source must be im­
ported into the adapter truststore on the Data Provision­
ing Agent host.

Use Agent Stored Credential Set to True to use credentials that are stored in the Data Pro­
visioning Agent secure storage.

Allow Self-Signed Server SSL Specify whether to allow the server to use a self-signed SSL
Certificate certificate. This property is meaningful only if SSL is enabled.

Require Certificate Name Specify whether to require that a CA-issued SSL certificate
Match Server Host Name name must match the Impala Server host name. This prop­
erty is meaningful only if SSL is enabled.

Kerberos Realm Optional. If specified, you can omit the realm part (for exam­
ple @EXAMPLE.COM) of the Impala Service Principal and
User Principal properties.

KDC Kerberos Key Distribution Center (KDC). This property is op­


tional and meaningful only if the Realm parameter is speci­
fied. If the Realm parameter is not specified, the parameter
must be manually configured in <DPAgent_root>/
krb5/krb5.conf for the realm of Impala Service Principal
and User Principal.

Impala Service Principal Specify the Kerberos principal of the Impala service.

User Principal Specify the Kerberos principal of the connection user.

Use Keytab Set this to True if you want the module to get the technical
user's key from the keytab. The default value is False.

If Key Tab is not set, then the module locates the keytab from
the Kerberos configuration file. If it is not specified in the Ker­
beros configuration file, then the module looks for the file
<user.home><file.separator>krb5.keytab.

Keytab Set this to the file name of the keytab to get the technical us­
er's secret key.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 183
Category Option Description

Use Ticket Cache Set this to true if you want the ticket-granting ticket (TGT) to
be obtained from the ticket cache. Set this option to False if
you do not want this module to use the ticket cache. The de­
fault value is False.

This module searches for the ticket cache in the following lo­
cations:

● On Solaris and Linux, in /tmp/krb5cc_<uid>, where


the uid is a numeric user identifier.
● If the ticket cache is not available in /tmp/
krb5cc_<uid>, or if you are on a Windows platform,
the module looks for the cache as
<user.home><file.separator>krb5cc_<use
r.name>. You can override the ticket cache location by
using the Ticket Cache parameter.
● For Windows, if a ticket cannot be retrieved from the file
ticket cache, the module uses Local Security Authority
(LSA) API to get the TGT.

Ticket Cache Set this to the name of the ticket cache that contains the us­
er's TGT. If this is set, Use Ticket Cache must also be set to
true; otherwise, a configuration error is returned.

Data Type Mapping Map Impala STRING to Specify to which SAP HANA type the Impala STRING is map­
ped. Choose from the following values:

● CLOB
● VARCHAR(5000)

Map Impala VARCHAR(length Specify to which SAP HANA type the Impala VAR­
> 5000) to
CHAR(length > 5000) is mapped. Choose from the following
values:

● NCLOB
● NVARCHAR(5000)

Schema Alias Replace­ Schema Alias Schema name to be replaced with the schema given in
ments
Schema Alias Replacement.

If given, accessing tables under this alias is considered to be


accessing tables under the schema given in Schema Alias
Replacement

Schema Alias Replacement Schema name to be used to replace the schema given in
Schema Alias.

Installation and Configuration Guide


184 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Credentials Credentials Mode Remote sources support two types of credential modes to
access a remote source: technical user and secondary cre­
 Note dentials.

Depending on the ● Technical User: A valid user and password in the remote
value you chose for the database. This valid user is used by anyone using the re­
Authentication mote source.
● Secondary User: A unique access credential on the re­
Mechanism parame­
mote source assigned to a specific user.
ter, the credentials
that appear will be dif­
ferent.

Credential (User Name and User name. Required only if the Authentication Mechanism
Password) > User Name
parameter is set to User Name and Password.

Credential (User Name and Password. Required only if the Authentication Mechanism pa­
Password) > Password
rameter is set to User Name and Password.

Credential (User Name) > User User name. Required only if the Authentication Mechanism
Name
parameter is set to User Name.

Credential (Kerberos) > Pass­ Kerberos password. Required only if the Authentication
word
Mechanism parameter is set to Kerberos.

User and Password Parameters for LDAP Authentication

The Impala adapter's User Name and Password remote source parameters are used when the Impala server
requires LDAP authentication. The User Name parameter is the LDAP user name. The Password parameter is
the LDAP bind password. Depending on the LDAP bind name pattern configuration in Impala Server, you may
need to provide values for either of these parameters:

● If ldap_domain is configured, the User Name is replaced with a string username@ldap_domain;


● If ldap_baseDN is configured, the User Name is replaced with a distinguished name (DN) of the form
uid=userid,ldap_baseDN. This is equivalent to a Hive option.
● If ldap_bind_pattern is configured, the User Name is replaced with the string ldap_bind_pattern, where
all instances of the string #UID are replaced with the user ID. For example, an ldap_bind_pattern of
user=#UID,OU=house,CN=boat with a user name of Customer1 constructs a bind name of
user=Customer1,OU=house,CN=boat.

See https://www.cloudera.com/documentation/enterprise/latest/topics/impala_ldap.html for more


information.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 185
Sample SQL Remote Source Configuration

Example

 Sample Code

CREATE REMOTE SOURCE "MyImpalaSource" ADAPTER "ImpalaAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="connection" displayName="Connection">
<PropertyEntry name="host" displayName="Host" >myhost.sap.corp</PropertyEntry>
<PropertyEntry name="port" displayName="Port">21050</PropertyEntry>
<PropertyEntry name="auth_mech" displayName="Authentication Mechanism">0</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="data_type_mapping">
<PropertyEntry name="string_to_default">true</PropertyEntry>
<PropertyEntry name="varchar_5000plus_to_default">true</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Using a Schema Alias [page 277]


Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.8.2 Kerberos Realm and KDC


You can configure the Kerberos environment, known as its context, either through the krb5.conf file or
through remote source parameters.

You must configure the Kerberos realm's Key Distribution Center (KDC) host name or address through either
the krb5.conf file or adapter remote source parameters.

Through the krb5.conf File

<DPAgent_root>/krb5/krb5.conf is a standard Kerberos V5 configuration file. Initially, it is an empty


configuration file containing [libdefaults], [realms] and [domain_realm] headers. You can configure

Installation and Configuration Guide


186 PUBLIC Configure Data Provisioning Adapters
KDC under the [realms] section. Also, if the default realm is not configured in the file, you need to configure it
under the [libdefaults] section. The following is an example, where the configured realm is
EXAMPLE.COM.

[libdefaults]
default_realm = EXAMPLE.COM
[realms]
EXAMPLE.COM = {
kdc = kdc.example.com
}
[domain_realm]

 Note

Do not remove any existing configurations in this file. Changes to this file take effect immediately without
the need to restart the Data Provisioning Agent.

Through Adapter Remote Source Parameters

You can configure the realm and KDC through the adapter remote source parameters Realm and KDC; you
need to specify both. This is a shortcut to editing <DPAgent_root>/krb5/krb5.conf. The adapter writes
the configuration to the krb5.conf if absent when the adapter connects to KDC.

6.9 File

Use the File adapter to read formatted and free-form text files.

The File adapter enables SAP HANA users to read formatted and free-form text files. In contrast to the File
Datastore adapters, use the File adapter for the following scenarios:

● SharePoint access
● SharePoint on Office365
● Pattern-based reading; reading multiple flies in a directory that match a user-defined partition
● Five system columns are included, including row num, file location, and so on
● Real-time file replication

To specify a file format such as a delimiter character, you must create a configuration file with the
extension .cfg to contain this information. Then each file can be read and parsed through this format,
returning the data in columns of a virtual table.

For free-form, unstructured text files, you do not need to designate a file format definition, and you can use the
FILECONTENTROWS virtual table to view the data.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 187
Authorizations

Keep the following in mind when accessing files:

● Ensure that the user account under which the Data Provisioning Agent is running has access to the files on
the local host, a shared directory, or a SharePoint site.
● If the files are located on the same host as the Data Provisioning Agent, the files must be located in the
same directory, or a subdirectory, of the Data Provisioning Agent root directory.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● Virtual table as a target using a Data Sink in a flowgraph; only INSERT is supported.

 Note

Writing to SharePoint is not supported.

● SharePoint source support


● HDFS target file support, except from SharePoint
● Kerberos authentication for HDFS target files
● Real-time change data capture

 Note

Only rows appended to a file initiate the capture. Only APPEND is supported. Using any other
command, such as DELETE, UPDATE, and so on, may shut down replication altogether.

Also, the addition of a file to the virtual table's directory initiates the capture. This functionality is not
supported for HDFS source files.

In addition, this adapter supports the following capabilities:

● SELECT, INSERT

Related Information

Configure the File Adapter [page 189]


File Adapter Remote Source Configuration [page 190]
Configuration Files [page 198]
Remote Source Tables [page 215]
Connect to a SharePoint Remote Source [page 215]
Access SharePoint Using HTTPS/SSL [page 217]
Accessing Files On a Shared Network [page 218]
Disable Adapter Write-back Functionality [page 219]

Installation and Configuration Guide


188 PUBLIC Configure Data Provisioning Adapters
Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft Office365 [page
220]
Configure Your Microsoft Azure Application [page 221]
File Datastore Adapters [page 222]

6.9.1 Configure the File Adapter

The File adapter is already deployed with the Data Provisioning Agent that you installed. However, you must
configure and register the adapter.

Procedure

1. Launch dpagentconfigtool.exe under <DPAgent_root>/configTool.

2. Go to Configure Preferences and select FileAdapter.


3. Enter the configuration information for your adapter.
4. Click Apply to save the changes.

Next Steps

Now, you can register your adapter with the Data Provisioning Agent.

Related Information

File Adapter Preferences [page 189]


Register Data Provisioning Adapters [page 111]

6.9.1.1 File Adapter Preferences

Configuration parameters for the File adapter.

Parameter Description

Root directory The root directory for your data files. No remote source can reach beyond this directory
for data files.

File format root directory The root directory for your file format definitions. No remote source can reach beyond
this directory for format files.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 189
Parameter Description

Access Token A password. An access token protects the files from access from different agents. Use
this password when creating a remote source.

6.9.2 File Adapter Remote Source Configuration

Determine the configuration parameters for your File adapter remote source. You can use the code samples
below for creating a remote source using the SQL console.

The available parameters might change depending on which options you choose.

 Note

To use a Data Provisioning Agent installed on Linux to connect to the SharePoint site, enable basic
authentication on the SharePoint server.

Category Option Description

ConnectionInfo Source Options ● Local File System: Specifies that


the source is a file on a local
system.
● SharePoint Server: Specifies that
the source is on a SharePoint
server.
● SharePoint on Office365: Specifies
that the Microsoft Excel source is
on an Office365 server.

 Note
Whichever you select Local File
System, SharePoint Server, or
SharePoint on Office365, the File
adapter remote source only
displays the file format definitions
(.cfg files) under the Data
Provisioning Agent local folder that
you specify in the remote source. It
never displays files or directories
on the SharePoint server directly,
which is different than the Excel
Adapter with SharePoint scenario.
You need to provide the path to the
source file on the SharePoint site in
the CFG file, then create the virtual
table in the file format definitions.

Installation and Configuration Guide


190 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Target Options The path to the folder that you want to


access on the local file system where
the Data Provisioning Agent is
deployed.

Remote HDFS: Specifies that the target


file is on a remote HDFS system.

Root Directory The root directory for your data files.


This is used for security. No remote
source can reach beyond this directory
for data files. The root directory must
exist before you can create a remote
source.

 Note
Do not use a link directory or
directory shortcut for a value in
this parameter.

If you are using a shared network


directory, enter the path as follows:

\\<host_name>\<directory>

Directory of the file format definitions Location where you store your file
format definition files. This directory
must exist before you can create a
remote source. Include the full path
and file name.

 Note
Do not use a linked directory or
directory shortcut for a value in
this parameter.

SharePoint on Office365 Configuration Authentication Mode Choose the type of credentials needed
to access SharePoint on Office365

● Client Credential (default):


● Username Password:

Site URL Enter the site URL, in the form of


https://<company>.sharepoint.com/
sites/<siteName>

Application ID Enter the application ID, as defined in


the Microsoft Azure Portal.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 191
Category Option Description

Tenant ID Enter the tenant ID, as defined in the


Microsoft Azure Portal.

Local Folder Path The path to the folder that you want to
access on the local file system where
the Data Provisioning Agent is
deployed.

ConnectionInfo > HDFS Configuration Host Name The remote URL to connect to the
remote HDFS, usually defined in
core-site.xml..

Port Number Port number to connect to the remote


HDFS, usually defined in core-
site.xml.

Target File Location The location to store copied target files


in a remote HDFS. For example, you
might want to copy a target file from a
local to a remote HDFS.

Hadoop User Name The user of the Hadoop system when


logging in. This can also be the owner
of the file location where you want to
put the copied target files. Make sure
you have the proper permissions to
access this location.

HDFS Authentication Mechanism Choose Kerberos to implement


Kerberos authentication. You are then
required to complete the necessary
parameters in the Kerberos
Configuration for HDFS option group.

Choose No Authentication if you are


not using Kerberos.

Kerberos Configuration for HDFS Realm (Optional when using Kerberos)


Authenticate using a principal from this
realm instead of the systems default
realm. Specify the realm for the
technical user.

The Realm option must be used


together with KDC.

KDC (Optional when using Kerberos) The


address of the technical user's KDC
(Key Distribution Center) to be used
with the specified realm. This must be
used together with the Realm option.

Installation and Configuration Guide


192 PUBLIC Configure Data Provisioning Adapters
Category Option Description

HDFS Principal The HDFS Service principal name.

Client Principal Specify the Kerberos principal of the


connection user.

Use Keytab Set this to True if you want the module


to get the technical user's key from the
keytab. The default value is False.

If Key Tab is not set, then the module


locates the keytab from the Kerberos
configuration file. If it is not specified in
the Kerberos configuration file, then
the module looks for the file
<user.home><file.separator
>krb5.keytab.

Keytab Set this to the path and file name of the


keytab to get the technical user's
secret key.

Use Ticket Cache Set this to true if you want the ticket-
granting ticket (TGT) to be obtained
from the ticket cache. Set this option to
False if you do not want this module to
use the ticket cache. The default value
is False.

This module searches for the ticket


cache in the following locations:

● On Solaris and Linux, in /tmp/


krb5cc_<uid>, where the uid is
a numeric user identifier.
● If the ticket cache is not available
in /tmp/krb5cc_<uid>, or if
you are on a Windows platform,
the module looks for the cache as
<user.home><file.separa
tor>krb5cc_<user.name>.
You can override the ticket cache
location by using the Ticket Cache
parameter.
● For Windows, if a ticket cannot be
retrieved from the file ticket cache,
the module uses Local Security
Authority (LSA) API to get the TGT.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 193
Category Option Description

Ticket Cache Set this to the name of the ticket cache


that contains the user's TGT. If this is
set, Use Ticket Cache must also be set
to true; otherwise, a configuration error
is returned.

ConnectionInfo > SharePoint Server Server URL Enter the URL for the server where the
Configuration SharePoint source is located.

If you create a new SharePoint site on


the server, be sure to include the name
of the site at the end of the URL. For
example, if your server name is
http://<server_name>/ and
your new site name is site1, your URL
would be http://
<server_name>/site1.

Local Folder Path The download folder path. This folder is


created under the
<DPAgent_root>/ directory
automatically.

The local folder path is the location on


the Data Provisioning Agent
computer's local drive where you want
to place your source data files, which
the Data Provisioning Agent will
download from the SharePoint server

For example, if you enter a value for


this parameter such as download/
sharepoint, create the following
path: <DPAgent_root>/
download/sharepoint.

Credentials Credentials Mode Technical user or Secondary user

Select one of the choices depending on


the purpose of the remote source you
want to create.

Credentials > AccessTokenEntry Password A password. An access token protects


the files from access from different
agents. Use this password when
creating a remote source.

Credentials > SharePoint Login SharePoint User (Domain\Username) The domain and user name for the
SharePoint account.

Installation and Configuration Guide


194 PUBLIC Configure Data Provisioning Adapters
Category Option Description

SharePoint Password The password for the SharePoint


account.

Credentials > Credential (Kerberos) Password The password for the Kerberos-
protected HDFS.

SharePoint on Office365 Credential Client Credential Enter the client secret you created on
the Microsoft Azure Portal.

SharePoint on Office365 Username Username Enter the username of your Microsoft


Password account.

Password Enter the password of your Microsoft


account.

Kerberos Setup for HDFS Target

● If you use Keytab and not Ticket Cache, specify the keytab file path in the Keytab parameter.
● If you are using Ticket Cache and not Keytab, specify the ticket cache file path in the Ticket Cache
parameter. Then, you can use any password (such as “abc” or “123”for the Credential (Kerberos)
parameter, because a password is required in Web IDE.
● Also, if you are using Ticket Cache and not Keytab, you can leave the ticket cache file path blank, but then
you must use the correct password for the Password of Credential (Kerberos) option

Remote Source Configuration Using the SQL Console

The following code samples illustrate how to create a remote source using the SQL console.

Example: Local file system

 Sample Code

CREATE REMOTE SOURCE "MyFileSource" ADAPTER "FileAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties>
<PropertyEntry name="rootdir">myrootdir</PropertyEntry>
<PropertyEntry name="fileformatdir">myfileformatdir</PropertyEntry>
<PropertyEntry name="source_options">local</PropertyEntry>
<PropertyEntry name="target_options">local</PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password>mytoken</password>
</CredentialEntry>';

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 195
Example: Local file system with real-time

 Sample Code

CREATE REMOTE SOURCE "MyFileSource" ADAPTER "FileAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties>
<PropertyEntry name="rootdir">myrootdir</PropertyEntry>
<PropertyEntry name="fileformatdir">myfileformatdir</PropertyEntry>
<PropertyEntry name="usecdc">true</PropertyEntry>
<PropertyEntry name="source_options">local</PropertyEntry>
<PropertyEntry name="target_options">local</PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password>mytoken</password>
</CredentialEntry>';

Example: HDFS as target

 Sample Code

CREATE REMOTE SOURCE "MyFileSource" ADAPTER "FileAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties>
<PropertyEntry name="rootdir">myrootdir</PropertyEntry>
<PropertyEntry name="fileformatdir">myfileformatdir</PropertyEntry>
<PropertyEntry name="target_options">hdfs</PropertyEntry>
<PropertyEntry name="host">hdfs:/myhost.sap.corp</PropertyEntry>
<PropertyEntry name="port_number">8020</PropertyEntry>
<PropertyEntry name="target_hdfs_file_location">/user/sap</PropertyEntry>
<PropertyEntry name="hadoop_user_name">myuser</PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password>mytoken</password>
</CredentialEntry>';

Installation and Configuration Guide


196 PUBLIC Configure Data Provisioning Adapters
Example: SharePoint location

 Sample Code

CREATE REMOTE SOURCE "MyFileSource" ADAPTER "FileAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties>
<PropertyEntry name="rootdir">myrootdir</PropertyEntry>
<PropertyEntry name="fileformatdir">myfileformatdir</PropertyEntry>
<PropertyEntry name="source_options">SharePoint</PropertyEntry>
<PropertyEntry name="target_options">local</PropertyEntry>
<PropertyGroup name="SharePoint">
<PropertyEntry name="spurl">http://myhost.sap.corp/mysharepointsite</
PropertyEntry>
<PropertyEntry name="spdir">download/sharepoint</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password>mytoken</password>
</CredentialEntry>
<CredentialEntry name="sharePointCredential">
<user>mydomain\mysharepointuser</user>
<password>mypassword</password>
</CredentialEntry>';

Example: Microsoft SharePoint on Office365

CREATE REMOTE SOURCE "MyFileSource" ADAPTER "FileAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties>
<PropertyEntry name="rootdir">myrootdir</PropertyEntry>
<PropertyEntry name="fileformatdir">myfileformatdir</PropertyEntry>
<PropertyEntry name="source_options">SharePoint365</PropertyEntry>
<PropertyEntry name="target_options">local</PropertyEntry>
<PropertyGroup name="SharePoint365">
<PropertyEntry name="authenticationMode">ClientCredential</PropertyEntry>
<PropertyEntry name="siteUrl">https://mycompany.sharepoint.com/sites/
mysharepointsite</PropertyEntry>
<PropertyEntry name="applicationId">myApplicationID</PropertyEntry>
<PropertyEntry name="tenantId">myTenantId</PropertyEntry>
<PropertyEntry name="sp365dir">download/sharepoint</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password>mytoken</password>
</CredentialEntry>
<CredentialEntry name="sharePoint365ClientCredential">
<password>myClientSecret</password>
</CredentialEntry>';

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 197
Related Information

HDFS Target Files


Accessing Files On a Shared Network [page 218]
Connect to a SharePoint Remote Source [page 215]
Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft Office365 [page
220]
Configure Your Microsoft Azure Application [page 221]

6.9.3 Configuration Files

Configuration files enable the application to read the file format accurately. You must have a configuration file
when using the File adapter.

You can create file format configuration files either within SAP HANA Web IDE using the command line or by
creating a text file.

Using Web IDE can speed up the process of creating your file format configuration files. Using the command
line or a text file to create the configuration file requires that you use a separate text editor to enter the options
and values manually into an empty file.

Related Information

File Format Configuration Files [page 198]


Generate the Configuration File with SAP Web IDE [page 205]
Generate the Configuration File With a Command-Line Utility [page 211]
Generate the Configuration File When Creating a Virtual Table [page 214]

6.9.3.1 File Format Configuration Files

Create a file format configuration file to work with the data file used by the File adapter.

Each configuration file is a text file and must match the following format:

● The first line must contain a comment or a description. This line is ignored during processing.
● A set of key-value pairs to specify the various parsing options.
● A set of COLUMN=<name>;<SAP HANA datatype>;<optional description>

Installation and Configuration Guide


198 PUBLIC Configure Data Provisioning Adapters
Example

File format to read US census data, see https://www.census.gov/econ/cbp/download/


FORMAT=CSV
FORCE_FILENAME_PATTERN=us_county_census_%.txt
FORCE_DIRECTORY_PATTERN=
CODEPAGE=
LOCALE=
COLUMN_DELIMITER=,
ROW_DELIMITER=\r\n
ESCAPE_CHAR=
TEXT_QUOTES="
TEXT_QUOTES_ESCAPE_CHAR=
SKIP_HEADER_LINES=1
QUOTED_TEXT_CONTAIN_ROW_DELIMITER=false
DATEFORMAT=yyyy.MM.dd HH:mm:ss
COLUMN=FIPSTATE;VARCHAR(2);FIPS State Code
COLUMN=EMP;INTEGER;Total Mid-March Employees with Noise
COLUMN=QP1_NF;VARCHAR(1);Total First Quarter Payroll Noise Flag
COLUMN=CENSTATE;VARCHAR(2);Census State Code
COLUMN=CENCTY;VARCHAR(3);Census County Code
COLUMN=PARTITION
COLUMNSTARTENDPOSITION=

Fixed-Format Files

Fixed file formats are also supported (FORMAT=fixed). The formatting can be specified using the
COLUMSTARTENDPOSITION parameter or the ROW_DELIMITER and ROWLENGTH parameters.

Example

Fixed file format


FORMAT=FIXED
FORCE_FILENAME_PATTERN=fixed%.txt
CODEPAGE=UTF-8
LOCALE=
ROW_DELIMITER=\r\n
SKIP_HEADER_LINES=1
COLUMNSSTARTENDPOSITION=0-1;2-7;8-15
ROWLENGTH=16
COLUMN=COL1;VARCHAR(2)
COLUMN=COL2;VARCHAR(6)
COLUMN=COL3;VARCHAR(8)

SharePoint Format Files

The FORCE_FILENAME_PATTERN and FORCE_DIRECTORY_PATTERN parameters are important when working


with a SharePoint source.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 199
Example

If your file exists in a subfolder, be sure to include that in the path for the FORCE_DIRECTORY_PATTERN
parameter.

FORCE_FILENAME_PATTERN=<file_name>.txt
FORCE_DIRECTORY_PATTERN=<root_directory><local_folder_path>/<folder_name>

 Note

The FORCE_DIRECTORY_PATTERN should be an absolute path that includes the root directory, local folder
path, and folder path on the Sharepoint server.

Related Information

Format Parameters [page 201]

Installation and Configuration Guide


200 PUBLIC Configure Data Provisioning Adapters
6.9.3.1.1 Format Parameters

Format parameters for files.

Global

Parameter Description and Examples

FORCE_FILENAME_PATTERN You might want to execute a simple select * from <virtualtable>


without a WHERE clause on a directory. In that case, every file in the root directory
FORCE_DIRECTORY_PATTERN
and subdirectories is read according to this virtual table format definition. That
process might take a while and produce many errors.

However, if the virtual table maps to files in a particular directory or directory tree,
or only to particular file names, you can specify this information in the virtual table
directly. For example:

● Reading all files in that directory only:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata

● Reading all files in that directory and subdirectories:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata/%

● Reading all files in directories that start with "plan":

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plan%:

● Reading a file such as plan20120101.txt:

FORCE_FILENAME_PATTERN=plan%.txt

● Reading files inside the directory and matching the provided name pattern:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata
FORCE_FILENAME_PATTERN=plan%.txt

 Note
The path you use in the FORCE_DIRECTORY_PATTERN parameter is case sen­
sitive. For example, if you set the Root Directory remote source parameter to
“C:\”, you must match that case in the FORCE_DIRECTORY_PATTERN param­
eter.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 201
Parameter Description and Examples

FORMAT Specifies the format of the data source file:

● CSV (default)
● FIXED
● XML
● JSON

CODEPAGE The character encoding with which the file is read. By default, the operating sys­
tem default codepage is used. In case the file has a Byte Order Mark, this code­
page is always used. Valid values of the Java installation can be found by creating a
virtual table for CODEPAGE and querying its contents.

ROW_DELIMITER A character sequence indicating the end of a row in the file. In case they are non-
printable characters, they can be provided when encoded as /d65536 or /xFFFF or
as Unicode notation /u+FFFF. Alternatively, the typical \r and \n are supported as
well. Examples:

● \n Unix standard
● \r\n Windows standard
● \d13\d10 Windows standard, but characters provided as a decimal number
● \x0D\x0A Windows standard, but characters provided as a hex number

SKIP_HEADER_LINES In case the file has a header, the number of lines to be skipped is entered here.

When SKIP_HEADER_LINES=0, it means that the writer will not add a header to
the newly created data file.

When SKIP_HEADER_LINES>0, it will add a header to the newly created data file.

ERROR_ON_COLUMNCOUNT By default, a row with fewer columns than defined is considered okay. By setting
this parameter to true, it is expected that all rows of the file have the number of
columns defined.

LOCALE The decimal and date conversion from the strings in the file into native numbers or
dates might be locale-specific. For example, the date “14. Oktober 2000” when
you are using a German locale works. However, for all other languages, this date
does not work.

Valid values for the locale can be found by querying a virtual table based on the
LOCALE table of the adapter.

WRITEBACK_NUMBER_FORMAT Instructs the File adapter to respect the LOCALE parameter when writing decimal
values.

Default: True

The decimal number follows the column definition of the CFG file if set to True. If
WRITEBACK_NUMBER_FORMAT=false, the decimal number is plain and keeps the
origin fraction digits, and it does not follow the decimal definition in the CFG file.

Installation and Configuration Guide


202 PUBLIC Configure Data Provisioning Adapters
Parameter Description and Examples

DATEFORMAT The file format can use these data types for date/time-related values. Each can
have a different format string. The syntax of the format string is the Java Simple­
TIMEFORMAT DateFormat syntax.

SECONDDATEFORMAT

TIMESTAMPFORMAT

LENIENT Controls automatic date and time format conversion when the value exceeds the
range.

For example, when this parameter is set to True, the 14th month of 2016 is con­
verted to the second month of 2017.

EXPONENTIAL Defines the exponential character used for decimal numbers.

For example, e for 1.05097214923805e-06 or E for


1.05097214923805E-06.

Default: E

COLUMN Multiple entries consist of the columnname;datatype, where the data type is any
normal SAP HANA data type.

CSV only

Parameter Description and Examples

COLUMN_DELIMITER The character sequence indicating the next column. If non-printable charac­
ters are used, then either the \d65536, \xFFFF, or \u+FFFF encoding works.
The default value is “'”. In addition:

● “;” as the column separator; for example, 2000;IT Costs;435.55


● “|” uses the pipe character as a delimiter
● “\d09” uses an ASCII tab character as a delimiter

TEXT_QUOTES Sometimes text data is enclosed in quotes so a column delimiter inside the text
does not break the format. The line 2000;IT Costs; software
related only;435.55 would appear as 4 columns because the text con­
tains a semicolon as well. If the file was created with quotes like 2000;"IT
Costs; software related only";435.55, then there is no such is­
sue, but the file parser must act more carefully and not just search for the next
column delimiter. It must check if the text is inside the text quote character or
outside.

ESCAPE_CHAR Another way to deal with inline special characters is to escape them; for exam­
ple, 2000;IT Costs\; software related only;435.55. Here
the \ is an escape character and indicates that the subsequent character is to
be taken literally, not as a column delimiter.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 203
Parameter Description and Examples

TEXT_QUOTES_ESCAPE_CHAR How to make quotes appear inside the text; for example, IT Costs;
"software related" only. One option the file creator might have used
is to use the global escape character: 2000;"IT Costs; \"software
related\" only";435.55. Another popular method is to have the
quotes escaped by another quote like in 2000;"IT Costs; ""software
related"" only";435.55. In that case, both the TEXT_QUOTE=" and
the TEXT_QUOTE_ESCAPE_CHAR=" are set to the " character.

QUOTED_TEXT_CONTAIN_ROW_DELIM­ The default value is False, which tells the parser that regardless of any quotes
ITER or escape characters, the text inside a row never contains the row delimiter
character sequence. In this case, the parser can break the file into rows faster,
can search only for the character sequence, and only the column parsing has
to consider the escape and quote characters. If set to true, parsing is slower.

Fixed-Width only

Parameter Description and Examples

COLUMNSSTARTENDPOSI­ In a fixed-width file, the column positions must be specified for each column. Examples:
TION
● 0-3;4-11;12-37;38-53 defines that the first 4 characters are the first column, the next 8
contain the data for the second column, and so on. Columns must be in the proper or­
der.
● 0;4;12;38 is equivalent to the previous example, but the last column ends with the line
end
● 0;4;12;38-53 can be used as well. In fact, for every column you can either specify the
start and end position or just the start.

ROWLENGTH In fixed-width files, there does not need to be a row delimiter. Often the file has some and
then they must be stripped away. The following examples assume that the last data charac­
ter is at index 53 as specified the COLUMNSTARTENDPOSITION example.

● ROWLENGTH=56 ROW_DELIMITER= would work for a file that has a row delimiter. The
payload text ranges from 0..53; therefore, it is 54 characters long plus two characters
for \r\n. The last column does not contain the \r\n because it is instructed to end at
index 53.
● ROWLENGTH=54 ROW_DELIMITER=\r\n is equivalent to the previous example. Each
row is expected to be 54 characters plus 2 characters long. The main advantage of this
notation is that COLUMNSSTARTENDPOSITION=0;4;12;38 would work and the trailing
\r\n is stripped away. In the previous example, the last column would start at 38 and
end at index 55 due to rowlength=56 and therefore contain the \r\n characters in the
last column.

Installation and Configuration Guide


204 PUBLIC Configure Data Provisioning Adapters
XML and JSON only

Parameter Description and Examples

SCHEMA_LOCATION The absolute path to the XML schema file <filename>.xsd. For example:

SCHEMA_LOCATION=Z:\FileAdapter\XMLSchema\example.xsd

TARGET_NAMESPACE The target namespace defined in the XML schema. For example:

TARGET_NAMESPACE=NISTSchema-negativeInteger-NS

ROOT_NAME The XML node to use to display the hierarchy structure. For example:

ROOT_NAME=root

CIRCULAR_LEVEL The maximum recursive level in the XML schema to display. For example:

CIRCULAR_LEVEL=3

6.9.3.2 Generate the Configuration File with SAP Web IDE

Use SAP Web IDE to create file format configuration files so that your CSV and fixed-format files can be used in
processing your data in the Flowgraph Editor.

Prerequisites

Ensure the SAP HANA database (HDB) module exists. For more information, see the SAP HANA Developer
Guide for XS Advanced Model.

Context

To create a file format configuration file in SAP Web IDE:

Procedure

1. Create a virtual table by right-clicking the src folder and choosing New File , then enter a file name
with the .hdbvirtualtable extension. For example, myVT.hdbvirtualtable.

2. Right-click the .hdbvirtualtable file, and then choose Open With File Format Editor .

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 205
The File Format Editor is separated into three panes. The options pane shows all of the settings for the file
location and file content. The required settings have an asterisk (*) next to them. In the top-right pane, you
can copy and paste a few lines from your data file to test the options you have set in the left pane. For a
complete list of options and descriptions, see File Format Options [page 207].
3. Enter the remote source name and remote object identifier. These identifiers help determine the location
and the configuration file that it references. In this example, the remote source name is Remote and the
remote object identifier is Object: VIRTUAL TABLE DUMMY AT
"REMOTE"."<NULL>"."<NULL>"."OBJECT"
4. Enter a file name pattern. This action associates all files with this pattern to the file format definition. For
example, %.txt applies to all files with a TXT extension. 123%.txt applies to all TXT files that begin with
the value “123”.
5. Choose the file format type.

Option Description

CSV Uses the comma-separated value format.

Fixed Uses the fixed-width format.

6. Set the required options based on the file format type selected in the previous step.

○ If you chose the CSV format, set the column delimiter that is used to separate the values in your file.
Frequently, this delimiter is a comma (,), but you can also use other values such as a semicolon (;),
colon(:), pipe (|), and so on.
○ If you chose the Fixed format, enter the row length and the column start and end numbers. The row
length should be the value of the entire row, including spaces and delimiters. The column start and end
numbers are the length of each column. You can enter the span of the column, or only the starting
number of the column. For example, 0-3;4-14;15-27 and 0;4;15 each return three columns with a total
row length of 28.
7. In the Virtual Table Columns section, add one or more columns of your virtual table or enter column
heading names by clicking the + icon and setting the name, description, and type of each new column.
Depending on the type you selected, you may also need to enter length, precision, and scale options.
If you choose to test your settings, you can see the columns you have added in the Simulation pane.

You can run the simulation on your file and copy the detected header information as columns in the Virtual
Table Columns section.
8. To test your settings, copy several lines from your data file and paste them into the top-right pane. Click the
Run Simulation icon above this pane to see the simulated results in the bottom-right pane.
9. When you have completed the settings, click Save.
You can either create a configuration file that serves as the file format definition, or you can use the virtual
table as the file format definition. The advantage of a virtual table is that you can use the table as an object
in your flowgraph. For example, you can reference it as a HANA Object in the Data Source and Data Target,
and in any nodes where you can call a procedure in the flowgraph. If you created a virtual table, the
configuration file is automatically created and placed in the file adapter with the name
<remote_object_identifier>.cfg. If you are creating a configuration file, continue with the following
steps.
10. (Optional) If you want to create a configuration file:
1. Right-click the .hdbvirtualtable file and choose Configuration (.cfg.txt).
2. Export the configuration file by right-clicking the .cfg.txt file, and choose Export to place the file in
your file adapter.

Installation and Configuration Guide


206 PUBLIC Configure Data Provisioning Adapters
3. On the file adapter, right-click the .cfg.txt file, choose Rename, then delete the .txt extension from
the filename so that it ends in .cfg. For example, you would rename the file
northwest_sales.cfg.txt to northwest_sales.cfg.

Related Information

File Format Options [page 207]


Create an HDB Module (SAP HANA Developer Guide for SAP HANA XS Advanced Model)

6.9.3.2.1 File Format Options

Lists the options available for generating the file format definition in SAP Web IDE.

Remote Source

Option Description

Remote Source Name Enter the name of the remote source, which helps locate the remote source.

Remote Object Identifier Enter the ID of the object on the remote source, which helps identify the configuration
file that it references. If the configuration file does not exist under that identifier, a con­
figuration file is created when the virtual table is deployed.

Description Enter an optional description of the remote source.

File Location

Option Description

Filename Pattern Enter a file name pattern that indicates the files that are used automatically with this file
format definition. For example, if you enter 123%, all files that begin with 123 automati­
cally use this file format definition.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 207
Option Description

Directory Pattern Enter a directory pattern that indicates the location of the files used with this file format
definition. You can use the directory pattern alone, or with the filename pattern setting,
to narrow the virtual tables that use this file format definition. You might want to exe­
cute a simple select * from <virtualtable> without a WHERE clause on a
directory and name of the file. In that case, every single file in the root directory and
subdirectories is read and parsed according to this virtual table format definition. Proc­
essing might take a while and produce many errors. However, if the virtual table maps
to files in a particular directory, directory tree, or to particular file names only, you can
specify this information in the virtual table directly. For example:

● Read all files in one directory only:


Directory Pattern=/usr/sap/FileAdapter/FileServer/
plandata
● Read all files in the directory and subdirectories:
Directory Pattern=/usr/sap/FileAdapter/FileServer/
plandata/%
● Read all files in directories that start with “plan”
Directory Pattern=/usr/sap/FileAdapter/FileServer/plan
%:
● Read files like plan20120101.txt
Filename Pattern=plan%.txt
● Read files inside the directory and match the provided name pattern

Directory Pattern=/usr/sap/FileAdapter/FileServer/
plandata
Filename Pattern=plan%.txt

Number of Partitions Enter the number of partitions for parallel processing, which can improve performance.
Entering 0 means that the data is run serially.

File Content Specification (general options)

Option Description

Format Choose the data source file type, CSV (comma-separated value), or Fixed (fixed-width
files). The option you select here displays format-specific options.

Code Page Select the character encoding for the file. By default, the operating system default is
used. When the file has a Byte Order Mark, this code page is always used. Valid values
of the Java installation can be found by creating a virtual table for the code page and
querying its contents. If you chose JSON or XML as the format, then set the code page
to UTF-8.

Locale The locale option sets the decimal and date conversion from the strings in the file into
native numbers or dates. For example, the month and day “14. Oktober 2017” are valid
in German, but is not valid in other languages. Valid values for the locale can be found
by querying a virtual table based on the LOCALE table of the adapter.

Skipped Leader Lines If the file contains header information such as metadata that is not used in the actual
data columns, enter the number of lines to be skipped.

Installation and Configuration Guide


208 PUBLIC Configure Data Provisioning Adapters
Option Description

Row Delimiter Enter the character sequence indicating the end of a row in the file. When the delimit­
ers are nonprintable characters, they can be provided encoded as /d65536 or /xFFFF
or as Unicode notation /u+FFFF. Alternatively, the typical \r and \n are supported as
well. Examples:

● \n Unix standard
● \r\n Windows standard
● \d13\d10 Windows standard, but characters provided as a decimal number
● \x0D\x0A Windows standard, but characters provided as a hex number

File Content Specification (CSV only)

Option Description

Column Delimiter Enter the character sequence indicating the next column. If nonprintable characters
are used, then encoding \d65536, \xFFFF, or \u+FFFF works.

● ; The semicolon is the column separator, so a line looks like 2000;IT Costs;
435.55
● | Use the pipe character as the delimiter
● \d09 Use an ASCII tab character as the delimiter

Escape Character If you have special characters in your data such as quotation marks or semicolons, en­
ter an escape character to use the character literally. For example,2000;IT Costs
\; software related only;435.55. In this example, the \ char is an escape
char and indicates that the subsequent character, the semicolon (;), is to be taken lit­
erally, not as a column delimiter.

Text Quotes Character If you have text data enclosed in quotes, you can specify a character to indicate that
the quotes are part of the data, and not a delimiter. The line 2000;IT Costs;
software related only;435.55 would appear as 4 columns because the
text contains a semicolon as well. If the file was created with quotes like 2000;"IT
Costs; software related only";435.55, then the semicolon within the
quotes is not interpreted as a column delimiter.

Text Quotes Escape Character Specify how to make quotes appear inside the text, like in IT Costs; "software
related" only. One option the file creator might have used is to use the global
escape character: 2000;"IT Costs; \"software related\" only";
435.55. Another popular method is to have the quotes escaped by another quote
like in 2000;"IT Costs; ""software related"" only";435.55. In
that case both the Character for Text Quotes=" and the Text Quotes Escape Charac­
ter=" are set to the " character.

Quoted Text Contains Row Delim­ When disabled (off), indicates that any quotes or escape characters in text inside a
iter row does not contain the row delimiter character. In this case, processing is faster.
When enabled (on), processing is slower because the system looks for quotes or es­
cape characters in the rows.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 209
File Content Specification (Fixed Format only)

Option Description

Row Length In fixed width files, you do not need to set a row delimiter. Often the file has some de­
limiters, and then they must be stripped away. The following examples show that the
last data character is at index 53:

● Setting RowLength to 56 and leaving theRow Delimiter setting empty


works for a file that has a row delimiter. The payload text ranges from 0 to 53
(therefore is 54 characters long when counting the 0) plus two characters for \r
\n. However, the last column does not contain the \r\n, and is told to index at 53.
● Setting RowLength to 54 and Row Delimiter to \r\n is equivalent to the ex­
ample in the previous bullet. Each row is expected to be 54 characters plus 2
characters long. The main advantage of this notation is that setting the Columns
Start and End Position parameter to 0;4;12;38 works well, because the
trailing \r\n is stripped away. In the example in the previous bullet, the last col­
umn would start at 38 and end at index 55, because the row length is 56 and con­
tain the \r\n characters in the last column.

Columns Start and End Position Enter the column positions for each column. Example:

● 0-3;4-11;12-37;38-53 defines that the first 4 characters are the first column, the
next 8 contain the data for the second column, and so on. Columns must be in the
proper order.
● 0;4;12;38 is equivalent to the example in the previous bullet. The last column ends
with the line end.
● 0;4;12;38-53 can be used as well. In fact, every single column can either specify
the start and end position or just the start.

Virtual Table Format Settings

Option Description

Exponential Character Enter a character that identifies any exponents in the data.

Date Format Choose from the available date and time formats or enter a custom date or time format.
Each option can have a different format string. The syntax of the format string is the Java
Seconddate Format SimpleDateFormat syntax.

Time Format

Timestamp Format

Convert Invalid Date or Time Enable the option to correct automatically invalid date or time values. For example, the
27th hour changes to 3 am.

Installation and Configuration Guide


210 PUBLIC Configure Data Provisioning Adapters
Virtual Table Columns (Add Columns dialog)

Option Description

Name Enter the column name.

Description Enter a description of the column.

Type Select the column type based on the data in the column.

Length Enter the number of characters of the longest value in the column.

Precision Enter the total number of digits in the value. Used for Decimal data types.

Scale Enter the number of digits to the right of the decimal. Used for Decimal data types.

6.9.3.3 Generate the Configuration File With a Command-


Line Utility

Use a Data Provisioning utility to create the CFG file.

Procedure

1. Navigate to <DPAgent_root>\agentutils.
2. Run the following from the command line:
For Windows:

createfileformat.bat -file <PATH TO DATA FILE> -cfgdir <DIRECTORY TO STORE


GENERATED CFG FILES> <OPTION> <VALUE>.....

For UNIX:

createfileformat.sh -file <PATH TO DATA FILE> -cfgdir <DIRECTORY TO STORE


GENERATED CFG FILES> <OPTION> <VALUE>.....

Only the -file, -cfgdir, and -format (when using a CSV file) parameters are required.

The value for the -file parameter is the path to the directory containing one or more data files or the path
to a single file name for which the configuration files must be generated. The value for -cfgdir is the path
to the output directory where the generated configuration files are stored.

A number of options and value pairs can be provided as extra parameters. The following are supported:

Parameter Description

-colDelimiter The column delimiter

-rowDelimiter The row delimiter

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 211
Parameter Description

-txtDelimiter Text quotes

-escChar Escape character

-txtEscChar Quote escape character

-dateformat Default date format

-timeformat Default time format

-secondDateformat Default second date format

-format The format of the file

-firstRowAsColumnName Specifies whether to use the first row in a data file as the column names when gen­
erating a CFG file with the createfileformat.sh/bat tool.

If set to TRUE, createfileformat.sh/bat uses the row above the real data
as the column name. Otherwise, createfileformat.sh/bat sets the row
names as COL1, COL2, ... by default. The default value is FALSE.

/17

 Note
To use this parameter together with -skipHeaderLine, the row containing
the column names should be included in the -skipHeaderLine count. If
you set -firstRowAsColumnName to true and did not configure -
skipHeaderLine, -skipHeaderLine is set automatically to 1.

 Note
○ FIXED format files do not support -firstRowAsColumnName.
○ The count of column name in the column name line must be correct.
○ If there are two-column names, but there are 3 columns in the file data,
the last column is ignored.
○ The column delimiter also applies to the column name line.

-skipHeaderLine Skips header lines

Installation and Configuration Guide


212 PUBLIC Configure Data Provisioning Adapters
Parameter Description

-columnStartEndPosition FIXED file column start end position. For example, -columnStartEndPosition
0-10;11-20.

Handle this parameter differently for Windows and Linux systems. The following is
an example for Windows:

./createfileformat.sh -file /dpagent/text/test.txt -


cfgdir /dpagent/cfg
-rowLength 16 -columnStartEndPosition 0-14;14-15 -
format "FIXED"

For Linux, you must enclose the semicolon in double quotes:

./createfileformat.sh -file /dpagent/text/test.txt -


cfgdir /dpagent/cfg
-rowLength 16 -columnStartEndPosition 0-14";"14-15 -
format "FIXED"

-rowLength FIXED file row length

-quotedTxtContainsRowDelimiter Quoted text contains the row delimiter (TRUE or FALSE)

-locale Default locale

-codePage Default code page

If no options are provided as parameters, the default delimiters are:

Delimiter Character

Column delimiter ,

Row delimiter \n (UNIX)

\r\n (Windows)

Escape character \

Quote escape character "

Default text quotes "

 Note

Only one format of each type (date, time, second date) is allowed per file. If you have two columns
containing different formatted dates in it, only the first one is recognized. The second is Varchar.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 213
Example

Run this tool to generate a configuration file named call_center.dat that has ';' as a column delimiter and
'\n' as a row delimiter:

createfileformat.sh -file C:\usr\sap\dataprovagent\sasi\FileServer


\call_center.dat
-cfgdir C:\usr\sap\dataprovagent\sasi\FileDefinitions -colDelimiter ; -
rowDelimiter \n

6.9.3.4 Generate the Configuration File When Creating a


Virtual Table

You can generate a CFG file when you create a virtual table using SQL.

A convenient way to generate the necessary configuration file is to do so when creating a virtual table using
SQL. By including the appropriate parameters in the SQL, a CFG file is generated and inserted into the
appropriate directory that you specified when creating the File adapter remote source.

For example, the following sample code generates a file named v_plan_2.cfg that is created in the file format
directory.

create virtual table v_plan2 at "fileAdapter"."<NULL>"."<NULL>"."v_plan_2"


REMOTE PROPERTY 'dataprovisioning_parameters'=
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Parameters>
<Parameter name="COMMENT">First line must be a comment</Parameter>
<Parameter name="FORCE_FILENAME_PATTERN">fixed%.txt</Parameter>
<Parameter name="FORCE_DIRECTORY_PATTERN"></Parameter>
<Parameter name="FORMAT">FIXED</Parameter>
<Parameter name="CODEPAGE">UTF-8</Parameter>
<Parameter name="ROW_DELIMITER">\n</Parameter>
<Parameter name="SKIP_HEADER_LINES">1</Parameter>
<Parameter name="COLUMNSSTARTENDPOSITION">0-1;2-7;8-15</Parameter>
<Parameter name="ROWLENGTH">16</Parameter>
<Parameter name="COLUMN">COL1;VARCHAR(2)</Parameter>
<Parameter name="COLUMN">COL2;VARCHAR(6)</Parameter>
<Parameter name="COLUMN">COL3;VARCHAR(8)</Parameter>
</Parameters>';

Related Information

File Adapter Remote Source Configuration [page 190]


Format Parameters [page 201]

Installation and Configuration Guide


214 PUBLIC Configure Data Provisioning Adapters
6.9.4 Remote Source Tables

The remote source provides tables that reflect the content of the CFG files, and they can be imported as virtual
tables.

After a remote source is created, you can browse the remote source. Each of the configured CFG files is shown
as a remote table under the remote source and can be imported as a virtual table. The following tables are
always included:

Table Description

CODEPAGES Use this table to retrieve all supported code pages of the Java installation and optionally
specify one in the various file format configuration files. The code page controls the char­
acter encodings of the source files.

FILECONTENT This virtual table has one row per file and the entire file content is inside a BLOB column.
Use this table for unstructured data files.

FILECONTENTROWS Similar to FILECONTENT, this table returns the data as is, without any conversion, but
splits the file into rows at every <newline> character.

FILECONTENTROWSTEXT Similar to FILECONTENTROWS, this table also uses a character buffer for improved per­
formance when handling lines with a length less than or equal to MAX_CLOB_IN­
LINE_LOB_LENGTH(43690).

For lines with a greater length, this table behaves the same as FILECONTENTROWS.

FILECONTENTTEXT This virtual table has one row per file, and the entire file content is inside an NCLOB col­
umn. Use this table for unstructured data files. In case the file has no ByteOrderMark
(BoM) header to identify the code page, or the operating system default code page is not
the proper one, you can supply the reader option CODEPAGE.

FILEDIRECTORY Returns a list of all files in the remote source configured root directory and its subdirecto­
ries.

LOCALES This table returns all supported Java locales, and the values can be used to control the lo­
cale of the file read, which impacts the decimal format, the month names of a date format,
and so on.

STATISTICS_CHAR Calculates the number of occurrences of each character in the files. Characters that occur
often usually are column delimiters, optional text quotes, and row delimiter characters.

6.9.5 Connect to a SharePoint Remote Source

Information about retrieving source data from a SharePoint server.

Procedure

1. Configure the remote source, making sure that you set the appropriate parameters.

At a minimum, you will need to configure the following remote source parameters, :

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 215
Parameter Comment

Source Options

Target Options

Root Directory

Directory of the file format definitions

Server URL SharePoint server URL

Local Folder Path The download folder path. This folder will be created un­
der the <DPAgent_root>/ directory automatically.
The local folder path is the location on the Data Provision­
ing Agent machine local drive where you want to place
your source data files that the Data Provisioning Agent will
download from the SharePoint server.

See the remote source configuration topic for more information about these parameters.

2. Replicate data from, for example, the following SharePoint server URL: http://<host name>/
sharepoint_site1/SharedDocuments/myCSVfile.txt.
3. In the local CFG file, add the following:

FORCE_FILENAME_PATTERN=myCSVfile.txt
FORCE_DIRECTORY_PATTERN=<root directory>\download\sharepoint\SharedDocuments

Results

Data Provisioning Agent will download myCSVfile.txt from the SharePoint Server URL SharedDocuments
folder and store the file locally in <root directory>\download\sharepoint\SharedDocuments.

 Note

When you execute a query, the Data Provisioning Agent downloads the file and places it in the download
folder. If you execute the same query to obtain the same file, the system downloads the file again and
replaces the existing file in the download folder.

Related Information

File Adapter Remote Source Configuration [page 190]

Installation and Configuration Guide


216 PUBLIC Configure Data Provisioning Adapters
6.9.6 Access SharePoint Using HTTPS/SSL

Information about how to access SharePoint using HTTPS/SSL.

Context

You can access the SharePoint server using HTTPS or SSL. You first must download the SharePoint certificate
(CER) and configure your system.

Procedure

1. Navigate to <DPAgent_root>/ssl folder.


2. Run the command to change the default keystore password changeit.

c:\<user>\dpagent\ssl>keytool -storepasswd -keystore cacerts


Enter keystore password:changeit
New keystore password:
Re-enter new keystore password:

 Note

Keytool is in the jre/bin folder. Add it to the $PATH environment. For example, C:\Program Files
\Java\jre7\bin\keytool.exe

3. Import the certificate that you exported.

c:\<user>\dpagent\ssl>keytool.exe -importcert -keystore c:\user\dpagent\ssl


\cacerts
-storepass <New Key Store Password> -file C:\<user>\dpagent\ssl
\SharePointSSL.cer
Owner: CN=RQA16CWIN2.sjc.sap.corp
Issuer: CN=RQA16CWIN2.sjc.sap.corp
Serial number: 34973632d6cb31934fdfbe04352cc5dc
Valid from: Thu Jan 05 01:29:45 PST 2017 until: Thu Jan 04 16:00:00 PST 2018
Certificate fingerprints:
MD5: 0C:7E:CA:38:1B:1E:2A:2A:47:21:78:86:50:1C:85:CE
SHA1: 25:CE:CF:F8:9A:2C:70:0A:66:CD:39:D5:C5:EC:10:4D:57:42:28:0B
SHA256: 40:80:A0:E1:56:1A:9A:F4:9F:63:20:37:F3:41:B0:27:B6:1F:9C:
33:3C:
0A:E8:79:0B:91:7E:E6:6B:E8:08:3A
Signature algorithm name: SHA1withRSA
Version: 3
Extensions:
#1: ObjectId: 2.5.29.37 Criticality=false
ExtendedKeyUsages [
serverAuth
]
#2: ObjectId: 2.5.29.15 Criticality=false
KeyUsage [
Key_Encipherment
Data_Encipherment
]
Trust this certificate? [no]: yes

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 217
Certificate was added to keystore

4. Open the dpagentconfig tool in <DPAgent>_root/configTool/dpagentconfigtool.exe. Click


Configure SSL and input the keystore file path and password that you used in the previous step.
5. If you are not using the TCP SSL connection between SAP HANA and the DP Agent, clear the Use SSL to
communicate with HANA on Cloud and Enable SSL for Agent to HANA communication on TCP parameters.
6. Open <DPAgent_root>/dpagent.ini, and add the following configuration:

-Djavax.net.ssl.trustStore=<keystore file path>

For example: -Djavax.net.ssl.trustStore=C:\<user>\dpagent\ssl\cacerts


7. Restart the DP Agent.

6.9.7 Accessing Files On a Shared Network

Information about how to use a shared network directory for data files with the File adapter.

You can access data and format files in a shared directory if you follow these guidelines:

Windows

When using Windows, make sure that you manually access the network folder first using a user name and
password before you try to connect by creating a remote source.

Linux

To access a Linux network folder, mount the folder under the Data Provisioning Agent root installation
directory.

File Adapter Remote Source Parameters

Observe the instructions for the Root Directory and Directory of the file format definitions parameters when
creating your File remote source.

Related Information

File Adapter Remote Source Configuration [page 190]

Installation and Configuration Guide


218 PUBLIC Configure Data Provisioning Adapters
6.9.8 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 219
Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.9.9 Register an Application on Microsoft Azure Portal to


Enable Access to SharePoint on Microsoft Office365

You must register an application on Microsoft Azure Portal as a precondition for using the Microsoft Graph API,
which is what allows you to access SharePoint on Office365 using the File or Microsoft Excel adapters.

Procedure

1. Go to https://portal.azure.com and sign in with your Microsoft account.


2. Navigate to Azure Active Directory, and click App registrations.
3. Click New registration.
4. Choose a name for your Data Provisioning Agent--for example, sdi-dpagent--to use as the name for your
application.
5. Choose the proper Supported account types: either Account in this organizational directory only or
Accounts in any organizational directory.
6. Leave Redirect URL empty, and click Register.

Next Steps

After registration, note the application (client) ID and Directory (tenant) ID, which you use during remote
source configuration.

Related Information

File Adapter Remote Source Configuration [page 190]


Configure Your Microsoft Azure Application [page 221]

Installation and Configuration Guide


220 PUBLIC Configure Data Provisioning Adapters
6.9.10 Configure Your Microsoft Azure Application

Configure your Azure application to set up your credentials and Microsoft Graph API.

Context

Further configuration of your Azure application is necessary to create credentials for when you create a remote
source. You must also grant permissions for using the Microsoft Graph API.

Procedure

1. Click Authentication to configure the client type.

If you want to authenticate using the username and password mode, set the Default client type to Yes.

If you want to authenticate the Client Credential mode, set the Default client type to No.

a. If you chose to authenticate using Client Credential mode, create a credential by clicking Certificates &
secrets. If you chose to authenticate using the username and password mode, skip to step 2.
b. Click New client secret, give it a name and an expiration time, and click Add.
c. Note the secret password for use during remote source creation.
2. Add permissions by clicking API permissions on the application page, and then clicking Add a permission.
3. Click Microsoft Graph.
4. If you use the Client Credential mode, click Application Permission. If you use the Username and password
mode, click Delegated permission.
5. Add the following permissions:
○ Directory.Read.All
○ Files.Read.All
○ Group.Read.All
○ Sites.Read.All
○ User.Read.All
6. Grant consent for these permissions.
If you have and administrator role, click Grant consent.

If you do not have an administrator role, ask your administrator to grant permission for you.

 Note

If permissions are not granted, you will not be able to access SharePoint Office365.

Every time a permission is changed, you should redo the grant operations.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 221
Next Steps

You can now create your remote source, using the information created while setting up your Microsoft Azure
Portal application.

Related Information

File Adapter Remote Source Configuration [page 190]


Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft Office365 [page
220]

6.10 File Datastore Adapters

Use the File Datastore adapters to read text files.

File Datastore adapters leverage the SAP Data Services engine as the underlying technology to read from a
wide variety of file sources. SAP Data Services uses the concept of datastore as a connection to a source.
These adapters provide features including:

● Auto-detect file formats


● Route rows that failed to be read to another file
● Read CFG files from SFTP sources
● Automatic CFG file generation via virtual procedure or data file importation

The file datastore adapters include:

● FileAdapterDatastore
● SFTPAdapterDatastore

Adapter Functionality

Datastore adapters support the following functionality:

● Virtual table as a source


● SELECT, WHERE, TOP, or LIMIT

Related Information

Authorizations [page 223]


Configuring Access to Your Data and Configuration Files [page 223]

Installation and Configuration Guide


222 PUBLIC Configure Data Provisioning Adapters
File Format Configuration Files [page 224]
Format Parameters for File Datastore Adapters [page 226]
Virtual Procedures [page 230]
FileAdapterDatastore [page 236]
SFTPAdapterDatastore [page 240]
File [page 187]

6.10.1 Authorizations

Authorization requirements for accessing remote sources with a File Datastore Adapter.

Keep the following in mind when accessing files:

● Ensure the user account under which the Data Provisioning Agent is running has access to the files on the
local host.
● If the files are located on the same host as the Data Provisioning Agent, the files must be located in the
same directory or in a subdirectory of the Data Provisioning Agent root directory.

6.10.2 Configuring Access to Your Data and Configuration


Files

How the File Datastore Adapter locates data files and configuration files.

By default, the adapter has access to the <DPAgent_root>/workspace directory. To enable browsing your
files, you can either put your data and configuration files in the default workspace directory, or you can
configure the location of the files in dpagentconfig.ini. For example, add the following to the
<DPAgent_root>/dpagentconfig.ini file:

#Number of paths that could be browsed in SAP HANA via this adapter
dsadapter.fileadapter.dirCount=2
dsadapter.fileadapter.dir1=C\:\\TEST1\\UAT
dsadapter.fileadapter.dir2=C\:\\TEST2\\QA

Then, browse to your data file and right-click to add it as virtual table. The adapter creates a corresponding
configuration file in the same folder. For example, when you add employee.csv to SAP HANA, the adapter
creates an employee.cfg file in the same folder.

Alternately, you can create your own configuration files through virtual procedures or create them manually:

● To use the Create Configuration File virtual procedure, in the SAP HANA Web Development Workbench:
Catalog, navigate to Provisioning Remote Sources <remote_source> File Operations CFG
Utilities . Right-click Create Configuration File and Add as Virtual Procedure.
● To create the configuration files manually, execute CREATE VIRTUAL PROCEDURE SQL.

You can then use the virtual table in a flowgraph or SQL execution.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 223
Related Information

Virtual Procedures [page 230]


Virtual Procedure: Create Configuration File [page 233]

6.10.3 File Format Configuration Files

Create a file format configuration file to work with your data file (File Datastore adapters).

Each configuration file is a text file and must match the following format:

● The first line must contain a comment or a description. This line is ignored during processing.
● A set of key-value pairs to specify the various parsing options
● A set of COLUMN=<name>;<SAP HANA datatype>;<optional description>;<optional date
type format>;<optional column width>
The date type format is necessary only if the SAP HANA data type of this column is date-related. Column
width is necessary only if the data file is a fixed-format file.

Example

File format to read US census data, see https://www.census.gov/econ/cbp/download/


FORMAT=CSV
FORCE_FILENAME_PATTERN=us_county_census_%.txt
FORCE_DIRECTORY_PATTERN=
CODEPAGE=
LOCALE=
COLUMN_DELIMITER=,
ROW_DELIMITER=\r\n
ESCAPE_CHAR=
TEXT_QUOTES="
TEXT_QUOTES_ESCAPE_CHAR=
SKIP_HEADER_LINES=1
QUOTED_TEXT_CONTAIN_ROW_DELIMITER=false
DATEFORMAT=yyyy.MM.dd HH:mm:ss
COLUMN=FIPSTATE;VARCHAR(2);FIPS State Code
COLUMN=EMP;INTEGER;Total Mid-March Employees with Noise
COLUMN=QP1_NF;VARCHAR(1);Total First Quarter Payroll Noise Flag
COLUMN=CENSTATE;VARCHAR(2);Census State Code
COLUMN=CENCTY;VARCHAR(3);Census County Code
COLUMN=CENTIME;TIMESTAMP;Payroll Time; yyyy.MM.dd HH:mm:ss
COLUMN=PARTITION
COLUMNSTARTENDPOSITION=

Fixed-Format Files

Fixed file formats where FORMAT=fixed are supported. You can specify the formatting using the <optional
column width> parameter. For example, in COLUMN=COL3;VARCHAR(8);Description;;8, the last column
value of 8 indicates the width.

Installation and Configuration Guide


224 PUBLIC Configure Data Provisioning Adapters
Example

Fixed file format


FORMAT=FIXED
FORCE_FILENAME_PATTERN=fixed%.txt
CODEPAGE=UTF-8
LOCALE=
ROW_DELIMITER=\r\n
SKIP_HEADER_LINES=1
COLUMN=COL1;VARCHAR(2);Description;;2
COLUMN=COL2;VARCHAR(6);Description;;6
COLUMN=COL3;VARCHAR(8);Description;;8

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 225
6.10.4 Format Parameters for File Datastore Adapters

File format parameter descriptions for File Datastore adapters.

Global

Parameter Description and Examples

FORCE_FILENAME_PATTERN You might want to execute a simple select * from <virtualtable>


without a WHERE clause on a directory. In that case, every file in the root directory
FORCE_DIRECTORY_PATTERN
and subdirectories is read and parsed according to this virtual table's format defi-
nitions. That process could take a long time and produce errors. However, if the
virtual table maps to files in a particular directory, directory tree, or to particular
file names only, you can specify this information in the virtual table directly. For ex­
ample:

● To read all files in that directory only:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata

● To read all files in that directory and subdirectories:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata/%

● To read all files in directories that start with “plan”:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plan%:

● To read files like plan20120101.txt:

FORCE_FILENAME_PATTERN=plan%.txt

● To read files inside the directory and matching the provided name pattern:

FORCE_DIRECTORY_PATTERN=/usr/sap/FileAdapter/
FileServer/plandata
FORCE_FILENAME_PATTERN=plan%.txt

FORMAT CSV is required for CSV files.

CODEPAGE The character encoding with which to read the file. By default, the operating sys­
tem default is used. If the file has a Byte Order Mark, this codepage is used. Valid
values of the Java installation can be found by creating a virtual table for CODE­
PAGE and querying its contents.

Installation and Configuration Guide


226 PUBLIC Configure Data Provisioning Adapters
Parameter Description and Examples

ROW_DELIMITER A character sequence indicating the end of a row in the file. If these sequences are
nonprintable characters, they can be provided encoded as /d65536 or /xFFFF or
as Unicode notation /u+FFFF. Alternatively, the typical \r and \n are supported as
well. Examples:

● \n UNIX standard
● \r\n Windows standard
● \d13\d10 Windows standard, but characters are provided as a decimal num­
ber
● \x0D\x0A Windows standard, but characters are provided as a hex number

SKIP_HEADER_LINES If the file has a header, enter the number of lines to skip.

ERROR_ON_COLUMNCOUNT By default, a row with fewer columns than defined is considered acceptable. Set­
ting this parameter to true indicates that all rows of the file have as many columns
as defined.

LOCALE The decimal and date conversion from the strings in the file into native numbers or
dates might be locale-specific. For example, if you have the date “14. Oktober
2000”, and you are using a German locale, it works. However, for all other lan­
guages, it does not work.

Valid values for the locale can be found by querying a virtual table based on the
LOCALE table of the adapter.

COLUMN ultiple entries consist of the columnname;datatype, where the datatype is


any SAP HANA data type.

NULL_INDICATOR Specifies a character sequence to indicate to the software thatthe data is NULL.

 Note
The software ignores NULL indicators specified in the file format for blob col­
umns.

IGNORE_ROW_MARKERS Specifies a character sequence that appears at the beginning of specific rows.
When the software reads the file, or when it automatically creates metadata, and it
encounters the row markers, it ignores the row and moves to the next row.

DATEFORMAT Specifies the date format for reading and writing date values to and from the file.

TIMEFORMAT Specifies the time format for reading and writing time values to and from the file.

SECONDDATEFORMAT Specifies the date/time format for reading or writing date/time values to and from
the file.

BOF Specifies a string that marks the start of data in the file.

EOF Specifies the string that marks the end of data in the file.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 227
Parameter Description and Examples

EXPONENTIAL Defines the exponential character used for decimal numbers.

For example, e for 1.05097214923805e-06 or E for


1.05097214923805E-06.

Default: E

LENIENT Controls automatic date and time format conversion when the value exceeds the
range.

For example, when this parameter is set to True, the 14th month of 2016 is con­
verted to the second month of 2017.

CSV only

Parameter Description and Examples

COLUMN_DELIMITER The character sequence indicating the next column. If nonprintable characters
are used, then any of the following encodings works: \d65536, \xFFFF, or \u
+FFFF.

● ; A semicolon is the column separator. For example, 2000;IT Costs;


435.55
● | uses the pipe character as a delimiter.
● \d09 uses an ASCII tab character as a delimiter.

TEXT_QUOTES Sometimes text data is enclosed in quotes so a column delimiter inside the text
does not break the format. The line 2000;IT Costs; software
related only;435.55 would appear as four columns because the text
contains a semicolon as well. If the file was created with quotes such as
2000;"IT Costs; software related only";435.55, then there
is no such issue. However, the file parser must not just search for the next col­
umn delimiter, it also must check if the text is inside or outside of the text
quote character.

ESCAPE_CHAR Another way to deal with inline special characters is to escape them. For exam­
ple, 2000;IT Costs\; software related only;435.55. Here
the \ character is an escape character and indicates that the subsequent char­
acter is to be taken literally and not as a column delimiter.

Installation and Configuration Guide


228 PUBLIC Configure Data Provisioning Adapters
Parameter Description and Examples

TEXT_QUOTES_ESCAPE_CHAR You can make quotes appear inside the text. For example, IT Costs;
"software related" only. One option the file creator might have used
is to use the global escape character 2000;"IT Costs; \"software
related\" only";435.55. Another popular method is to have the
quotes escaped by another quote; for example, 2000;"IT Costs;
""software related"" only";435.55. In that case, both the
TEXT_QUOTE=" and the TEXT_QUOTE_ESCAPE_CHAR=" are set to the "
character.

QUOTED_TEXT_CONTAIN_ROW_DELIM­ The default value is false and tells the parser regardless of any quotes or es­
ITER cape characters that the text inside a row never contains the row delimiter
character sequence. In this case, the parser can break the file into rows much
faster; it must search for the character sequence only, and only the column
parsing has to consider the escape and quote characters. If set to true, parsing
becomes slower.

Fixed-Width only

Parameter Description and Examples

COLUMNSSTARTENDPOSI­ In a fixed-width file, the column positions must be specified for each column. Examples:
TION
● 0-3;4-11;12-37;38-53 defines that the first 4 characters are the first column, the next 8
contain the data for the second column, and so on. Columns must be in the proper or­
der.
● 0;4;12;38 is equivalent to the previous example, but the last column ends with the line
end
● 0;4;12;38-53 can be used as well. In fact, for every column you can either specify the
start and end position or just the start.

ROWLENGTH In fixed-width files, there does not need to be a row delimiter. Often the file has some and
then they must be stripped away. The following examples assume that the last data charac­
ter is at index 53 as specified the COLUMNSTARTENDPOSITION example.

● ROWLENGTH=56 ROW_DELIMITER= would work for a file that has a row delimiter. The
payload text ranges from 0..53; therefore, it is 54 characters long plus two characters
for \r\n. The last column does not contain the \r\n because it is instructed to end at
index 53.
● ROWLENGTH=54 ROW_DELIMITER=\r\n is equivalent to the previous example. Each
row is expected to be 54 characters plus 2 characters long. The main advantage of this
notation is that COLUMNSSTARTENDPOSITION=0;4;12;38 would work and the trailing
\r\n is stripped away. In the previous example, the last column would start at 38 and
end at index 55 due to rowlength=56 and therefore contain the \r\n characters in the
last column.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 229
Related Information

Configuring Access to Your Data and Configuration Files [page 223]

6.10.5 Virtual Procedures

Use the provided utility virtual procedures to alter, create, delete, or view configuration files.

First use auto-detect to identify the delimiters and metadata, then use these virtual procedures to alter a file
source to your requirements.

To create a virtual procedure, in the SAP HANA Web Development Workbench: Catalog, navigate to
Provisioning Remote Sources <remote_source> File Operations CFG Utilities . Right-click the
utility and select Add as Virtual Procedure.

Related Information

Virtual Procedure: Alter Configuration File Property [page 230]


Virtual Procedure: Alter File Field [page 232]
Virtual Procedure: Create Configuration File [page 233]
Virtual Procedure: Delete Configuration File [page 235]
Virtual Procedure: View Configuration File [page 235]

6.10.5.1 Virtual Procedure: Alter Configuration File Property

Use the Alter Configuration File Property virtual procedure to change values in a CFG file property.

You can alter the following values in a CFG file property:

INOUT Parameter Type Description

IN ConfigFilePath NVARCHAR Full path to the CFG file

IN ParameterName NVARCHAR Name of the CFG file format


parameter

IN ParameterValue NVARCHAR Value of the CFG file format


parameter

OUT StatusTable TABLE Table describing the proce­


dure call status

Installation and Configuration Guide


230 PUBLIC Configure Data Provisioning Adapters
Creating the virtual procedure via SQL statement

CREATE VIRTUAL PROCEDURE "SYSTEM"."Alter_Configuration_File_Property"(


IN ConfigFilePath NVARCHAR(512),
IN ParameterName VARCHAR(1024),
IN ParameterValue VARCHAR(1024),
OUT param_3 TABLE (Status TINYINT,Message VARCHAR(1024))) CONFIGURATION '{
"__DP_UNIQUE_NAME__": "FileAdapter.Procedures.ConfigUtil.ALTER_SINGLE_CONFIG",
"__DP_HAS_NESTED_PARAMETERS__": false,
"__DP_USER_DEFINED_PROPERTIES__": {
"dsadapter.fileadapter.procedure.ConfigProcedure$ConfigProcedureType":
"ALTER_SINGLE_CONFIG",
"isProcCallOnCFGFile": "false"
},
"__DP_INPUT_PARAMETER_PROPERTIES_": [],
"__DP_RETURN_PARAMETER_PROPERTIES_": [],
"__DP_VIRTUAL_PROCEDURE__": true,
"__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false,
"__DP_DEFAULT_OUTPUT_PARAMETER_INDEX__": 0
}' AT "{remote_source_name}";

Example

Suppose that you have a file on C:\usr\sap\dataprovagent\workspace\sample_data.csv where the


content is in the following format. You want to point the configuration to prod_data.csv instead of
sample_data.csv so you can test with the sample file and load the production file during execution.

Item_ID,Item_Price,Item_Description,Date_Added
101,99.99,Item1,2016-10-11

The CFG file:

#FileFormat created by virtual procedures


COLUMN_DELIMITER=,
ERROR_ON_COLUMNCOUNT=false
FORCE_DIRECTORY_PATTERN=C:\usr\sap\dataprovagent\workspace
FORCE_FILENAME_PATTERN=sample_data.csv
FORMAT=CSV
ROW_DELIMITER=\r\n
SKIP_HEADER_LINES=1
COLUMN=Item_ID;INTEGER;
COLUMN=Item_Price;DOUBLE;
COLUMN=Item_Description;VARCHAR(256);
COLUMN=Date_Added;DATE;SomeDateColumn;yyyy-MM-dd;0

Use the procedure to update FORCE_FILENAME_PATTERN to use prod_data.csv:

--Alter second column properties


call "SYSTEM"."Alter_Configuration_File_Property"('C:\usr\sap\dataprovagent
\workspace\item.cfg','FORCE_FILENAME_PATTERN','prod_data.csv',?);
--Check if updated correctly
call "SYSTEM"."View_Configuration_File"('C:\usr\sap\dataprovagent\workspace
\item.cfg',?,?);

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 231
6.10.5.2 Virtual Procedure: Alter File Field

Alter column metadata using a virtual procedure.

The Alter File Field virtual procedure allows you to change the column metadata for a given file field. You can
alter data types, length, format, and so on.

INOUT Parameter Type Description

IN ConfigFilePath NVARCHAR Full path to the CFG file

IN ColumnIndex INTEGER Index of the column; starts


with 0

IN ColumnName NVARCHAR Column name

IN DataType Column data type

IN LengthOrPrecision INTEGER Length or precision

IN Scale INTEGER Column scale

IN Description NVARCHAR Column description

IN Format NVARCHAR Column date/time format

IN ColumnWidth INTEGER Column width for fixed-width


format

OUT StatusTable TABLE Table describing the proce­


dure call status

Creating the virtual procedure via SQL statement

CREATE VIRTUAL PROCEDURE "SYSTEM"."Alter_File_Field"(


IN ConfigFilePath NVARCHAR(512),
IN ColumnIndex INTEGER,
IN ColumnName VARCHAR(1024),
IN DataType VARCHAR(32),
IN LengthOrPrecision INTEGER,
IN Scale INTEGER,
IN Description NVARCHAR(1024),
IN Format VARCHAR(32),
IN ColumnWidth INTEGER,
OUT param_9 TABLE (Status TINYINT,Message VARCHAR(1024))) CONFIGURATION '{
"__DP_UNIQUE_NAME__": "FileAdapter.Procedures.ConfigUtil.ALTER_SINGLE_COLUMN",
"__DP_HAS_NESTED_PARAMETERS__": false,
"__DP_USER_DEFINED_PROPERTIES__": {
"dsadapter.fileadapter.procedure.ConfigProcedure$ConfigProcedureType":
"ALTER_SINGLE_COLUMN",
"isProcCallOnCFGFile": "false"
},
"__DP_INPUT_PARAMETER_PROPERTIES_": [],
"__DP_RETURN_PARAMETER_PROPERTIES_": [],
"__DP_VIRTUAL_PROCEDURE__": true,
"__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false,
"__DP_DEFAULT_OUTPUT_PARAMETER_INDEX__": 0
}' AT "{remote_source_name}";

Installation and Configuration Guide


232 PUBLIC Configure Data Provisioning Adapters
Example

Suppose that you have a file in C:\usr\sap\dataprovagent\workspace\items.csv where the content is


in the following format and you want to change the data type and column name:

Item_ID,Item_Price,Item_Description,Date_Added
101,99.99,Item1,2016-10-11

The CFG file:

#FileFormat created by virtual procedures


COLUMN_DELIMITER=,
ERROR_ON_COLUMNCOUNT=false
FORCE_DIRECTORY_PATTERN=C:\usr\sap\dataprovagent\workspace
FORCE_FILENAME_PATTERN=item.csv
FORMAT=CSV
ROW_DELIMITER=\r\n
SKIP_HEADER_LINES=1
COLUMN=Item_ID;INTEGER;
COLUMN=Item_Price;DOUBLE;
COLUMN=Item_Description;VARCHAR(256);
COLUMN=Date_Added;DATE;SomeDateColumn;yyyy-MM-dd;0

Use the virtual procedure to update the second column Item_Price to be Price and DECIMAL(10,5).

--Alter second column properties


CALL "SYSTEM"."Alter_File_Field"('C:\usr\sap\dataprovagent\workspace\item.cfg',
1,'Price','DECIMAL',10,5,'Price Filed',null,null,?);
--Check if updated correctly
call "SYSTEM"."View_Configuration_File"('C:\usr\sap\dataprovagent\workspace
\item.cfg',?,?);

6.10.5.3 Virtual Procedure: Create Configuration File

Create Configuration File allows you to create a CFG file under available root folders using SAP HANA tables.

INOUT Parameter Type Description

IN ConfigFilePath NVARCHAR Full path to the CFG file

IN ConfigTable TABLE Table describing delimiters


and other file format configu-
ration

IN MetadataTable TABLE Table describing file field in


metadata format

IN VerifyConfiguration VARCHAR True or false to verify the CFG


content

OUT StatusTable TABLE Table describing the proce­


dure call status

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 233
Creating the virtual procedure via SQL statement

CREATE VIRTUAL PROCEDURE "SYSTEM"."Create_Configuration_File"(


IN ConfigFilePath NVARCHAR(512),
IN ConfigTable TABLE (ParameterName VARCHAR(1024),ParameterValue VARCHAR(1024)),
IN MetadataTable TABLE (ColumnName NVARCHAR(1024),DataType
VARCHAR(32),LengthOrPrecision INTEGER,Scale INTEGER,Description
NVARCHAR(1024),Format VARCHAR(32),ColumnWidth INTEGER),
IN VerifyConfiguration VARCHAR(4),
OUT StatusTable TABLE (Status TINYINT,Message VARCHAR(1024))) CONFIGURATION '{
"__DP_UNIQUE_NAME__": "FileAdapter.Procedures.ConfigUtil.CREATE_CONFIG",
"__DP_USER_DEFINED_PROPERTIES__": {
"dsadapter.fileadapter.procedure.ConfigProcedure$ConfigProcedureType":
"CREATE_CONFIG",
"isProcCallOnCFGFile": "false"
},
"__DP_VIRTUAL_PROCEDURE__": true,
"__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false
}' AT "{remote_source_name}";

Example

Suppose that you have a file on C:\usr\sap\dataprovagent\workspace\items.csv where the content is


in the following format:

Item_ID,Item_Price,Item_Description,Date_Added
101,99.99,Item1,2016-10-11

--Sample SQL to create the configuration file


--Create the input table that you will need to provide to the procedure.
drop table SYSTEM.filefields;
create table SYSTEM.filefields (COLUMNNAME NVARCHAR(512), DATATYPE
VARCHAR(32),LENGTHORPRECISION INT, SCALE INT, DESCRIPTION NVARCHAR(512), FORMAT
NVARCHAR(512), COLUMNWIDTH INT);
truncate table SYSTEM.filefields;
insert into SYSTEM.filefields values('Item_ID','INTEGER',0,0,NULL,NULL,0);
insert into SYSTEM.filefields values('Item_Price','DOUBLE',0,0,NULL,NULL,0);
insert into SYSTEM.filefields values('Item_Description','VARCHAR',
256,0,NULL,NULL,0);
insert into SYSTEM.filefields values('Date_Added','DATE',
0,0,'SomeDateColumn','yyyy-MM-dd',0);
select * from SYSTEM.filefields;
drop table SYSTEM.config;
create table SYSTEM.config (parametername varchar(512), parametervalue
varchar(512));
truncate table SYSTEM.config;
insert into SYSTEM.config values('SKIP_HEADER_LINES','1');
insert into SYSTEM.config values('ROW_DELIMITER','\r\n');
insert into SYSTEM.config values('COLUMN_DELIMITER',',');
insert into SYSTEM.config values('FORCE_DIRECTORY_PATTERN','C:\usr\sap
\dataprovagent\workspace');
insert into SYSTEM.config values('FORCE_FILENAME_PATTERN','item.csv');
--Call the procedure to create a CFG file based on this configuration.
call "SYSTEM"."Create_Configuration_File"('C:\usr\sap\dataprovagent\workspace
\item.cfg',SYSTEM.config,SYSTEM.filefields,'true',?);
--Now you can import this cfg and read form the file.

Installation and Configuration Guide


234 PUBLIC Configure Data Provisioning Adapters
6.10.5.4 Virtual Procedure: Delete Configuration File

Delete a configuration file.

Deletes the given configuration file using the Delete Configuration File virtual procedure.

INOUT Parameter Type Description

IN ConfigFilePath NVARCHAR Full path to the CFG file

OUT StatusTable TABLE Table describing the proce­


dure call status

Creating the virtual procedure via SQL statement

CREATE VIRTUAL PROCEDURE "SYSTEM"."Delete_Configuration_File"(


IN ConfigFilePath NVARCHAR(512),
OUT param_1 TABLE (Status TINYINT,Message VARCHAR(1024))) CONFIGURATION '{
"__DP_UNIQUE_NAME__": "FileAdapter.Procedures.ConfigUtil.DELETE_CONFIG",
"__DP_HAS_NESTED_PARAMETERS__": false,
"__DP_USER_DEFINED_PROPERTIES__": {
"dsadapter.fileadapter.procedure.ConfigProcedure$ConfigProcedureType":
"DELETE_CONFIG",
"isProcCallOnCFGFile": "false"
},
"__DP_INPUT_PARAMETER_PROPERTIES_": [],
"__DP_RETURN_PARAMETER_PROPERTIES_": [],
"__DP_VIRTUAL_PROCEDURE__": true,
"__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false,
"__DP_DEFAULT_OUTPUT_PARAMETER_INDEX__": 0
}' AT "{remote_source_name}";

Usage

Suppose you have a file on C:\usr\sap\dataprovagent\workspace\items.cfg :

--Call the procedure to delete this CFG file


call "SYSTEM"."Delete_Configuration_File"('C:\usr\sap\dataprovagent\workspace
\item.cfg',?);

6.10.5.5 Virtual Procedure: View Configuration File

View an existing CFG file.

The View Configuration File virtual procedure allows you to view an existing CFG file under available root
folders.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 235
INOUT Parameter Type Description

IN ConfigFilePath NVARCHAR Full path to the CFG file

OUT ConfigTable TABLE Table describing delimiters


and other file format configu-
ration

OUT MetadataTable TABLE Table describing file field in


SAP HANA smart data
integration metadata format

Creating the virtual procedure via SQL statement

CREATE VIRTUAL PROCEDURE "SYSTEM"."View_Configuration_File"(


IN ConfigFilePath NVARCHAR(512),
OUT param_1 TABLE (ParameterName VARCHAR(1024),ParameterValue VARCHAR(1024)),
OUT param_2 TABLE (ColumnName NVARCHAR(1024),DataType
VARCHAR(32),LengthOrPrecision
INTEGER,Scale INTEGER,Description NVARCHAR(1024),Format VARCHAR(32),ColumnWidth
INTEGER))
CONFIGURATION '{
"__DP_UNIQUE_NAME__": "FileAdapter.Procedures.ConfigUtil.VIEW_CONFIG",
"__DP_HAS_NESTED_PARAMETERS__": false,
"__DP_USER_DEFINED_PROPERTIES__": {
"dsadapter.fileadapter.procedure.ConfigProcedure$ConfigProcedureType":
"VIEW_CONFIG",
"isProcCallOnCFGFile": "false"
},
"__DP_INPUT_PARAMETER_PROPERTIES_": [],
"__DP_RETURN_PARAMETER_PROPERTIES_": [],
"__DP_VIRTUAL_PROCEDURE__": true,
"__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false,
"__DP_DEFAULT_OUTPUT_PARAMETER_INDEX__": 0
}' AT "{remote_source_name}";

Example

Suppose that you have a CFG file in C:\usr\sap\dataprovagent\workspace\items.cfg:

--Call the procedure to get the CFG file


call "SYSTEM"."View_Configuration_File"('C:\usr\sap\dataprovagent\workspace
\item.cfg',?,?);

6.10.6 FileAdapterDatastore

To access file sources, use the FileAdapterDatastore, one of the File Datastore adapters.

Installation and Configuration Guide


236 PUBLIC Configure Data Provisioning Adapters
Related Information

FileAdapterDatastore Remote Source Configuration [page 237]


File [page 187]
SFTPAdapterDatastore [page 240]

6.10.6.1 FileAdapterDatastore Remote Source Configuration

Remote source configuration parameters for the FileAdapterDatastore. Also included is a code sample for
creating a remote source using the SQL console.

Category Option Description

File Format Configuration Format Specifies that the file has a delimiter
character between columns. Flat Files
and Fixed Width Files are supported.

Skip Error Handling Specifies weather to skip the error


handling during processing. Default
value is false.

Error handling Log data conversion warnings Specifies whether to log data
conversion warnings.

Default value is true.

Maximum warnings to log Only available when Skip Error


Handling is enabled (true). Specifies
the maximum number of warnings in
log files.

Capture data conversion errors Specifies whether to capture data


conversion errors in the logs.

Default value is false.

Capture row format errors Specifies whether to capture row


format errors in the logs.

Default value is true.

Capture string truncation errors Specifies whether to capture string


truncation errors in the logs.

Default value is false.

Maximum errors to stop processing Only available when Skip Error


Handling is enabled (true). Specifies
the maximum number of errors
allowed before stopping the process.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 237
Category Option Description

Write error rows to file Specifies whether to write error rows to


an external error file in the Error file
root directory.

Default value is false.

Error file root directory Only available when Write error rows to
file is enabled (true). Full path to the
directory in which to store the error file.

Error file name Only available when Write error rows to


file is enabled (true). Name of the error
file.

Additional Configuration Auto-Detect Columns Specifies whether to detect delimiters


and data types automatically.

 Note
Auto-detect might not match your
data types and delimiters exactly.
If this is the case, you can use the
CFG file utility virtual procedures to
modify the files to your
specifications.

Default value is true.

Data type mapping match percent Used for auto-detection. Given a file
with data:

1. The software analyzes the


probability of possible data types
for each column.
2. The software selects the data type
with the highest probability,
provided that the probability is
greater than or equal to the
specified Data type mapping
match percent.
3. If the calculated probability for the
data type is less than the specified
Data type mapping match percent,
the software sets the data type as
VARCHAR(256).

Default value is 90.

Range is 50 to 100.

Installation and Configuration Guide


238 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Allow CFG file to overwrite Whether changes made to settings in


configuration the configuration file overwrite the
configuration.

Default value is true.

Credentials Credentials Mode Only Technical User is supported.

AccessToken A password. An access token protects


the files from access from different
agents. Use this same password when
creating a remote source. You can
browse and manipulate the
configuration and data files only if the
AccessToken provided in the remote
source configuration matches that set
in Data Provisioning Agent
Configuration Tool.

To create an AccessToken, lauch the


Data Provisioning Agent Configuration
Tool, which is
dpagentconfigtool.exe in the
<DPAgent_root>/configTool
directory. Set the AccessToken value

by navigating to Configure

Adapters FileAdapter .

The following code sample illustrates how to create a remote source using the SQL console:

Example

 Sample Code

CREATE REMOTE SOURCE "FileAdapterDSTest" ADAPTER "FileAdapterDatastore" AT


LOCATION agent "MyAgent"
CONFIGURATION '<?xml version="1.0" encoding="UTF-8"?>
<ConnectionProperties name="configuration">
<PropertyGroup name="fileformatconfiguration">
<PropertyEntry name="format">flatfiles</PropertyEntry>
<PropertyEntry name="errorHandling">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="errorHandlingConfiguration">
<PropertyEntry name="logDataConversionWarnings">true</PropertyEntry>
<PropertyEntry name="maximumWarningsToLog"></PropertyEntry>
<PropertyEntry name="captureDataConversionErrors">false</
PropertyEntry>
<PropertyEntry name="captureRowFormatErrors">true</PropertyEntry>
<PropertyEntry name="captureStringTruncationErrors">false</
PropertyEntry>
<PropertyEntry name="maximumErrosToStopJob"></PropertyEntry>

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 239
<PropertyEntry name="writeErrorRowsToFile">false</PropertyEntry>
<PropertyEntry name="errorFileRootDirectory"></PropertyEntry>
<PropertyEntry name="errorFileName"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="additionalConfiguration">
<PropertyEntry name="autodetect">true</PropertyEntry>
<PropertyEntry name="overwriteConfigByCFG">true</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password><yourAccessToken></password>
</CredentialEntry>';

Related Information

Virtual Procedures [page 230]

6.10.7 SFTPAdapterDatastore

To access SFTP CFG file sources, use the SFTPAdapterDatastore, one of the File Datastore adapters.

Related Information

SFTPAdapterDatastore Remote Source Configuration [page 240]


File [page 187]
FileAdapterDatastore [page 236]

6.10.7.1 SFTPAdapterDatastore Remote Source Configuration

Remote source configuration parameters for the SFTPAdapterDatastore. Also included is a code sample for
creating a remote source using the SQL console.

Category Option Description

File Format Configuration Format Specifies that the file has a delimiter
character between columns. Flat Files
and Fixed Width Files are supported.

Skip Error Handling Specifies whether to skip the error


handling during processing. Default
value is false.

Installation and Configuration Guide


240 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Error handling Log data conversion warnings Specifies whether to log data
conversion warnings.

Default value is true.

Maximum warning to log Only available when Skip Error


Handling is enabled (true). Specifies
the maximum number of warnings in
log files.

Capture data conversion errors Specifies whether to capture data


conversion errors in the logs.

Default value is false.

Capture row format errors Specifies whether to capture row


format errors in the logs.

Default value is true.

Capture string truncation errors Specifies whether to capture string


truncation errors in the logs.

Default value is false.

Maximum errors to stop processing Only available when Skip Error


Handling is enabled (true). Specifies
the maximum number of errors
allowed before stopping the process.

Write error rows to file Specifies whether to write error rows to


an external error file in the Error file
root directory.

Default value is false.

Error file root directory Only available when Write error rows to
file is enabled (true). Full path to the
directory in which to store the error file.

Error file name Only available when Write error rows to


file is enabled (true). Name of the error
file.

SFTP Configuration Host The host name of the SFTP server

Port The port number enabled for the SFTP


connection

Hostkey Fingerprint Used to secure the SFTP connection.


You can generate a hostkey fingerprint

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 241
Category Option Description

for a public key using ssh-keygen, for


example:

ssh-keygen –lf /path/to/


key.pub

Authentication Type Only Password is supported.

Connection Retry Count The maximum number of times to retry


the connection

Connection Retry Interval The time interval for each connection


retry

Remote File Format Directory The directory of the folder on the SFTP
server to browse

Enable Additional Logging Set to True to allow JSch to write its


own logging to framework.trc

Set to False to not print JSch specific


logs to framework.trc

The default value is False.

Credentials Credentials Mode Only Technical User is supported.

AccessToken A password. An access token protects


the files from access from different
agents. Use this same password when
creating a remote source. You can
browse and manipulate the
configuration and data files only if the
AccessToken provided in the remote
source configuration matches that set
in Data Provisioning Agent
Configuration Tool.

To create an AccessToken, lauch the


Data Provisioning Agent Configuration
Tool, which is
dpagentconfigtool.exe in the
<DPAgent_root>/configTool
directory. Set the AccessToken Value

by navigating to Configure

Adapters FileAdapter .

User The user name for the SFTP


connection

Installation and Configuration Guide


242 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Password The password for the corresponding


SFTP user

The following code sample illustrates how to create a remote source using the SQL console.

Example

 Sample Code

CREATE REMOTE SOURCE "SFTPAdapterDSTest" ADAPTER "SFTPAdapterDatastore" AT


LOCATION agent "MyAgent"
CONFIGURATION '<?xml version="1.0" encoding="UTF-8"?>
<ConnectionProperties name="configuration">
<PropertyGroup name="fileformatconfiguration">
<PropertyEntry name="format">flatfiles</PropertyEntry>
<PropertyEntry name="errorHandling">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="errorHandlingConfiguration">
<PropertyEntry name="logDataConversionWarnings">true</PropertyEntry>
<PropertyEntry name="maximumWarningsToLog"></PropertyEntry>
<PropertyEntry name="captureDataConversionErrors">false</
PropertyEntry>
<PropertyEntry name="captureRowFormatErrors">true</PropertyEntry>
<PropertyEntry name="captureStringTruncationErrors">false</
PropertyEntry>
<PropertyEntry name="maximumErrosToStopJob"></PropertyEntry>
<PropertyEntry name="writeErrorRowsToFile">false</PropertyEntry>
<PropertyEntry name="errorFileRootDirectory"></PropertyEntry>
<PropertyEntry name="errorFileName"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="sftp_location">
<PropertyEntry name="host">mo-1a6803cc5.mo.sap.corp</PropertyEntry>
<PropertyEntry name="port">22</PropertyEntry>
<PropertyEntry name="hostKeyFingerprint">ba:84:07:e8:1d:23:a0:89:0e:
13:83:e0:d2:e5:77:3e</PropertyEntry>
<PropertyEntry name="authType">password</PropertyEntry>
<PropertyEntry name="connectionRetryCount">10</PropertyEntry>
<PropertyEntry name="connectionRetryInterval">10</PropertyEntry>
<PropertyEntry name="sftp_remote_directory">/usr/sap/KS1/HDB01</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="AccessTokenEntry">
<password><password></password>
</CredentialEntry>'
'<CredentialEntry name="SFTP_CREDENTIAL">
<user><username></user>
<password><yourAccessToken></password>
</CredentialEntry>';

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 243
6.11 Hive

The Hive adapter supports Hadoop via Hive.

Hive is the data warehouse that sits on top of Hadoop and includes a SQL interface. While Hive SQL does not
fully support all SQL operations, most SELECT features are available. The Hive adapter service provider is
created as a remote source, and requires the support of artifacts like virtual table and remote subscription for
each source table to perform replication.

 Note

Before registering the adapter with the SAP HANA system, ensure that you have downloaded and installed
the correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib/hive folder.

Adapter Functionality

This adapter supports the following functionality:

● SELECT, INSERT, UPDATE, and DELETE


● Virtual table as a source
● Virtual table as a target using a Data Sink node in a flowgraph

 Restriction

Write-back operations including INSERT, UPDATE, and DELETE are supported only on Hive 2.3.3 and
newer, and the source table must support ACID transactions.

When writing to a Hive virtual table, the following data type size limitations apply:

● BLOB: 65,536 bytes


● CLOB: 43,690 bytes

In addition, this adapter supports the following capabilities:

Table 39: Global Settings

Functionality Supported?

SELECT from a virtual table Yes

INSERT into a virtual table Yes

Execute UPDATE statements on a virtual table Yes

Execute DELETE statements on a virtual table Yes

Different capabilities per table No

Installation and Configuration Guide


244 PUBLIC Configure Data Provisioning Adapters
Functionality Supported?

Different capabilities per table column No

Real-time No

Table 40: Select Options

Functionality Supported?

Select individual columns Yes

Add a WHERE clause Yes

JOIN multiple tables Yes

Aggregate data via a GROUP BY clause Yes

Support a DISTINCT clause in the select Yes

Support a TOP or LIMIT clause in the select Yes

ORDER BY Yes

GROUP BY Yes

Related Information

Understanding Hive Versions, Features, and JAR Files [page 245]


Hive Remote Source Configuration [page 248]
Kerberos Debugging [page 253]
Update JCE Policy Files for Stronger Encryption [page 518]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Understanding Hive Versions, Features, and JAR Files [page 245]

6.11.1 Understanding Hive Versions, Features, and JAR Files

Find out which Hive, Hadoop, and other product JAR files are compatible with which versions of SAP HANA
smart data integration

Depending on the version of SAP HANA smart data integration and Hive you are using, there are steps you
need to take to ensure you have the proper JAR files loaded.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 245
Upgrading to SDI 2.2.2 or Higher

Beginning with SDI 2.2.2, we no longer bundle the hadoop-core-0.20.2.jar file. When you upgrade from a
previous version, you must manually download this file and place it in the <DPAgent_root>/lib/hive folder.
After you restart the Data Provisioning Agent and refresh the Hive adapter in SAP HANA, your remote source
will work.

Avoiding JAR File Conflicts

There are two ways that conflicts may occur when installing JAR files in the <DPAgent>/lib/hive directory:

● The directory cannot contain multiple versions of Hive JAR files, which avoids class name conflicts.
● The directory cannot contain both a hadoop-core-0.20.2.jar and hadoop-common-<version>.jar
file at the same time, which also avoids class name conflicts.

JAR Files for Normal Operation

If you are not using more advanced features, the following JAR files are sufficient:

Table 41: Hive 1.2.2/Hadoop 2.7.3

Hive JAR Files Hadoop JAR Files

Found in $HIVE_HOME/lib/ Found in the Maven repository

● hive-jdbc-1.2.2-standalone.jar ● hadoop-core-0.20.2.jar

Table 42: Hive 2.3.0/Hadoop 2.8.1 (SDI 2.3.0 and above)

Hive JAR Files Hadoop JAR Files

Found in the Maven repository Found in the Maven repository

● hive-jdbc-2.3.0-standalone.jar ● hadoop-core-0.20.2.jar

Alternatively, you can use the JAR files associated with advanced Hive features listed below.

JAR Files for Advanced Features

If you are using some advanced Hive features, for example, Zookeeper and HTTP Transport Mode, a standalone
Hive JAR (hive-jdbc-<version>-standalone.jar) is not sufficient. If you are using any of the following

Installation and Configuration Guide


246 PUBLIC Configure Data Provisioning Adapters
features, you need to be sure that the following files are manually installed in the <DPAgent_root>/lib/hive
folder:

Table 43: Hive 1.2.2/Hadoop 2.7.3

Hive JAR Files Hadoop JAR Files

Found in $HIVE_HOME/lib/ Found in $HADOOP_HOME/share/hadoop/

● hive-jdbc-1.2.2-standalone.jar ● common/hadoop-common-2.7.3.jar
● commons-codec-1.4.jar ● common/lib/commons-
● httpclient-4.4.jar configuration-1.6.jar
● common/lib/hadoop-auth-2.7.3.jar
● common/lib/jaxb-impl-2.2.3.jar
● common/lib/slf4j-log4j12-1.7.10.jar
● hdfs/lib/xercesImpl-2.9.1.jar

Table 44: Hive 2.3.0/Hadoop 2.8.1 (SDI 2.3.0 and above)

Hive JAR Files Hadoop JAR Files

$HIVE_HOME/lib/ $HADOOP_HOME/share/hadoop/

● commons-codec-1.4.jar ● common/hadoop-common-2.8.1.jar
● curator-client-2.7.1.jar ● common/lib/commons-
● curator-framework-2.7.1.jar collections-3.2.2.jar
● guava-14.0.1.jar ● common/lib/commons-
● hive-common-2.3.0.jar configuration-1.6.jar

● hive-jdbc-2.3.0.jar ● common/lib/commons-lang-2.6.jar

● hive-serde-2.3.0.jar ● common/lib/hadoop-auth-2.8.1.jar

● hive-service-2.3.0.jar ● common/lib/httpcore-4.4.4.jar

● hive-service-rpc-2.3.0.jar ● common/lib/jaxb-impl-2.2.3-1.jar

● hive-shims-0.23-2.3.0.jar ● common/lib/slf4j-log4j12-1.7.10.jar

● hive-shims-2.3.0.jar ● hdfs/lib/xercesImpl-2.9.1.jar

● hive-shims-common-2.3.0.jar
● httpclient-4.4.jar
● libthrift-0.9.3.jar
● zookeeper-3.4.6.jar

Related Information

SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Hive Remote Source Configuration [page 248]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 247
6.11.2 Hive Remote Source Configuration

Configure the following options in smart data access to set up your connection to a Hive remote source. Also
included is sample code for creating a remote source using the SQL console.

 Note

If you change the remote source parameters after you have made a connection with Hive, you need to
restart the Data Provisioning Agent.

Category Option Description

Connection Use Connection URL Specify whether to use a connection


URL.

If you set this value to True, you need to


provide the URL in the Connection URL
parameter.

Connection URL The URL used to create the


connection.

The format for the connection URL is


documented on the Apache website.

Hive Version The version of Hive. For Hive 0.12.0, set


its value to 0.12.0. For Hive 0.13.0 and
0.13.1, set its value to 0.13.1, and so on.

Host The host of Hive.

A value for this parameter is necessary


only when Use Connection URL is set to
False.

If Use Connection URL is set to True,


the host should be specified in the URL
directly.

Port The port number of Hive.

A value for this parameter is necessary


only when Use Connection URL is set to
False.

If Use Connection URL is set to True,


the port should be specified in the URL
directly.

Database Name The Hive database name.

If Use Connection URL is set to True,


this parameter has no effect.

If Use Connection URL is set to False


and the database name is specified

Installation and Configuration Guide


248 PUBLIC Configure Data Provisioning Adapters
Category Option Description

here, you will see only the specified


database in the remote source catalog.
If you leave this parameter empty, you
will see all Hive databases in the
remote source catalog.

Data Type Mapping Map Hive STRING to If the length of a string in Hive is
greater than 5000 characters, set this
parameter to CLOB. The default value
is VARCHAR(5000).

Map Hive BINARY to If the length of a BINARY in Hive is


greater than 5000 characters, set this
parameter to BLOB. The default value
is VARBINARY(5000).

Security Use SSL Specifies whether to use SSL.

The default value is False.

A value for this parameter is necessary


only when Use Connection URL is set to
False.

If Use Connection URL is set to True,


the connection URL should be
specified in the URL directly.

 Note
The CA certificate for the remote
source must be imported into the
adapter truststore on the Data
Provisioning Agent host.

You will also need to set up the


truststore and password in the Data
Provisioning Agent Configuration Tool.

Logon Mechanism Controls the authentication


(+authorization) method used, and
which username and password values
to enter in the credentials field.

● Default
● Kerberos: If set to Kerberos, the
Realm, KDC, and Hive Service
Principal settings are used when
making the Hive connection.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 249
Category Option Description

Use Agent Stored Credential Set to True to use credentials that are
stored in the DP Agent secure storage.

Kerberos Realm (Optional when using Kerberos)


Authenticate using a principal from this
realm instead of the systems default
realm. Specify the realm for the
technical user.

The Realm option must be used


together with KDC.

KDC (Optional when using Kerberos) The


address of the technical user's KDC
(Key Distribution Center) to be used
with the specified realm. This must be
used together with the Realm option.

Hive Service Principal The Hive Service principal name.

 Note
A value for this parameter is
necessary only when Use
Connection URL is set to False.

If Use Connection URL is set to


True, the Hive service principal
should be specified in the URL
directly.

Use Ticket Cache Set this to true if you want the ticket-
granting ticket (TGT) to be obtained
from the ticket cache. Set this option to
False if you do not want this module to
use the ticket cache. The default value
is False.

This module searches for the ticket


cache in the following locations:

● On Solaris and Linux, in /tmp/


krb5cc_<uid>, where the uid is
a numeric user identifier.
● If the ticket cache is not available
in /tmp/krb5cc_<uid>, or if
you are on a Windows platform,
the module looks for the cache as
<user.home><file.separa

Installation and Configuration Guide


250 PUBLIC Configure Data Provisioning Adapters
Category Option Description

tor>krb5cc_<user.name>.
You can override the ticket cache
location by using the Ticket Cache
parameter.
● For Windows, if a ticket cannot be
retrieved from the file ticket cache,
the module uses Local Security
Authority (LSA) API to get the TGT.

Ticket Cache Set this to the name of the ticket cache


that contains the user's TGT. If this is
set, Use Ticket Cache must also be set
to true; otherwise, a configuration error
is returned.

Use Key Tab Set this to True if you want the module
to get the technical user's key from the
keytab. The default value is False.

If Key Tab is not set, then the module


locates the keytab from the Kerberos
configuration file. If it is not specified in
the Kerberos configuration file, then
the module looks for the file
<user.home><file.separator
>krb5.keytab.

Key Tab Set this to the file name of the keytab


to get the technical user's secret key.

Additional Properties Additional JDBC settings that are


added directly to the JDBC URL. The
parameters must be specified in the
following format:
key=value,key=value,...

A value for this parameter is necessary


only when Use Connection URL is set to
False.

Credentials Credentials Mode Technical user or Secondary user

Select one of the choices depending on


the purpose of the remote source you
want to create.

JDBC Credentials Username The technical user's user name.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 251
Category Option Description

If Logon Mechanism is set to Kerberos,


the user should be the client principal.

Password The technical user's password.

The following code samples illustrate how to create a remote source using the SQL console:

Basic

Example

 Sample Code

CREATE REMOTE SOURCE "MyHiveSource" ADAPTER "HiveAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="connectionInfo" displayName="Database">
<PropertyEntry name="HOST" displayName="Host">myhost.sap.corp</
PropertyEntry>
<PropertyEntry name="PORT" displayName="Port Number">10000</
PropertyEntry>
<PropertyEntry name="DB_NAME" displayName="Database Name">mydb</
PropertyEntry>
<PropertyEntry name="VERSION" displayName="Database Version">1.2.1</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security">
<PropertyEntry name="USE_SSL">false</PropertyEntry>
<PropertyEntry name="LOGMECH">default</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Kerberos

Example

 Sample Code

CREATE REMOTE SOURCE "MyHiveSource" ADAPTER "HiveAdapter" AT LOCATION AGENT


"MyAgent"

Installation and Configuration Guide


252 PUBLIC Configure Data Provisioning Adapters
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="connectionInfo" displayName="Database">
<PropertyEntry name="HOST" displayName="Host">myhost.sap.corp</
PropertyEntry>
<PropertyEntry name="PORT" displayName="Port Number">10000</
PropertyEntry>
<PropertyEntry name="DB_NAME" displayName="Database Name">mydb</
PropertyEntry>
<PropertyEntry name="VERSION" displayName="Database Version">1.2.1</
PropertyEntry>
<PropertyEntry name="ADDITIONAL"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security">
<PropertyEntry name="USE_SSL">false</PropertyEntry>
<PropertyEntry name="LOGMECH">Kerberos</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="Kerberos" displayName="Kerberos">
<PropertyEntry name="KERBEROS_REALM">SAPDS.CORP</PropertyEntry>
<PropertyEntry name="KERBEROS_KDC">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="KERBEROS_PRINCIPAL">hive/
myhost.sap.corp@SAPDS.CORP</PropertyEntry>
<PropertyEntry name="KERBEROS_REFRESH_KRB5_CONFIG">true</
PropertyEntry>
<PropertyEntry name="KERBEROS_USE_TICKET_CACHE">false</
PropertyEntry>
<PropertyEntry name="KERBEROS_USE_KEY_TAB">true</PropertyEntry>
<PropertyEntry name="KERBEROS_KEY_TAB">my.keytab</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser@SAPDS.CORP</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Apache Hive Connection URL Format


Understanding Hive Versions, Features, and JAR Files [page 245]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.11.3 Kerberos Debugging


There are steps you need to take to enable Kerberos debugging.

Even though you may have enabled Kerberos debug messages in the remote source configuration by setting
Kerberos Debug to True or by setting sun.security.krb5.debug=true in the dpagentconfig.ini file, the
debug messages will not appear in the Data Provisioning Agent log framework.trc.

To make the Kerberos debug messages visible, start the Data Provisioning Agent directly by executing
<DPAgent_root>/dpagent, or in Windows, <DPAgent_root>/dpagent.exe). Then, all logs and Kerberos

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 253
debug messages are printed in your console. In Linux, you could also save all of the output to a file by
redirecting the stdout and stderr, such as ./dpagent 2>&1 1>output.txt.

Related Information

Hive Remote Source Configuration [page 248]

6.12 IBM DB2 Log Reader

The IBM DB2 Log Reader adapter provides real-time changed-data capture capability to replicate changed data
from a database to SAP HANA in real time. You can also use this adapter for batch loading.

The Log Reader service provider is created as a remote source and requires the support of artifacts like virtual
tables and remote subscriptions for each source table to perform replication.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

Adapter Functionality

This adapter supports the following functionality:

● Connect multiple remote sources in SAP HANA to the same source database

 Note

Use different DB2 users to set up different replications on the same DB2 database.

● Virtual table as a source


● Real-time changed-data capture (CDC)

 Restriction

DB2 range partitioned tables are not supported for real-time CDC.

 Note

Log Reader adapters do not support the truncate table operation.

● Virtual table as a target using a Data Sink node in a flowgraph


● Loading options for target tables

Installation and Configuration Guide


254 PUBLIC Configure Data Provisioning Adapters
● DDL propagation. The supported schema changes are:
○ ADD COLUMN
○ DROP COLUMN
● Replication monitoring and statistics
● Search for tables
● LDAP Authentication
● Virtual procedures

In addition, this adapter supports the following capabilities:

Table 45: Global Settings

Functionality Supported?

SELECT from a virtual table Yes

INSERT into a virtual table Yes

Execute UPDATE statements on a virtual table Yes

Execute DELETE statements on a virtual table Yes

Different capabilities per table No

Different capabilities per table column No

Realtime Yes

Table 46: Select Options

Functionality Supported?

Select individual columns Yes

Add a WHERE clause Yes

JOIN multiple tables Yes

Aggregate data via a GROUP BY clause Yes

Support a DISTINCT clause in the select Yes

Support a TOP or LIMIT clause in the select Yes

ORDER BY Yes

GROUP BY Yes

Related Information

IBM DB2 Real-time Replication [page 256]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 255
DB2LogReaderAdapter Preferences [page 268]
DB2 Log Reader Remote Source Configuration [page 270]
Using a Schema Alias [page 277]
Log Reader Adapter Log Files [page 278]
Configure SSL for the DB2 Log Reader Adapter [page 278]
Creating a Whitelist to Limit Access to a Source Database [page 281]
Disable Adapter Write-back Functionality [page 282]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.12.1 IBM DB2 Real-time Replication

Information about setting up your source system and adapter for real-time replication.

Related Information

Remote Database Setup for DB2 Real-time Replication [page 256]


Remote Database Clean-up for DB2 Real-time Replication [page 266]
Validate the IBM DB2 Log Reader Environment [page 266]
Generate a Log Reader Remote Source Creation Script [page 267]

6.12.1.1 Remote Database Setup for DB2 Real-time


Replication

The remote database must be set up properly for Log Reader adapters to function correctly when using real-
time replication.

This setup process is necessary only when using real time.

Remember the following when setting up for replication:

● If you have a UDB client instance and a UDB server instance on different machines, the client and server
must be of the same UDB version.
● On a Windows system, the DB2 connectivity autocommit parameter must be enabled (autocommit=1).
The autocommit parameter is specified in the DB2 call level interface (CLI) configuration file for the
primary database.
If the autocommit parameter is not enabled, a deadlock problem can occur. The path to the CLI
configuration file is:<%DB2DIR%> \sqllib\db2cli.ini where <%DB2DIR%> is the path to the DB2 client
installation. Alternatively, to enable autocommit, open the DB2 administrative command-line console and
run: db2set DB2OPTIONS=-c
● To initialize LogReader without error, the database must have a tablespace created with these
characteristics:

Installation and Configuration Guide


256 PUBLIC Configure Data Provisioning Adapters
○ The tablespace should be a user temporary tablespace. By default, user temporary tablespaces are
not created when a database is created.
○ The tablespace must be a system-managed space (SMS).
○ The PAGESIZE parameter must be set to 8192 (8 kilobytes) or greater.

Upgrading the DB2 Database

Before upgrading your source DB2 database, keep the following in mind:

● Suspend any remote subscriptions before upgrading. Before suspending your subscriptions, ensure that
all data has been synced to the SAP HANA target table.
● After suspending your subscriptions, ensure that there is a change to the DB2 source table.
● After your upgrade, resume your subscriptions. If you receive an error such as code: <-2,657> after
resuming your subscriptions, reset and then resume all of your subscriptions.

Real-time Replication Limitations

The following limitations exist when performing real-time replication:

● Unsupported table types:


○ Table with all LOB columns
○ Table with computed columns
○ Table with LOB column and no primary key or unique index
○ Table with duplicated rows and no primary key
○ Table with user-defined identifier
○ Nested table

Related Information

Setting DB2 Universal Database Environment Variables [page 258]


Installing the Data Provisioning Agent and DB2 Server on Different Servers [page 258]
Primary DB2 UDB Database Configuration for Replication [page 260]
Required Libraries for DB2 Log Reader Adapter [page 265]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 257
6.12.1.1.1 Setting DB2 Universal Database Environment
Variables

The method for setting DB2 UDB environment variables depends on the operating system.

 Note

The DB2 UDB environment variables should be set up regardless of whether your Data Provisioning Agent
is installed on the same server as the DB2 database or not. Prior to setting up the variables, be sure that
you have installed the IBM Data Server Runtime Client.

For Linux, the DB2 UDB installation provides two scripts for setting up the DB2 UDB environment variables:
db2cshrc for C shell and db2profile for Bourne or Korn shell. These scripts set the library path environment
variable based on the bit size of the installed server or client.

For Windows, the installation sets all necessary environment variables.

For Linux platforms, the 32-bit and 64-bit versions of the driver and API libraries are located in <$HOME/
sqllib/lib32>/sqllib/lib32 and <$HOME/sqllib/lib64>/sqllib/lib64, respectively, where <
$HOME> is the home directory of the DB2 UDB instance owner.

 Note

If the Data Provisioning Agent is installed on Linux, the library path environment variable must point to the
64-bit libraries. For Windows, the library path environment variable must point to the 32-bit libraries.

 Note

We recommend that you add a line to the <DPAgent_root>/bin/dpagent_env.sh file to set the
db2profile environmental variables. This ensures that when you use dpagent_service.sh to start and
stop the DPAgent service, the DB2 UDB environment variables are sourced automatically. For example, you
could add a line such as . /home/db2inst1/sqllib/db2profile.

6.12.1.1.2 Installing the Data Provisioning Agent and DB2


Server on Different Servers

Additional steps are necessary when installing the Data Provisioning Agent and DB2 Server on different
servers.

If the Data Provisioning Agent and the DB2 Server are on different machines, the IBM Data Server Runtime
Client must be installed on the Data Provisioning Agent machine.

Related Information

DB2 Connectivity [page 259]


Catalog the Remote TCP/IP Node from the DB2 Client [page 259]

Installation and Configuration Guide


258 PUBLIC Configure Data Provisioning Adapters
Catalog the Primary Database from the DB2 Client [page 260]

6.12.1.1.2.1 DB2 Connectivity

The method for configuring DB2 connectivity varies by operating system.

On a Windows system, you must configure a DB2 Universal Database JDBC data source in the DB2
Administration Client, then use the database name and database alias specified for that DB2 Universal
Database JDBC data source when you configure DB2 LogReader Adapter connectivity.

On a Linux system, catalog the node and the primary database in DB2. Set the DB2 LogReader Adapter
pds_datasource_name parameter to the database alias. Also set the pds_host_name and
pds_host_number.

6.12.1.1.2.2 Catalog the Remote TCP/IP Node from the DB2


Client

Follow these steps to catalog the remote TCP/IP node from the DB2 client.

Procedure

1. (For Linux only) Log in as the DB2 instance owner.


Logging in sets up your DB2 environment variables by executing the environment scripts. You can also
execute these scripts manually as follows.
In Korn shell, source the db2profile file: <$HOME>/sqllib/db2profile.
In C shell, source the db2cshrc file: source <$HOME>/sqllib/db2cshrc
<$HOME> is the home directory of the DB2 instance owner.
2. Start the DB2 command-line processor by typing the following DB2 command: %>db2 db2 =>
3. Catalog the remote TCP/IP node using this command at the DB2 prompt: db2 => catalog TCPIP node
MYNODE remote MYHOST server XXXX, where <MYNODE> is the node name, <MYHOST> is the host
name or IP address of the data server, and <XXXX> is the data server port number.
4. Verify the catalog entry: db2 => list node directory. DB2 should return something similar to: Node
1 entry: Node name = MYNODE Comment = Directory entry type = LOCAL Protocol = TCPIP Hostname =
MYHOST Service name = XXXX

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 259
6.12.1.1.2.3 Catalog the Primary Database from the DB2
Client

Follow these steps to catalog the primary database from the DB2 client.

Procedure

1. Catalog the primary database using this command at the DB2 prompt:

db2 => catalog database MYDB as MYDB_ALIAS at node MYNODE

Parameter Description

MYDB Database name

MYDB_ALIAS Alias for the database

MYNODE Node name used in the catalog TCPIP node command

2. Verify the catalog entry:

db2 => list database directory

DB2 should return something similar to:

System Database Directory

Number of entries in the direc­ 1


tory

Database 1 entry Database alias = MYDB_ALIAS

Database name = MYDB

Node name = MYNODE

Database release level = b.00

Comment =

Directory entry type = Remote

6.12.1.1.3 Primary DB2 UDB Database Configuration for


Replication

Configure your DB2 UDB database to work with the Log Reader adapter and replication.

For successful replication, remember the following:

● If you have a UDB client instance and a UDB server instance on different machines, the client and server
must be of the same UDB version.

Installation and Configuration Guide


260 PUBLIC Configure Data Provisioning Adapters
● On a Windows system, the DB2 connectivity autocommit parameter must be enabled (autocommit=1).
The autocommit parameter is specified in the DB2 call level interface (CLI) configuration file for the
primary database. If the autocommit parameter is not enabled, a deadlock problem can occur.
The path to the CLI configuration file is: <%DB2DIR%>\sqllib\db2cli.ini where <%DB2DIR%> is the
path to the DB2 client installation. Alternatively, to enable autocommit, open the DB2 administrative
command line console and run: db2set DB2OPTIONS=+c
● To initialize LogReader without error, the database must have a tablespace created with these
characteristics:
○ The tablespace should be a user temporary tablespace. By default, user temporary tablespaces are
not created when a database is created.
○ The tablespace must be a system-managed space (SMS).
○ The PAGESIZE parameter must be set to 8192 (8 kilobytes) or greater.

Related Information

Add a Temporary Tablespace to the Primary Database [page 261]


Verify the Current Archive Setting of the Transaction Log [page 262]
Create a DB2 UDB User and Grant Permissions [page 264]

6.12.1.1.3.1 Add a Temporary Tablespace to the Primary


Database

These steps show how to add a temporary tablespace to the primary database.

Procedure

1. Start the DB2 UDB command-line processor:

%>bash
%>source /db2home/db2inst1/sqllib/db2profile
%>db2

2. Connect to the primary DB2 UDB database:

db2 => connect to pdb user db2_admin_user using db2_admin_password

<db2_admin_user> and <db2_admin_password> are the administrative user ID and password for the
primary database.
3. Create a buffer pool:

db2 => create bufferpool pdb_buffer_name size 1000 pagesize


same_pagesize_as_pdb

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 261
<pdb_buffer_name> is the buffer name and <same_pagesize_as_pdb> is the page size at the primary
database.
4. Create a temporary tablespace:

db2=>create user temporary tablespace pdb_temp_space_name


pagesize same_pagesize_as_pdb managed by automatic storage
bufferpool pdb_buffer_name

<pdb_temp_space_name> is the tablespace name, <same_pagesize_as_pdb> is the page size at the


primary database, and <pdb_buffer_name> is the buffer name.

 Note

Determine the DB2 UDB page size using the LIST TABLESPACES SHOW DETAIL command. For
example, to create a temporary tablespace named deep13 with a 16-KB page size and buffer pool
named tom_servo, enter:

db2 => create user temporary tablespace deep13 pagesize 16K managed by
automatic storage bufferpool tom_servo

6.12.1.1.3.2 Verify the Current Archive Setting of the


Transaction Log
Set the primary DB2 UDB database transaction logging to archive logging instead of circular logging for DB2
LogReader Adapter.

Procedure

1. Determine the LOGARCHMETH1 setting.


a. Connect to the database by entering this command at the CLP prompt:

db2 => CONNECT TO dbalias USER db2_user USING db2_user_ps

where <dbalias> is the cataloged alias of the primary database, <db2_user> is the primary
database user, and <db2_user_ps> is the password.
b. Determine the LOGARCHMETH1 setting:

db2 => GET DB CFG FOR dbalias

2. If the results do not show that LOGARCHMETH1 is set to LOGRETAIN or to the path name of the directory
to which logs are archived or TSM server, set it:

○ To use the default archive location:

db2 => UPDATE DATABASE CONFIGURATION USING logarchmeth1 LOGRETAIN

○ To use a specific archive location:

db2 => UPDATE DATABASE CONFIGURATION USING logarchmeth1 DISK:path

Installation and Configuration Guide


262 PUBLIC Configure Data Provisioning Adapters
○ To use TSM server:

db2 => UPDATE DATABASE CONFIGURATION USING logarchmeth1 TSM

where <path> is the full path name of the directory where the archive logs are to be stored. If you change
the setting of the DB2 UDB logarchmeth1 parameter, DB2 UDB requires you to back up the database. Use
your normal backup procedure or see the IBM documentation for information on the BACKUP DATABASE
command.
3. Reactivate and backup the DB2 UDB database to make the configuration change take effect:
a. Deactivate the database db2 => DEACTIVATE DATABASE dbalias USER db2_user USING
db2_user_ps, where <dbalias> is the cataloged alias of the primary database, <db2_user> is the
primary database user, and <db2_user_ps> is the password.
b. Back up the database:
○ LOGARCHMETH1=LOGRETAIN

db2 => BACKUP DATABASE dbalias USER db2_user USING db2_user_ps

○ LOGARCHMETH1=DISK: path

db2 => BACKUP DATABASE dbalias TO path USER db2_user USING db2_user_ps

where <dbalias> is the cataloged alias of the primary database, <path> is the log archive path
you specified, <db2_user> is the primary database user, and <db2_user_ps> is the password.
c. Activate the database again db2 => ACTIVATE DATABASE dbalias USER db2_user USING
db2_user_ps, where <dbalias> is the cataloged alias of the primary database, <db2_user> is the
primary database user, and <db2_user_ps> is the password.
4. Verify the configuration change:

○ db2=> CONNECT TO dbalias USER db2_user USING db2_user_ps

where <dbalias> is the cataloged alias of the primary database, <db2_user> is the primary
database user, and <db2_user_ps> is the password.

○ db2=> CALL SYSPROC.GET_DB_CONFIG()

○ db2=> SELECT DBCONFIG_TYPE, LOGARCHMETH1 FROM SESSION.DB_CONFIG

The last SELECT statement returns two rows: one for the on-disk (DBCONFIG_TYPE=0) value and another
for the in-memory (DBCONFIG_TYPE=1) value. Make sure that both of the values are changed to
LOGRETAIN or DISK.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 263
6.12.1.1.3.3 Create a DB2 UDB User and Grant Permissions

These steps show how to create a DB2 UDB user and grant permissions.

Context

DB2 LogReader Adapter requires a DB2 UDB login that has permission to access data and create new objects
in the primary database. The DB2 UDB login must have SYSADM or DBADM authority to access the primary
database transaction log.

Procedure

1. Create a new operating system user named ra_user using commands appropriate for your operating
system. For example, to create a user named ra_user on a Linux operating system, use: %>useradd -
gusers -Gmgmt -s/bin/shell -psybase -d/home/ra_user -m ra_user, where <psybase> is
the password corresponding to the ra_user user name.
2. Start the DB2 UDB command-line processor:

%>bash
%>source /db2home/db2inst1/sqllib/db2profile
%>db2

3. Connect to the primary DB2 UDB database: db2=>connect to pdb user db2_admin_user using
db2_admin_password, where <db2_admin_user> and <db2_admin_password> are the administrative
user ID and password for the primary database.
4. Grant all necessary authorities to ra_user:

GRANT DBADM ON DATABASE TO USER <user>


GRANT CREATETAB ON DATABASE TO USER <user>
GRANT BINDADD ON DATABASE TO USER <user>
GRANT CONNECT ON DATABASE TO USER <user>
GRANT CREATE_NOT_FENCED_ROUTINE ON DATABASE TO USER <user>
GRANT IMPLICIT_SCHEMA ON DATABASE TO USER <user>
GRANT LOAD ON DATABASE TO USER <user>
GRANT CREATE_EXTERNAL_ROUTINE ON DATABASE TO USER <user>
GRANT QUIESCE_CONNECT ON DATABASE TO USER <user>

Installation and Configuration Guide


264 PUBLIC Configure Data Provisioning Adapters
6.12.1.1.4 Required Libraries for DB2 Log Reader Adapter
The following table contains a list of the required libraries for setting up the DB2 Log Reader Adapter.

Library Notes

DB2 UDB JDBC driver Include the DB2 JDBC driver library in the Data Provisioning Agent CLASSPATH envi­
ronment variable. Use the corresponding version of the JDBC driver listed in the IBM
documentation.

For information about required JDBC libraries, see the SAP HANA smart data
integration Product Availability Matrix (PAM). This JAR file (db2jcc4.jar) must be
copied to the following directory:

<DPAgent_root>/lib

Log Reader native interface The DB2 Log Reader Adapter calls a C-based native interface to access the DB2 Log
Reader API to read its log record. Include the native interface library in the DPAgent
PATH (for Windows) or LD_LIBRARY_PATH (for Linux) environment variable or
JVM -Djava.libary.path variable if you start up the Data Provisioning Agent
from Eclipse.

Platform Notes

Windows (64-bit) sybrauni.dll to support DB2 v9.5

sybrauni97.dll to support DB2 v9.7

sybrauni98.dll to support DB2 v10.1, v10.5

Linux (64-bit) libsybrauni.so to support DB2 v9.5

libsybrauni97.so to support DB2 v9.7)

libsybrauni98.so to support DB2 v9.8, v10.1, v10.5

 Note
The native interface libraries are packaged into the Data Provisioning Agent in­
staller.

DB2 Log Reader Adapter internal li­ ● sybrautrunc.jar


braries
● sybraudb2flsn.jar

These libraries are installed into the DB2 database during replication initialization for
specific procedure calls. Include them in the Data Provisioning Agent CLASSPATH
environment variable. These libraries are packaged into the Data Provisioning Agent
installer.

Related Information

IBM driver documentation

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 265
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.12.1.2 Remote Database Clean-up for DB2 Real-time


Replication

Run SQL scripts to clean objects manually from the DB2 source database.

Clean-up scripts are used to drop database-level objects. Usually you do not need to execute a clean-up script
after an adapter is dropped, because the adapter drops database-level objects automatically. However, in some
cases, if any errors occur before or while automatically dropping these objects, the objects may not be
dropped. At that point, you may want to execute the clean-up script to drop the objects.

You can find the DB2 clean-up script file at <DPAgent_root>\LogReader\scripts


\db2_logreader_cleanup.sql.

6.12.1.3 Validate the IBM DB2 Log Reader Environment

You can use the Data Provisioning Agent command-line configuration tool to validate the configuration of the
IBM DB2 log reader environment before creating remote sources that use the IBM DB2 Log Reader adapter.

Prerequisites

Before validating the log reader environment, be sure that you have downloaded and installed the correct JDBC
libraries. For information about the proper JDBC library for your source, see the SAP HANA smart data
integration Product Availability Matrix (PAM).

Also, before starting these steps, place your files in <DPAgent_root>/lib, and manually create the /lib
folder.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose DB2 Replication Setup.
4. Choose Config DB2 Connection Info to configure the connection used for other validation tasks.
Specify the following information required to connect the configuration tool to the database:

Installation and Configuration Guide


266 PUBLIC Configure Data Provisioning Adapters
○ The hostname, port number, database name, and database source name for the DB2 database
○ Whether to use SSL
○ The DB2 username and password for connecting to the database
The configuration tool connects to the database with the specified parameters when performing other
validation tasks.
5. Perform validation and configuration tasks for the IBM DB2 log reader environment.
For each task, provide any additional parameters required by the task. To test whether the DB2
environment is ready for replication, choose DB2 Replication Precheck.

Next Steps

After you have validated the configuration of the IBM DB2 log reader environment, you can create remote
sources with the IBM DB2 Log Reader adapter. You can manually create remote sources or generate a creation
script with the command-line configuration tool.

Related Information

Generate a Log Reader Remote Source Creation Script [page 267]


DB2 Log Reader Remote Source Configuration [page 270]

6.12.1.4 Generate a Log Reader Remote Source Creation


Script

Use the Data Provisioning Agent command-line configuration tool to validate parameters and generate a
usable script to create a remote source for log reader adapters.

Prerequisites

Before generating a remote source creation script for your source, be sure that you have downloaded and
installed the correct JDBC libraries. For information about the proper JDBC library for your source, see the SAP
HANA smart data integration Product Availability Matrix (PAM).

Before performing these steps, place your files in <DPAgent_root>/lib. Note that you must manually create
the /lib folder.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 267
Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose the appropriate replication setup option for your remote source type.
4. Choose the appropriate log reader setup option for your remote source type.
5. Provide the configuration details for your remote source as prompted.

Specify the name of the agent to use and the name of the remote source to create, as well as any
connection and configuration information specific to your remote source.

For more information each configuration parameter, refer to the remote source configuration section for
your source type.

Results

The configuration tool validates the configuration details for your remote source and generates a script that
can be used to create the remote source. You can view the validation results in the Data Provisioning Agent log.

By default, the configuration tool generates the remote source creation script in the user temporary directory.
For example, on Windows: C:\Users\<username>\AppData\Local\Temp\remoteSource-
<remote_source_name>.txt.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

6.12.2 DB2LogReaderAdapter Preferences

Configuration parameters for the DB2 Log Reader adapter.

 Note

Log Reader adapter preferences are no longer set in the Data Provisioning Agent Configuration Tool with
the exception of Number of wrapped log files, Enable verbose trace, and Maximum log file size. They are now
in the remote source configuration options in SAP HANA. If you have upgraded from a previous version, the
settings you find in the Agent Configuration Tool are the previous settings and are displayed for your
reference.

Installation and Configuration Guide


268 PUBLIC Configure Data Provisioning Adapters
You can adjust DB2 Log Reader adapter settings in the Data Provisioning Agent Configuration Tool.
(<DPAgent_root>/configTool/dpagentconfigtool.exe)

Parameter Description Default value

Maximum operation queue size The maximum number of operations 1000


permitted in the log reader operation
queue during replication.

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Ignore log record processing errors Determines whether to ignore log re­ false
cord processing errors.

Replicate LOB columns Determines whether the agent applies true


each LOB change.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library (DBLIB, 5


connections fails ODBC, ADO, and so on) to keep retrying
the connection attempt, as long as the
server is not found, for the specified
number of times.

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size in 1-K blocks of the 3
LogReader system log file before wrap­
ping.

Enable verbose trace Enables or disables extra diagnostic in­ false


formation in the agent system log files.

Maximum log file size Limits the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not Log Reader TRUE
should turn on asynchronized logging
mode. (TRUE, FALSE)

Maximum size of work queue for asyn­ The Maximum size of the work queue 1000
chronous logging for asynchronous logging file handler to
collect the log records. The range is 1 to
2147483647.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 269
Parameter Description Default value

Discard policy for asynchronous logging Specifies the discard policy for the BLOCKING
file handler asynchronous logging file handler when
the work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offered into queue are
dropped.
● DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried, which can fail
again, causing this process to be
repeated.

6.12.3 DB2 Log Reader Remote Source Configuration

Configure your connection to a DB2 remote source.

When setting up a remote source and you use a remote source name longer than 30 characters, the generated
log reader folder name under <DPAgent_root>/LogReader/ is converted to AGENT<xxxx>.

The log file is located at <DPAgent_root>/log/Framework.trc and reads: The instance name
<original_name> exceeds 30 characters and it is converted to <converted_name>.

Category Option Description

Generic Always Map Character Types to Determines whether a CHAR/


Unicode
CHARACTER/VARCHAR/
LONGVARCHAR/CLOB column in the
source database is mapped to a
Unicode column type in SAP HANA
when the source database character
set is non-ASCII. The default value is
False.

The value of this parameter can be


changed when the remote source is
suspended.

Set this parameter to True only when


the remote database is multibyte
character sets such as UTF-8, GBK,
and JA16SJIS.

Installation and Configuration Guide


270 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Load and Replicate LOB columns When this parameter is set to False, the
LOB columns are filtered out when
doing an initial load and real-time
replication.

The value of this parameter can be


changed when the remote source is
suspended.

 Note
This option is not available for an
ECC adapter.

Database Host The host name or IP address on which


the DB2 Server is running.

The value of this parameter can be


changed when the remote source is
suspended.

Port Number The port number of the DB2 Server.


See Setting the DB2 Port Number
[page 277] for more information.

Database Name The name of the database

Database Source Name Set the Source Name parameter to


<MYDB_ALIAS> when creating a
remote source, where <MYDB_ALIAS>
is the database alias that was used
when cataloging the primary database.

Whitelist Table in Remote Database Enter the name of the table that
contains the whitelist in the remote
database.

Include Table/Columns Remarks ● True: Returns a description of the


table/column. If you have many
tables, setting this parameter to
True can impede performance.
● False (Default): Turns off the
return of descriptions

If the parameter Include Table/


Columns Remarks is set to True, the
descriptions of tables/views are
returned when
GET_REMOTE_SOURCE_OBJECTS_LIS
T is called. The descriptions of tables/
views and columns are returned when

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 271
Category Option Description

GET_REMOTE_SOURCE_TABLE_DEFI
NITIONS is called.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Additional Connection Properties Use this parameter to attach additional


custom connection properties. For
example, you can use this new
parameter to set JDBC driver
connection properties.

Use the following format:

key1=value1[;key2=value2].
..

For example,
securityMechanism=9;encryp
tionAlgorithm=2

LDAP Authentication Use LDAP Authentication Set to True to enable LDAP


authentication for the DB2 database.
The default is False.

 Note
The IBM DB2 log reader adapter
does not support the following
LDAP scenarios:

● LDAP + SSL authentication


● LDAP + Kerberos
authentication
● LDAP failover mode

Schema Alias Replacements Schema Alias Schema name to be replaced with the
schema given in Schema Alias
Replacement. If given, accessing tables
under it is considered to be accessing
tables under the schema given in
Schema Alias Replacement.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


272 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Schema Alias Replacement Schema name to be used to replace


the schema given in Schema Alias.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Security Use SSL Specifies whether you are using SSL.

The default value is False.

Use Agent Stored Credential Set to True to use credentials that are
stored in the Data Provisioning Agent
secure storage.

The default value is False.

 Note
When you use credentials stored in
the agent's secure storage, you
must still specify the user name in
Credentials User Name .
Additionally, the Credential Mode
must not be none or empty.

CDC Properties > Log Reader Maximum operation queue size The maximum number of operations
permitted in the log reader operation
queue during replication. The value
range is 25 to 2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Maximum scan queue size The maximum number of log records


permitted in the log reader log scan
queue during replication. The value
range is 25 to 2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Ignore log record processing errors Specifies whether to ignore log record
processing errors. If set to True, the
replication does not stop if log record
processing errors occur. The default
value is False.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 273
Category Option Description

The value of this parameter can be


changed when the remote source is
suspended.

Ignore log record decluster errors


 Note
This parameter is available only
when you are using the DB2 Log
Reader ECC adapter.

Specifies whether to ignore log record


declustering errors. If set to True, the
replication does not stop if log record
declustering errors occur. The default
value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Database connection pool size Maximum number of connections


allowed in the connection pool on a
secondary node. The value range is 1to
64.

The value of this parameter can be


changed when the remote source is
suspended.

Number of times to retry to connect if Instructs a client library, such as


a connection fails
DBLIB, ODBC, and ADO, to keep trying
the connection attempt when the
server is not found for the specified
number of times. The value range is 0
to 2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Timeout in seconds to retry connecting The number of seconds the agent waits
between retry attempts to connect to
the primary database. The value range
is 0 to 3600.

The value of this parameter can be


changed when the remote source is
suspended.

LogReader Character Set Represents the charset of the source


DB2 database. There is no default

Installation and Configuration Guide


274 PUBLIC Configure Data Provisioning Adapters
Category Option Description

value, which means no character set


conversion occurs during the
replication from DB2 to SAP HANA. To
view the accepted character set name,
refer to http://www.iana.org/
assignments/character-sets .

The value of this parameter can be


changed when the remote source is
suspended.

LogReader read buffer size Allows you to adjust the size of the DB2
log read. If the size is too small, you
may encounter an errorsqlcode
-2650 reason 8.

The default value is 65536. The value


range is 1000 to 2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Credentials Credentials Mode


● Technical UserRemote sources
support two types of credential
modes to access a: A valid user
and password in the remote
database. This valid user is used
by anyone using the remote
source.
● Secondary User: A unique access
credential on the remote source
assigned to a specific user.

Credential User Name The name of the DB2 database user


that DB2 LogReader Adapter uses to
access the DB2 database.Remote
sources support two types of
credential modes to access a remote
source: technical user and secondary
credentials.

Password The password of the DB2 database


user that DB2 LogReader Adapter uses
to access the DB2 database.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 275
SQL Example

CREATE REMOTE SOURCE "db2rs" ADAPTER "DB2LogReaderAdapter" AT LOCATION AGENT


"MyAgent" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_host_name" displayName="Host"
isRequired="true">mo-xxxxxxxx.mo.sap.corp</PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number"
isRequired="true">60060</PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name"
isRequired="true">testdb</PropertyEntry>
<PropertyEntry name="pds_datasource_name" displayName="Database
SourceName" isRequired="true">testdb</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security">
<PropertyEntry name="pds_use_agent_stored_credential">false</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>xxxx</user>
<password>xxxxxxxxx</password>
</CredentialEntry>
<CredentialEntry name="credential_user_only">
<password>xxxxxxx</password>
</CredentialEntry>';

Related Information

Setting the DB2 Port Number [page 277]


Create Credentials for a Secondary User
Using a Schema Alias [page 277]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Security Aspects of SAP HANA Smart Data Access (SAP HANA Security Guide)
Creating a Whitelist to Limit Access to a Source Database [page 281]
Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]
DB2 Log Reader Remote Source Configuration [page 270]
Setting the DB2 Port Number [page 277]
Using a Schema Alias [page 277]

Installation and Configuration Guide


276 PUBLIC Configure Data Provisioning Adapters
6.12.3.1 Setting the DB2 Port Number

Make sure that the DB2 port number is within a valid range.

If the DB2 port number is set to 0 or larger than 65535, DB2 converts it to a port number that is less than
65535. The following translation rules apply:

● If the port number is 0 or 65536, DB2 will set a random port number after you restart DB2, each time.
● If the port number is larger than 65536, the real port number that DB2 set is the port number, minus
65536. For example, 70000–65536=4464. In this case, 4464 is the real port number that DB2 sets.

To identify the real port number:

● On Windows, open Task Manager. Find the PID of DB2_XX service, then open a cmd prompt and type
netstat -aon | findstr PID.
● On Linux, use the ps -aux |grep db2sysc command.

6.12.4 Using a Schema Alias

Using a schema alias can help you manage multiple schema, remote sources, and tables more easily.

The Schema Alias and Schema Alias Replacement options, available in the remote source configuration
parameters for some Data Provisioning adapters, allow you to switch easily between schema, remote sources,
and tables. The Schema Alias is the name of the schema in the original system. The Schema Alias Replacement
is the name of the schema in the current system that replaces the Schema Alias name.

A common use case is to create a remote source pointing to a development database (for example, DB_dev),
and then create virtual tables under that remote source. Afterward, you may switch to the production database
(for example, DB_prod) without needing to create new virtual tables; the same tables exist in both DB_dev and
DB_prod, but under different schema and databases.

During the development phase, you may create a virtual table for a source table OWNER1.MYTABLE in DB_dev,
for example. Note that OWNER1.MYTABLE is the unique name of the source table, and it is a property of the
virtual table. With it, the adapter knows which table in the source database it is expected to access. However,
when you switch to the production database (DB_prod), there is no OWNER1.MYTABLE, only
OWNER2.MYTABLE. The unique name information of the virtual table cannot be changed once created.

You can resolve this problem using the Schema Alias options. In this case, we want to tell the adapter to replace
OWNER1 with OWNER2. For example, when we access OWNER1.MYTABLE, the adapter should access
OWNER2.MYTABLE. So here, OWNER1 is Schema Alias from the perspective of DB_prod, while OWNER2 is
Schema Alias Replacement.

To use this functionality, you must populate both of these options.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 277
SAP HANA Remote Source Configuration [page 444]
SDI DB2 Mainframe [page 460]

6.12.5 Log Reader Adapter Log Files

You can review processing information in the Log Reader log files.

The following files are available:

Log file name and location Description

<DPAgent_root>/LogReader/admin_logs/ Log Reader administration log


admin<instance_name>.log

<DPAgent_root>/log/<instance_name>.log Log Reader instance log

 Note

By default, the adapter instance name is the same as the remote source name when the remote source is
created from the SAP HANA Web-based Development Workbench.

6.12.6 Configure SSL for the DB2 Log Reader Adapter

Set up secure SSL communication between DB2 and the Data Provisioning Agent.

Context

If you want to use SSL communication between your DB2 source and the Data Provisioning Agent, you must
prepare and import certificates and configure the source database.

Procedure

1. Prepare the DB2 database server for SSL connections.


a. Create an SSL directory and use the gskit tool to generate the SSL key file.

For example, on Windows:

cd C:\SSL
"C:\Program Files\ibm\gsk8\bin\gsk8capicmd_64.exe" -keydb -create -db
"key.kdb" -pw "ibm123456" -stash
"C:\Program Files\ibm\gsk8\bin\gsk8capicmd_64.exe" -cert -create -db
"key.kdb" -pw "ibm123456" -label "SSLLabel" -dn
"CN=XXXX.XX.XX.XXXX,O=IBM,OU=IDL,L=Bangalore,ST=KA,C=INDIA"

Installation and Configuration Guide


278 PUBLIC Configure Data Provisioning Adapters
"C:\Program Files\ibm\gsk8\bin\gsk8capicmd_64.exe" -cert -extract -db
"key.kdb" -pw "ibm123456" -label "SSLLabel" -target "key.arm" -format
ascii -fips

On Linux:

cd /home/db2inst1/SSL
/home/db2inst1/sqllib/gskit/bin/gsk8capicmd_64 -keydb -create -db
"key.kdb" -pw "ibm123456" -stash
/home/db2inst1/sqllib/gskit/bin/gsk8capicmd_64 -cert -create -db "key.kdb"
-pw "ibm123456" -label "SSLLabel" -dn
"CN=XXXX.XX.XX.XXXX,O=IBM,OU=IDL,L=Bangalore,ST=KA,C=INDIA"
/home/db2inst1/sqllib/gskit/bin/gsk8capicmd_64 -cert -extract -db
"key.kdb" -pw "ibm123456" -label "SSLLabel" -target "key.arm" -format
ascii -fips

b. Connect to the DB2 database using the instance user, and use the command-line interface to update
SSL-relevant configuration parameters.

Specify the server SSL key location, label, and port, and set the communication protocol to include
SSL.

For example, to use a key stored in H:\cert\SSL with the label “SSLLabel” and port 56110:

db2 update dbm cfg using SSL_SVR_KEYDB H:\cert\SSL\key.kdb


db2 update dbm cfg using SSL_SVR_STASH H:\cert\SSL\key.sth
db2 update dbm cfg using SSL_SVR_LABEL SSLLabel
db2 update dbm cfg using SSL_SVCENAME 56110
db2set DB2COMM=SSL,TCPIP
db2 update dbm cfg using DIAGLEVEL 4
db2 force application all
db2 stop
db2 restart

c. Verify the SSL configuration.

In the DB2 diagnostic log db2diag.log, check for the following message:

MESSAGE : DIA3000I "SSL" protocol support was successfully started.

Additionally, verify that the /etc/services file contains the specified SSL port.
2. Prepare the DB2 client for SSL connections.
a. Copy the SSL key from the DB2 database server to the DB2 client location.

Create an SSL directory on the DB2 client, and copy key.arm from the DB2 server into this directory.
b. Add the DB2 server SSL key to the DB2 client.

From the SSL directory on the DB2 client, use the gskit tool to import the server SSL key.

For example:

/build/db2/gskit/bin/gsk8capicmd_64 -keydb -create -db "keyclient.kdb" -pw


"ibm123456" -stash
/build/db2/gskit/bin/gsk8capicmd_64 -cert -add -db "keyclient.kdb" -pw
"ibm123456" -label "SSLLabelClt" -file key.arm -format ascii -fips

c. Update the DB2 client configuration.

Specify the SSL keydb and stash, and restart the instance.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 279
For example:

db2 update dbm cfg using SSL_CLNT_KEYDB /build/home/db2inst2/SSL/


keyclient.kdb
db2 update dbm cfg using SSL_CLNT_STASH /build/home/db2inst2/SSL/
keyclient.sth
db2 force application all
db2stop
db2start

d. Catalog the DB2 database with the SSL protocol.

For example:

db2 catalog tcpip node SSLNODE remote <hostname> server 56110 security ssl
db2 catalog database mydb as sslmydb at node SSLNODE

e. Verify the SSL connection to the DB2 server.

For example:

db2 connect to sslmydb user db2inst1 using db2inst1

3. Prepare the Data Provisioning Agent for SSL connections.


a. Copy the SSL key from the DB2 database server to the Data Provisioning Agent installation.

Copy key.arm from the DB2 server into <DPAgent_root>/ssl/.


b. Import the DB2 server SSL key to the agent cacerts file.

Use the Java keytool to import the SSL key. By default, keytool is located in $JAVA_HOME/bin.

For example:

keytool -import -keystore <DPAgent_root>/ssl/cacerts -storepass changeit -


file <DPAgent_root>/ssl/key.arm -noprompt -alias <alias_name>

c. Configure the SSL password with the Data Provisioning Agent configuration tool.

Specify the same password used when importing the SSL key, and then restart the Data Provisioning
Agent.

Next Steps

When you create a DB2 remote source, ensure that the following parameters are set appropriately:

● Use SSL: True


● Port Number: SSL port for the DB2 database. For example, 56110.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]

Installation and Configuration Guide


280 PUBLIC Configure Data Provisioning Adapters
6.12.7 Creating a Whitelist to Limit Access to a Source
Database

There are times when you may want to limit access to all of the tables in a source database. For data
provisioning log reader adapters, as well as SAP HANA and SAP ECC adapters, an efficient way to limit access
is to create a whitelist.

Restricting access to only those tables that are to be replicated is done by creating a whitelist of source
database objects in a separate table.

 Note

The whitelist impacts only the virtual table created and the replications created after the whitelist was
created.

You can use SQL to create the whitelist table.

 Note

● The whitelist table, which can have any name, must have two columns named
REMOTE_SOURCE_NAME and WHITELIST.
● The whitelist items are separated by a comma.
● You can use an asterisk (*) to represent any character or empty string. However, the asterisk must be
placed at the end of a whitelist item. Otherwise, it is treated as a normal character.
● You can add multiple rows of whitelisted tables for a single remote source.

Microsoft SQL Server Example

create table whitelist(REMOTE_SOURCE_NAME varchar(128), WHITELIST varchar(4000));

To add a whitelist for the remote source called “localmssqldb”, insert a row into the whitelist table:

insert into whitelist values('localmssqldb', 'object.A, object.B*');


insert into whitelist values('localmssqldb', 'object.C, object.D*');

object.A, object.B*, and so on, means that the table (or procedure) object.A and the table (or procedure)
starting with object.B are filtered for the remote source “localmssqldb”.

SAP HANA Example

create schema SAP_RESTRICTIONS;


create table WHITE_LIST(REMOTE_SOURCE_NAME varchar(128) primary key, WHITELIST
varchar(4000));

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 281
To add a whitelist for the remote source called “localhadp”, insert a row into the whitelist table:

insert into WHITE_LIST values('localhadp', 'APP_USER.MERCHANT,APP_PRODUCT.B*');

APP_USER.MERCHANT,APP_PRODUCT.B* means that the table (or procedure) APP_USER.MERCHANT and


the table (or procedure) starting with APP_PRODUCT.B are filtered for remote source “localhadp”.

6.12.8 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:

Installation and Configuration Guide


282 PUBLIC Configure Data Provisioning Adapters
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.13 IBM DB2 Mainframe

The DB2 Mainframe adapter supports IBM DB2 for z/OS and IBM DB2 iSeries, which is formerly known as AS/
400.

The DB2 Mainframe adapter is a data provisioning adapter that provides DB2 client access to the database
deployed on IBM DB2 for z/OS and iSeries systems. DB2 database resources are exposed as remote objects of
the remote source. These remote objects can be added as data provisioning virtual tables. The collection of
DB2 data entries are represented as rows of the virtual table.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source for both z/OS and iSeries


● SELECT, WHERE, JOIN, GROUP BY, ORDER BY, TOP, LIMIT, DISTINCT

Related Information

Setting DB2 Universal Database Environment Variables [page 284]


IBM DB2 Mainframe Permissions [page 284]
Bind the DB2 SYSHL Package [page 285]
Preparing JDBC JAR Files [page 285]
IBM DB2 Mainframe Remote Source Configuration [page 286]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 283
6.13.1 Setting DB2 Universal Database Environment Variables

The method for setting DB2 UDB environment variables depends on the operating system.

 Note

The DB2 UDB environment variables should be set up regardless of whether your Data Provisioning Agent
is installed on the same server as the DB2 database or not. Prior to setting up the variables, be sure that
you have installed the IBM Data Server Runtime Client.

For Linux, the DB2 UDB installation provides two scripts for setting up the DB2 UDB environment variables:
db2cshrc for C shell and db2profile for Bourne or Korn shell. These scripts set the library path environment
variable based on the bit size of the installed server or client.

For Windows, the installation sets all necessary environment variables.

For Linux platforms, the 32-bit and 64-bit versions of the driver and API libraries are located in <$HOME/
sqllib/lib32>/sqllib/lib32 and <$HOME/sqllib/lib64>/sqllib/lib64, respectively, where <
$HOME> is the home directory of the DB2 UDB instance owner.

 Note

If the Data Provisioning Agent is installed on Linux, the library path environment variable must point to the
64-bit libraries. For Windows, the library path environment variable must point to the 32-bit libraries.

 Note

We recommend that you add a line to the <DPAgent_root>/bin/dpagent_env.sh file to set the
db2profile environmental variables. This ensures that when you use dpagent_service.sh to start and
stop the DPAgent service, the DB2 UDB environment variables are sourced automatically. For example, you
could add a line such as . /home/db2inst1/sqllib/db2profile.

6.13.2 IBM DB2 Mainframe Permissions

DB2 mainframe database users must have certain permissions granted to them.

The IBM DB2 Mainframe adapter requires a user with read privileges to the SYSIBM.SYSCOLUMNS system
table.

Installation and Configuration Guide


284 PUBLIC Configure Data Provisioning Adapters
6.13.3 Bind the DB2 SYSHL Package

Instructions for binding the DB2 SYSHL package.

Context

If you receive the following error from the adapter, follow these steps to bind the DB2 SYSHL package:

DB2 SQL Error: SQLCODE=-805, SQLSTATE=51002, SQLERRMC=DB1SLOC.NULLID.SYSLH

Procedure

1. Install and open the IBM DB2 Configuration Assistant.


2. In the source window, connect to the DB2 database deployed on the mainframe system.
3. Test the connection.
4. Bind the DB2 SYSHL package through the Configuration Assistant.
5. Select ddcsmvs.lst as the bind file location, enter the connection username and password, and then
click Bind.

6.13.4 Preparing JDBC JAR Files

Prepare the IBM DB2 JDBC JAR files to use one of the DB2 Mainframe adapters.

To use one of the DB2 Mainframe adapters, you are required to copy the following IBM DB2 JDBC JAR files to
the /lib folder of the Data Provisioning Agent installation directory (<DPAgent_root>\lib).

● db2jcc4.jar (Required)
You can download this file here: http://www-01.ibm.com/support/docview.wss?uid=swg21363866 .
Download the JDBC JAR file according to your DB2 database version.
● db2jcc_license_cisuz.jar (Required)
You can find information about this file here: http://www-01.ibm.com/support/docview.wss?
uid=swg21191319

You can find these JAR files in the following ways:

● These JAR files are available in the installation directory after you installed the IBM DB2 client. For
example, on a Windows system, the JAR files are located in C:\Program Files\IBM\SQLLIB\java.
● Download them from the IBM Support and Download Center.

 Note

If the source z/OS DB2 system contains a non-English CCSID table space, you are required to update the
JVM to an internationalized version. At a minimum, the charsets.jar file within the current JVM should

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 285
contain the required CharToByteCP<XXX>.class, where <XXX> corresponds to the source system’s
language locale.

6.13.5 IBM DB2 Mainframe Remote Source Configuration

Options for connecting to the remote mainframe data server. Also included is sample code for creating a
remote source using the SQL console.

Category Option Description

Generic Always Map Character Determines whether a CHAR/CHARACTER/VARCHAR/


types to Unicode
LONGVARCHAR/CLOB column in the source database is
mapped to a Unicode column type in SAP HANA when the
source database character set is non-ASCII. The default
value is False.

The value of this parameter can be changed when the re­


mote source is suspended.

Set this parameter to True only when the remote data­


base is multibyte character sets such as UTF-8, GBK,
JA16SJIS, and soon.

Database Host Host name or IP address on which the remote DB2 data
server is running.

Port Number The DB2 data server port number.

Database Name The DB2 database name.

Database Source Name The DB2 instance name.

Security Use SSL Specifies whether you are using SSL.

The default value is False.

Use Agent Stored Creden­ Set to True to use credentials that are stored in the DP
tial
Agent secure storage.

The default value is False.

Installation and Configuration Guide


286 PUBLIC Configure Data Provisioning Adapters
Category Option Description

z/OS DB2 Additional Info Bind Packages When this option is set to Yes, the DB2 mainframe
adapter automatically checks and binds all of the required
missing JAR files.

We recommend that you set this option to Yes the first


time you attempt to establish a connection, then set this
option to No for subsequent attempts.

 Note
If any necessary packages are missing, an error oc­
curs.

Setting this option for subsequent attempts helps im­


prove performance by eliminating the need for redundant
checks for the necessary JDBC packages.

Source System is AS/400 Set this parameter to Yes if your source system is AS/
(IBM I)
400.

The default value is No.

Credential Properties Credentials Mode Remote sources support two types of credential modes to
access a remote source: technical user and secondary
credentials.

● Technical User: A valid user and password in the re­


mote database. This valid user is used by anyone us­
ing the remote source.
● Secondary User: A unique access credential on the
remote source assigned to a specific user.

User Name The DB2 user with access to the tables that are added as
virtual tables in SAP HANA.

Password DB2 database user password.

Example

 Sample Code

CREATE REMOTE SOURCE "MyDB2MainframeSource" ADAPTER "DB2MainframeAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_host_name" displayName="Host">myhost.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">5950</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 287
<PropertyEntry name="pds_datasource_name" displayName="Database
SourceName">mydb</PropertyEntry>
<PropertyEntry name="bind_packages" displayName="Bind Packages">No</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]

6.14 Microsoft Excel

This adapter lets SAP HANA users access Microsoft Excel files.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● Search for tables
● SharePoint as a source
● SharePoint on Office365
● SELECT from a virtual table

Related Information

Microsoft Excel Authorizations [page 289]


Microsoft Excel Adapter Preferences [page 289]
Microsoft Excel Remote Source Configuration [page 289]
Access SharePoint Using HTTPS/SSL [page 295]

Installation and Configuration Guide


288 PUBLIC Configure Data Provisioning Adapters
Accessing Microsoft Excel Data Files in a Shared Network Directory [page 296]
Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft Office365 [page
297]
Configure Your Microsoft Azure Application [page 298]

6.14.1 Microsoft Excel Authorizations

Authorization requirements for Microsoft Excel file remote sources.

Keep the following in mind when accessing files:

● Password-protected Microsoft Excel files are not supported.


● Ensure the user account under which the Data Provisioning Agent is running has access to the Microsoft
Excel files on the local computer, a shared directory, or a SharePoint site.
● If the Microsoft Excel files are located on the same computer as the Data Provisioning Agent, the files must
be located in the same directory or a subdirectory of the Data Provisioning Agent root directory.

6.14.2 Microsoft Excel Adapter Preferences

Options for controlling the Microsoft Excel adapter.

Option Description

Access Token A password. An access token protects the Microsoft Excel files from being accessed from a
different remote source. Use this same password when creating a remote source.

6.14.3 Microsoft Excel Remote Source Configuration

Options for connecting to the remote Microsoft Excel data. Also included is sample code for creating a remote
source using the SQL console.

 Note

If you want to use a Data Provisioning Agent installed on Linux to connect to the SharePoint site, enable
Basic Authentication on the SharePoint server.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 289
Category Parameter Description

File Source File Source Type ● File System: Specifies that the Microsoft Excel
source is located in a file system.
● SharePoint: Specifies that the Microsoft Excel
source is located on a SharePoint server.
● SharePoint on Office365: Specifies that the Micro­
soft Excel source is on an Office365 server.

File System Folder The directory of Microsoft Excel files. Use a relative
path.

If you leave this parameter blank, it is set to


<DPAgent_root>/excel.

If you set the value to a relative folder name, it be­


comes a subfolder of <DPAgent_root>/excel.

For example, if you set the Folder parameter to


download/test, the Microsoft Excel file's folder is
<DPAgent_root>/excel/download/test.

If you are using a shared network directory, enter the


path as follows:

\\<host_name>\<directory>

 Note
Password-protected Microsoft Excel files are not
supported.

HANA HANA Server The SAP HANA server name

HANA Port The port used to connect to the SAP HANA server

HANA Schema The SAP HANA schema

SharePoint Server URL Enter the URL for the server where the SharePoint
source is located.

If you create a SharePoint site on the server, be sure to


include the name of the site at the end of the URL. For
example, if your server name is http://
<server_name>/ and your new site name is site1,
your URL would be http://<server_name>/site1.

Local Folder Path The path to the folder that you want to access on the
local file system where the Data Provisioning Agent is
deployed.

Installation and Configuration Guide


290 PUBLIC Configure Data Provisioning Adapters
Category Parameter Description

Table First Row as Header Determines whether the first row of the sheet is con­
sidered the header. If set to True, each column's con­
tent is used as the column name of the virtual table in
SAP HANA.

Values:

● True (Default): The columns in the first row are


used as the column names of the virtual table in
SAP HANA.
● False: The column names of the virtual table in
SAP HANA are defined as COL1, COL2, COL3, and
so on.

Start Row of Data Determines which row of the sheet is the first data row
the Microsoft Excel adapter loads into the virtual table.

The value must be no greater than the maximum row


number of the sheet.

If First Row as Header is set to True, its default value is


2.

If First Row as Header is set to False, its default value is


1.

End Row of Data Determines which row of the sheet is the last data row
the adapter loads into the virtual table.

The value must be no greater than the maximum row


number of the sheet.

By default, all rows of the sheet are loaded.

Show Hidden Column and Rows Determines whether to process the columns that are
hidden from the sheet.

Values:

● True: The hidden columns are processed as nor­


mal columns.
● False (Default): The hidden columns are ignored.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 291
Category Parameter Description

Column Filter The list of columns that are processed. Any column
that does not exist in the list is ignored.

Enter a list of column names separated by a semico­


lon.

 Note
If the Column Filter option is empty, all columns
are processed. If the Column Filter option is not
empty, only the listed columns are processed.

For example, if you set the option to


COL1;COL2;COL3, all columns other than COL1,
COL2, and COL3 are ignored.

Default: All columns are processed.

SharePoint on Office365 Authentication Mode Choose the type of credentials needed to access
SharePoint on Office365

● Client Credential (default)


● Username Password:

Site URL Enter the site URL, in the form of https://


<company>.sharepoint.com/sites/<siteName>

Application ID Enter the application ID, as defined in the Microsoft


Azure Portal.

Tenant ID Enter the tenant ID, as defined in the Microsoft Azure


Portal.

Local Folder Path The path to the folder that you want to access on the
local file system where the Data Provisioning Agent is
deployed.

Credentials Credentials mode Remote sources support two types of credential


modes to access a remote source: technical user and
secondary credentials.

● Technical User: A valid user and password in the


remote database. This valid user is used by any­
one using the remote source.
● Secondary User: A unique access credential on
the remote source assigned to a specific user.

User Token User Token for Excel Folder Access The same password as the adapter Access Token pref­
erence. If this parameter is left blank or is different
from the Access Token, the remote source is not al­
lowed to read the Microsoft Excel files. Microsoft Excel
Adapter Preferences [page 289]

HANA Credential The SAP HANA user name.

Installation and Configuration Guide


292 PUBLIC Configure Data Provisioning Adapters
Category Parameter Description

HANA Password The SAP HANA password.

SharePoint Credential SharePoint logon (Domain\User­ The domain and user name for the SharePoint ac­
Name) count.

SharePoint Password The password for the SharePoint account.

SharePoint on Office365 Client Credential Enter the client secret you created on the Microsoft
Credential Azure Portal.

SharePoint on Office365 Username Enter the username for the Microsoft account
Username Password

Password Enter the password for the Microsoft account.

The following code samples illustrate how to create a remote source using the SQL console.

Local file system

Example

 Sample Code

CREATE REMOTE SOURCE "MyExcelSource" ADAPTER "ExcelAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyEntry name="FileSourceType">File System</PropertyEntry>
<PropertyGroup name="File System" displayName="File System">
<PropertyEntry name="folder" displayName="Folder">myfolder</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="Table" displayName="Table">
<PropertyEntry name="firstRowAsHeader" displayName="First Row as
Header">true</PropertyEntry>
<PropertyEntry name="rowMin" displayName="rowMin">2</PropertyEntry>
<PropertyEntry name="showHiddenColRow" displayName="Show Hidden Column
and Rows">false</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="usertoken">
<password>mytoken</password>
</CredentialEntry>';

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 293
SharePoint location

Example

 Sample Code

CREATE REMOTE SOURCE "MyExcelSource" ADAPTER "ExcelAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyEntry name="FileSourceType" type="STRING">SharePoint</PropertyEntry>
<PropertyGroup name="SharePoint">
<PropertyEntry isRequired="false" name="ServerUrl" type="STRING">http://
myhost.sap.corp/mysharepointsite</PropertyEntry>
<PropertyEntry isRequired="false" name="LocalFolder"
type="STRING">mySubFolder</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="Table" displayName="Table">
<PropertyEntry name="firstRowAsHeader" displayName="First Row as
Header">true</PropertyEntry>
<PropertyEntry name="rowMin" displayName="rowMin">2</PropertyEntry>
<PropertyEntry name="showHiddenColRow" displayName="Show Hidden Column
and Rows">false</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="usertoken">
<password>mytoken</password>
</CredentialEntry>
<CredentialEntry name="sharePointCredential">
<user>mydomain\mysharepointuser</user>
<password>mypassword</password>
</CredentialEntry>';

Example: Microsoft SharePoint on Office365

CREATE REMOTE SOURCE "MyExcelSource" ADAPTER "ExcelAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyEntry isRequired="false" name="FileSourceType"
type="STRING">SharePointOnOffice365</PropertyEntry>
<PropertyGroup name="SharePointOnOffice365">
<PropertyEntry name="AuthenticationMode">ClientCredential</PropertyEntry>
<PropertyEntry name="SiteUrl">https://mycompany.sharepoint.com/sites/
mysharepointsite</PropertyEntry>
<PropertyEntry name="ApplicationId">myApplicationID</PropertyEntry>
<PropertyEntry name="TenantId">myTenantId</PropertyEntry>
<PropertyEntry name="LocalFolder">mySubFolder</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="Table" displayName="Table">
<PropertyEntry name="firstRowAsHeader" displayName="First Row as
Header">true</PropertyEntry>
<PropertyEntry name="rowMin" displayName="rowMin">2</PropertyEntry>
<PropertyEntry name="rowMax" displayName="rowMax"></PropertyEntry>

Installation and Configuration Guide


294 PUBLIC Configure Data Provisioning Adapters
<PropertyEntry name="showHiddenColRow">false</PropertyEntry>
<PropertyEntry name="columnVisibility"></PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="usertoken"><password>mytoken</password>
</CredentialEntry>
<CredentialEntry name="sharePoint365Credential">
<password>myClientSecret</password>
</CredentialEntry>';

Related Information

Accessing Microsoft Excel Data Files in a Shared Network Directory [page 296]

6.14.4 Access SharePoint Using HTTPS/SSL

Information about how to access SharePoint using HTTPS/SSL.

Context

You can access the SharePoint server using HTTPS or SSL. You first must download the SharePoint certificate
(CER) and configure your system.

Procedure

1. Navigate to <DPAgent_root>/ssl folder.


2. Run the command to change the default keystore password changeit.

c:\<user>\dpagent\ssl>keytool -storepasswd -keystore cacerts


Enter keystore password:changeit
New keystore password:
Re-enter new keystore password:

 Note

Keytool is in the jre/bin folder. Add it to the $PATH environment. For example, C:\Program Files
\Java\jre7\bin\keytool.exe

3. Import the certificate that you exported.

c:\<user>\dpagent\ssl>keytool.exe -importcert -keystore c:\user\dpagent\ssl


\cacerts
-storepass <New Key Store Password> -file C:\<user>\dpagent\ssl
\SharePointSSL.cer

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 295
Owner: CN=RQA16CWIN2.sjc.sap.corp
Issuer: CN=RQA16CWIN2.sjc.sap.corp
Serial number: 34973632d6cb31934fdfbe04352cc5dc
Valid from: Thu Jan 05 01:29:45 PST 2017 until: Thu Jan 04 16:00:00 PST 2018
Certificate fingerprints:
MD5: 0C:7E:CA:38:1B:1E:2A:2A:47:21:78:86:50:1C:85:CE
SHA1: 25:CE:CF:F8:9A:2C:70:0A:66:CD:39:D5:C5:EC:10:4D:57:42:28:0B
SHA256: 40:80:A0:E1:56:1A:9A:F4:9F:63:20:37:F3:41:B0:27:B6:1F:9C:
33:3C:
0A:E8:79:0B:91:7E:E6:6B:E8:08:3A
Signature algorithm name: SHA1withRSA
Version: 3
Extensions:
#1: ObjectId: 2.5.29.37 Criticality=false
ExtendedKeyUsages [
serverAuth
]
#2: ObjectId: 2.5.29.15 Criticality=false
KeyUsage [
Key_Encipherment
Data_Encipherment
]
Trust this certificate? [no]: yes
Certificate was added to keystore

4. Open the dpagentconfig tool in <DPAgent>_root/configTool/dpagentconfigtool.exe. Click


Configure SSL and input the keystore file path and password that you used in the previous step.
5. If you are not using the TCP SSL connection between SAP HANA and the DP Agent, clear the Use SSL to
communicate with HANA on Cloud and Enable SSL for Agent to HANA communication on TCP parameters.
6. Open <DPAgent_root>/dpagent.ini, and add the following configuration:

-Djavax.net.ssl.trustStore=<keystore file path>

For example: -Djavax.net.ssl.trustStore=C:\<user>\dpagent\ssl\cacerts


7. Restart the DP Agent.

6.14.5 Accessing Microsoft Excel Data Files in a Shared


Network Directory

Information about how to use a shared network directory for data files with the Microsoft Excel adapter.

You can access Microsoft Excel data files in a shared directory, however you must follow a few rules:

Windows

When using Windows, make sure that you first manually access the network folder using a user name and
password before trying to connect via creating a remote source.

Installation and Configuration Guide


296 PUBLIC Configure Data Provisioning Adapters
Linux

To access a Linux network folder, mount the folder under the Data Provisioning Agent root installation
directory.

Excel Adapter Remote Source Parameters

Observe the instructions for the Folder parameter when creating your Microsoft Excel remote source.

Related Information

Microsoft Excel Remote Source Configuration [page 289]

6.14.6 Register an Application on Microsoft Azure Portal to


Enable Access to SharePoint on Microsoft Office365

You must register an application on Microsoft Azure Portal as a precondition for using the Microsoft Graph API,
which is what allows you to access SharePoint on Office365 using the File or Microsoft Excel adapters.

Procedure

1. Go to https://portal.azure.com and sign in with your Microsoft account.


2. Navigate to Azure Active Directory, and click App registrations.
3. Click New registration.
4. Choose a name for your Data Provisioning Agent--for example, sdi-dpagent--to use as the name for your
application.
5. Choose the proper Supported account types: either Account in this organizational directory only or
Accounts in any organizational directory.
6. Leave Redirect URL empty, and click Register.

Next Steps

After registration, note the application (client) ID and Directory (tenant) ID, which you use during remote
source configuration.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 297
Related Information

File Adapter Remote Source Configuration [page 190]


Configure Your Microsoft Azure Application [page 221]

6.14.7 Configure Your Microsoft Azure Application

Configure your Azure application to set up your credentials and Microsoft Graph API.

Context

Further configuration of your Azure application is necessary to create credentials for when you create a remote
source. You must also grant permissions for using the Microsoft Graph API.

Procedure

1. Click Authentication to configure the client type.

If you want to authenticate using the username and password mode, set the Default client type to Yes.

If you want to authenticate the Client Credential mode, set the Default client type to No.

a. If you chose to authenticate using Client Credential mode, create a credential by clicking Certificates &
secrets. If you chose to authenticate using the username and password mode, skip to step 2.
b. Click New client secret, give it a name and an expiration time, and click Add.
c. Note the secret password for use during remote source creation.
2. Add permissions by clicking API permissions on the application page, and then clicking Add a permission.
3. Click Microsoft Graph.
4. If you use the Client Credential mode, click Application Permission. If you use the Username and password
mode, click Delegated permission.
5. Add the following permissions:
○ Directory.Read.All
○ Files.Read.All
○ Group.Read.All
○ Sites.Read.All
○ User.Read.All
6. Grant consent for these permissions.
If you have and administrator role, click Grant consent.

If you do not have an administrator role, ask your administrator to grant permission for you.

Installation and Configuration Guide


298 PUBLIC Configure Data Provisioning Adapters
 Note

If permissions are not granted, you will not be able to access SharePoint Office365.

Every time a permission is changed, you should redo the grant operations.

Next Steps

You can now create your remote source, using the information created while setting up your Microsoft Azure
Portal application.

Related Information

File Adapter Remote Source Configuration [page 190]


Register an Application on Microsoft Azure Portal to Enable Access to SharePoint on Microsoft Office365 [page
220]

6.15 Microsoft Outlook

Access Microsoft Outlook data by using the Outlook adapter.

You can access Microsoft Outlook data stored in a PST file using the Outlook adapter.

This adapter supports the following functionality:

● Virtual table as a source

Related Information

Microsoft Outlook Adapter Preferences [page 299]


Microsoft Outlook Remote Source Configuration [page 300]

6.15.1 Microsoft Outlook Adapter Preferences

Configuration parameters for the Microsoft Outlook adapter.

You can adjust Microsoft Outlook adapter settings in the Data Provisioning Agent Configuration Tool by running
<DPAgent_root>/configTool/dpagentconfigtool.exe.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 299
Parameter Description

Access Token A password to access Microsoft Outlook PST files. This exact
value must be used when setting up a Microsoft Outlook re­
mote source.

6.15.2 Microsoft Outlook Remote Source Configuration

Configuration settings for accessing a Microsoft Outlook source. Also included is sample code for creating a
remote source using the SQL console.

Configure the following options in smart data access to configure your connection to a Microsoft Outlook PST
file.

Option Description

PST File Location Specifies the path and file name to the PST file from which the adapter will read. The
user of the Data Provisioning Agent must have permission to access this PST file.

Ignore Extra Folder Select True to not show any irrelevant folders when browsing metadata.

Credentials Mode Remote sources support two types of credential modes to access a remote source:
technical user and secondary credentials.

● Technical User: A valid user and password in the remote database. This valid user
is used by anyone using the remote source.
● Secondary User: A unique access credential on the remote source assigned to a
specific user.

PST File Access Token Specifies the access token. This value must be the same as the Access Token value in
the Outlook adapter preferences set in the Data Provisioning agent configuration tool.

Example

 Sample Code

CREATE REMOTE SOURCE "MyOutlookSource" ADAPTER "OutlookAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations" displayName="Configurations">
<PropertyGroup name="PSTFileInformation" displayName="PST File Information">
<PropertyEntry name="PSTLocation" displayName="PST File Location"
>mymail.pst</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="PstAccessToken">
<password>mytoken</password>

Installation and Configuration Guide


300 PUBLIC Configure Data Provisioning Adapters
</CredentialEntry>';

6.16 Microsoft SQL Server Log Reader

Use the Microsoft SQL Server Log Reader adapter to batch load to SAP HANA or to replicate changed data in
real time from a database to SAP HANA.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

 Note

The user configured during the installation of the Data Provisioning Agent must have read access to the
transaction log, which is the .ldf file.

 Note

If you are using Microsoft SQL Server on Amazon RDS or Microsoft Azure, observe the following limitations:

● To avoid remote access issues in Amazon RDS, ensure the database instance setting Publicly
Acccessible has been enabled.
● Real-time replication is not supported.

Adapter Functionality

This adapter supports the following functionality:

Feature SQL Server (on premise)

Virtual table as a source Yes

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 301
Feature SQL Server (on premise)

Realtime change data capture (CDC) Yes. Both log reader and trigger-based realtime replication
are supported

 Note
● Log Reader adapters do not support the truncate
table operation.
● The Microsoft SQL Server Log Reader adapter does
not support WRITETEXT and UPDATETEXT.
● For CDC replication, data imported into Microsoft
SQL Server using the bcp tool is not supported be­
cause the tool bypasses writing to the Microsoft
SQL Server transaction logs.

Virtual table as a target using a Data Sink node in a flow- Yes


graph

Connect multiple remote sources in HANA to the same Yes


source database

Loading options for target tables Yes

DDL propagation Yes

The supported schema changes are:

● ADD COLUMN
● DROP COLUMN
● RENAME TABLE
● RENAME COLUMN
● ALTER COLUMN DATATYPE

 Note
For trigger-based CDC, the supported schema changes
are:

● ADD COLUMN
● DROP COLUMN
● ALTER COLUMN DATA TYPE

Replication monitoring and statistics Yes

Search for tables Yes

Virtual procedures Yes

In addition, this adapter supports the following capabilities:

● Global: SELECT, INSERT, UPDATE, DELETE

Installation and Configuration Guide


302 PUBLIC Configure Data Provisioning Adapters
● Select: WHERE, JOIN, GROUP BY, DISTINCT, TOP or LIMIT, ORDER BY

Related Information

Microsoft SQL Server Real-time Replication [page 303]


MssqlLogReaderAdapter Preferences [page 322]
Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Using a Schema Alias [page 337]
Log Reader Adapter Log Files [page 338]
Configure SSL for the Microsoft SQL Server Log Reader Adapter [page 338]
Configuring Windows Authentication [page 340]
Creating a Whitelist to Limit Access to a Source Database [page 341]
Disable Adapter Write-back Functionality [page 342]
Configure Microsoft Windows Authentication [page 343]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

Amazon Virtual Private Cloud (VPCs) and Amazon RDS

6.16.1 Microsoft SQL Server Real-time Replication

Information about setting up your source system and adapter for real-time replication.

 Note

Real-time replication is not supported with Microsoft SQL Server on Amazon RDS or Microsoft Azure.

Related Information

Remote Database Setup for Microsoft SQL Server Real-time Replication [page 304]
Installing Data Provisioning Agent and Microsoft SQL Server on Different Servers [page 314]
Connecting Multiple Remote Sources to the Same SQL Server Source Database [page 316]
Remote Database Cleanup for Microsoft SQL Server Real-time Replication [page 316]
Validate the Microsoft SQL Server Log Reader Environment [page 317]
Generate a Log Reader Remote Source Creation Script [page 318]
Microsoft SQL Server Trigger-Based Replication [page 319]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 303
6.16.1.1 Remote Database Setup for Microsoft SQL Server
Real-time Replication

The remote database must be set up properly for Log Reader adapters to function correctly when using real-
time replication.

This setup process is necessary only when using real-time replication.

Real-time Replication Limitations

The following limitations exist when performing real-time replication:

● Unsupported table types:


○ Table with all LOB columns
○ Table with non-persisted computed columns as part of primary keys.

 Note

If the non-persisted computed columns are not part of primary keys, values for these columns will
be propagated to the target table during initial load. However, because changes in values for these
columns are not recorded in transaction logs, the changed values for these columns cannot be
replicated during realtime (CDC), and they will be set to NULL for the changed rows.

○ Table with LOB column and no primary key or unique index


○ Table with duplicated rows and no primary key
○ Table with user-defined identifier
○ Nested table
○ Table with REF constraint
○ Table with a clustered column store index
● WRITETEXT and UPDATETEXT
● Update LOB data types using a LIKE statement
● Big size TEXT data using BCP

 Note

The Microsoft SQL Server Log Reader relies on database logs to perform data movement. Logs must be
available until the data is successfully read and replicated to the target SAP HANA database. To ensure that
the data is replicated to SAP HANA, configure Microsoft SQL Server in Full Recovery Mode.

 Restriction

Microsoft SQL Server with Transparent Data Encryption (TDE) is not supported.

Real-time replication for Microsoft SQL Server relies on the ability of the adapter to read transactions from
physical log files. Because these files are encrypted by Microsoft SQL Server, the adapter cannot read the
transactions, so consequently real-time capability is not available.

Installation and Configuration Guide


304 PUBLIC Configure Data Provisioning Adapters
Related Information

Create Users and Grant Privileges [page 305]


Enable Remote Dedicated Administrator Connection (DAC) [page 305]
Enable TCP/IP [page 307]
Configure the Primary Data Server for the First Time [page 308]
Run a Microsoft SQL Server Log Reader Adapter on Linux [page 309]
Configure a Microsoft SQL Server Log Reader Adapter with Always On Support [page 311]
Configure a Microsoft SQL Server Log Reader Adapter with Failover Cluster Support [page 313]

6.16.1.1.1 Create Users and Grant Privileges

Follow these steps to create users and grant privileges.

Procedure

1. Create a Microsoft SQL Server user, for example DP_USER, for the remote source.
2. Grant the required privileges as follows:

use master
go
create login DP_USER with password =‘MyPW’
go
use <primary database>
go
create user DP_USER for login DP_USER
go
EXEC sp_addsrvrolemember ‘DP_USER’, ‘sysadmin’
go

6.16.1.1.2 Enable Remote Dedicated Administrator


Connection (DAC)

Follow these steps to enable DAC to allow remote connections.

Procedure

1. Log on to Microsoft SQL Server using the newly created user, and change the Microsoft SQL Server
remote admin connections configuration option to enable DAC to allow remote connections:

sp_configure 'remote admin connections', 1

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 305
go

2. Update the remote administrator connection setting:

reconfigure
go

3. Verify the remote admin connections string:

sp_configure 'remote admin connections'


go

Related Information

Make Log Files Readable [page 306]

6.16.1.1.2.1 Make Log Files Readable

Install and set up the sybfilter driver so that the Log Reader can read the primary transaction log files.

Prerequisites

On Windows Server 2008 R2, Windows Security Update KB3033929 must already be installed on the host
system.

Procedure

1. In Windows Explorer, navigate to the sybfilter driver installation directory. This directory is located at
<DPAgent_root>\LogReader\sybfilter\system\<platform>, where <DPAgent_root> is the root
directory or Data Provisioning Agent installation and <platform> is either winx86 or winx64.

○ winx86 is for 32-bit Windows Server 2008, Windows Server 2008 R2, and Windows 7
○ winx64 is for 64-bit Windows Server 2008, Windows Server 2008 R2, and Windows 7
2. Right-click sybfilter.inf, and click Install to install the sybfilter driver.
3. Under any directory, create a configuration file to save all log file paths for primary databases. The
configuration file must have a .cfg suffix. For example, under <DPAgent_root>\LogReader
\sybfilter\system\<platform>, create a file named LogPath.cfg.
4. Add a system environment variable named <RACFGFilePath>, then set its value to the path and file name
of the configuration file.

Installation and Configuration Guide


306 PUBLIC Configure Data Provisioning Adapters
5. In Windows Explorer, navigate to <DPAgent_root>\LogReader\sybfilter\bin\, right-click the
sybfiltermgr.exe file, then select Run as administrator to access the sybfilter driver management
console.
6. To start the sybfilter driver, enter start at the management console.
7. Add the log file path to the sybfilter driver with the user manager or by modifying the configuration file
directly:

○ User manager: Use the add command in the management console. The syntax for this command is
add serverName dbName logFilePath. For example, to add the log file named pdb1_log.ldf for
the database pdb1 on the data server PVGD50857069A\MSSQLSERVER, use the following: add
PVGD50857069A\MSSQLSERVER pdb1 C:\Mssql2012\MSSQL11.MSSQLSERVER\MSSQL\DATA
\pdb1_log.ldf
○ Add the following into the LogPath.cfg file directly:

[PVGD50857069A\MSSQLSERVER, pdb1]

log_file_path=C:\Mssql2012\MSSQL11.MSSQLSERVER\MSSQL\DATA\pdb1_log.ldf

8. Refresh the configuration with the newly-added path.


In the sybfilter management console, enter refresh and press Enter .
9. If Microsoft SQL Server was running while the log paths were added, restart it to make the log files
readable.
10. Verify whether the log files are readable.
In the sybfilter management console, enter check and press Enter .

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

6.16.1.1.3 Enable TCP/IP

Follow these steps to enable TCP/IP for the Microsoft SQL Server adapter.

Procedure

1. Go to SQL Server Configuration Tool, and choose SQL Server Configuration Manager SQL Server
Network Configuration Protocols for <SQLInstanceName> , where <SQLInstanceName> is your
Microsoft SQL Server instance.
2. Right-click TCP/IP, and choose Enable.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 307
6.16.1.1.4 Configure the Primary Data Server for the First
Time

Configure the primary data server.

Context

Before you can begin using the SQL Server Log Reader adapter, you must configure the primary data server.

 Note

If the Database Data Capture Mode parameter is set to MSSQL CDC Mode when you create a remote
source, this step is not necessary.

 Note

If you are using Microsoft SQL Server installed on Windows 2012 and later, you must restart Microsoft SQL
Server in single-user mode from the command line opened with the Run as Administrator parameter
enabled.

Procedure

1. Stop the Microsoft SQL Server service.

a. In Control Panel Administrative Tools Services , find the service named MicrosoftSQLServer
(<SERVER>), where <SERVER> is the name of your Microsoft SQL Server data server. For example,
Microsoft SQL Server (TEAMSTER).
b. Right-click your Microsoft SQL Server instance and choose Properties.
c. In the General tab, click Stop.

 Tip

You can also stop Microsoft SQL Server in single-user mode from the command line using
Administrator privileges.

For example, if you started the instance using a command prompt, enter Ctrl+C in the window and
enter Y to stop it.

2. Restart Microsoft SQL Server in single-user mode.

a. Click Start Control Panel Administrative Tools Services .


b. Right-click your Microsoft SQL Server instance, and choose Properties.
c. In the General tab, click Stop.
d. Under Start parameters, enter –m .
e. Switch to the Log On tab, make note of the account, then change to a user who has Administrator
privileges.

Installation and Configuration Guide


308 PUBLIC Configure Data Provisioning Adapters
f. Click Start.

 Tip

Restart Microsoft SQL Server in single-user mode from the command line using Administrator
privileges.

For example, Run > C:\Program Files\Microsoft SQL Server\MSSQL12.MSSQLSERVER


\MSSQL\Binn>> .\sqlservr.exe -sMSSQLSERVER -m

3. Connect to Microsoft SQL Server using dedicated administrator connection (DAC).


a. In Microsoft SQL Server Management Studio, with no other DACs open, click Database Engine Query
on the toolbar.
b. In the Connect to Database Engine dialog box, in the Server name box, type ADMIN:, followed by the
name of the server instance. For example, to connect to a server instance named ACCT\PAYABLE,
type ADMIN:ACCT\PAYABLE.
c. Complete the Authentication section, providing credentials for a member of the sysadmin group, and
then click Connect.

The connection is made. If the DAC is already in use, the connection fails with an error indicating it
cannot connect.
4. To initialize the server, execute script <DPAgent_root>\LogReader\scripts
\mssql_server_init.sql. Script <DPAgent_root>\LogReader\scripts
\mssql_server_deinit.sql can be used to de-initialize the server if necessary.

5. Open the Microsoft SQL Server service properties window: by clicking Start Control Panel
Administrative Tools Services , then right-click your Microsoft SQL Server instance, and choose
Properties. Then, recover the user account to the previous value in the Log On tab.
6. Stop and restart the Microsoft SQL Server service back to normal mode.

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

6.16.1.1.5 Run a Microsoft SQL Server Log Reader Adapter on


Linux

Learn how to set up your environment to run your Microsoft SQL Server database on one computer and run the
Data Provisioning Agent on a separate Linux computer.

Context

The following is an example of how to set up an environment with a SQL Server database named “mypdb”
installed on Windows computer A and a Data Provisioning Agent installed on Linux computer B.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 309
Procedure

1. Install the Data Provisioning Agent on computer B (Linux).


2. Configure Sybfilter on computer A (Windows computer where the Microsoft SQL Server database is
installed). You can copy Sybfilter from the Data Provisioning Agent installation directory on computer B.
For example, <DPAgent_root>/LogReader/Sybfilter).
3. Run the following SQL query to get the exact location of the log files:

SELECT physical_name FROM sys.database_files WHERE type=1;

For example, you might get a return of the following paths:


○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
\mypdb_log.ldf
○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
\mypdb_log_2.ldf
○ C:\MSSQL_LOG\mypdb\mypdb_log_3.ldf
4. Share the SQL Server transaction log directory and mount to the Linux computer.

For example, in step 2, the Microsoft SQL log files are stored in two directories:
○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
○ C:\MSSQL_LOG\mypdb
Share the two directories on computer A, and then mount the two directories on computer B.
a. Create a directory on computer B where you want to mount the MSSQL log file folder. For example,
create directories on computer B named /MSSQL_share_folder1 and /MSSQL_share_folder2.
b. On computer B execute the following command:

For SLES SP 11:

sudo mount -v -t cifs -o


username=<computer_A_login_name>,password=<computer_A_login_password>,domai
n=<computer_A_login_name_domain>,ro,cache=none,directio
<computer_A_share_directory ><computer_B_mouted_directory>

For SLES SP 12 and above:

sudo mount -v -t cifs -o


username=<computer_A_login_name>,password=<computer_A_login_password>,domai
n=<computer_A_login_name_domain>,ro,cache=none <computer_A_share_directory
><computer_B_mouted_directory>

c. Assuming that the username/password for computer A is ABC/123456, the logon domain is localhost,
and the share name of the MSSQL log file folder on computer A is //10.172.162.145/DATA and //
10.172.162.145/mypdb, you can execute the following command to mount the MSSQL log file folder on
computer B:

sudo mount -v -t cifs -o


username=ABC,password=123456,domain=localhost,ro,cache=none //
10.172.162.145/DATA /MSSQL_share_folder1

Installation and Configuration Guide


310 PUBLIC Configure Data Provisioning Adapters
and

sudo mount -v -t cifs -o


username=ABC,password=123456,domain=localhost,ro,cache=none //
10.172.162.145/mypdb /MSSQL_share_folder2

5. Configure the mssql_log_path_mapping.props file on computer B.

Open the file <DPAgent_root/Logreader/config/mssql_log_path_mapping.props> and add the


following information into the mssql_log_path_mapping.props file, assuming the database name
you use is R01: [R01] C:\Program Files\Microsoft SQL Server
\MSSQL11.MSSQL2K12SP1\MSSQL\DATA=/MSSQL_share_folder1 C:\MSSQL_LOG\mypdb=/
MSSQL_share_folder2.
6. Open SAP HANA Web IDE and log in.
7. Create a Microsoft SQL Server remote source, and open the remote source configuration page. In the
remote source configuration page, expand the Configurations category and expand the Database option.
8. Make sure that the Use Remote Database option is set to True.

Related Information

Install the Data Provisioning Agent [page 42]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

6.16.1.1.6 Configure a Microsoft SQL Server Log Reader


Adapter with Always On Support

More steps are necessary when configuring a Microsoft SQL Server Log Reader Adapter to connect to a
Microsoft SQL Server host that uses Always On Availability Groups.

Prerequisites

Before you can configure the log reader adapter with Always On support, Microsoft SQL Server must be
configured with an Availability Group Listener. For more information, see the Microsoft SQL Server
documentation.

Context

The following is an example that shows you how to set up an environment with a Microsoft SQL Server
database named “mypdb”. The database is also configured with an Always On Availability Group with a
secondary database, in addition to the primary database.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 311
Procedure

1. Install and configure Sybfilter on each host in the Microsoft SQL Server Always On Availability Group,
including the primary and secondary databases.
You can copy Sybfilter from the agent installation directory on the Data Provisioning Agent host. For
example, C:\usr\sap\dataprovagent\LogReader\sybfilter.
2. Run a SQL query to get the exact location of the log files.

SELECT physical_name FROM sys.database_files WHERE type=1;

For example, you might get a return of the following path:

C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA


\mypdb_log.ldf

3. Share the folders that contain “mypbd” database log files on each host computer in the Always On
Availability Group.

 Note

Grant READ permissions for the shared folders to the DPAGENT user on each host in the Always On
Availability Group. If you haven't done so already, make sure that your log files are readable by following
the instructions in Make Log Files Readable [page 306].

For example, share the folder C:\Program Files\Microsoft SQL Server


\MSSQL11.MSSQL2K12SP1\MSSQL\DATA.
4. Edit and include the mapping relationship into the mssql_log_path_mapping.props file as shown in the
following example. Also, provide the database name as shown in the following example.

○ Because the mapping is based on a parent directory and not on the log file itself, only one entry is
sufficient for both mypdb_log.ldf and mypdb_log_2.ldf.
○ Put the original path on the left side of the equal sign and the UNC pathname of each share folder on
the right side, separated by semicolons.

For example, suppose that you are connecting to the database “mypdb”, with the primary database on
computer A and one secondary database on computer B.

[myrs:mypdb]
C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA=\
\<host_name_A>\mssql_data;\\<host_name_B>\mssql_data

5. When you create the remote source, set the value of the SQL Server Always On parameter to True and
specify the Availability Group Listener Host and Availability Group Listener Port.

 Tip

We recommend that you also set Database Data Capture Mode to MS SQL CDC Mode. If you do not use
the Microsoft CDC data capture mode, you need to execute server-level initialization scripts on each
host in the Always On Availability Group.

Installation and Configuration Guide


312 PUBLIC Configure Data Provisioning Adapters
6.16.1.1.7 Configure a Microsoft SQL Server Log Reader
Adapter with Failover Cluster Support
More steps are necessary when configuring a Microsoft SQL Server Log Reader Adapter to connect to a
Microsoft SQL Server host that is part of a failover cluster.

Context

The following procedure is an example, which shows you how to set up an environment with a Microsoft SQL
Server database named “mypdb” that is configured as part of a failover cluster.

Procedure

1. Install and configure Sybfilter on each host in the failover cluster, including the primary and secondary
databases.
You can copy Sybfilter from the agent installation directory on the Data Provisioning Agent host. For
example, C:\usr\sap\dataprovagent\LogReader\sybfilter.
2. Run a SQL query to get the exact location of the log files.

SELECT physical_name FROM sys.database_files WHERE type=1;

For example, you might get a return of the following path:

C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA


\mypdb_log.ldf

3. Share the folders that contain mypbd database log files on the active node of the failover cluster.

 Note

Grant READ permissions for the shared folder to the DPAGENT user. If you haven't done so already,
make sure that your log files are readable by following the instructions in Make Log Files Readable
[page 306].

For example, share the folder C:\Program Files\Microsoft SQL Server


\MSSQL11.MSSQL2K12SP1\MSSQL\DATA.
4. Edit and include the mapping relationship into the mssql_log_path_mapping.props file as shown in the
following example. Also, provide the database name as shown in the following example.
○ Because the mapping is based on a parent directory and not on the log file itself, only one entry is
sufficient for both mypdb_log.ldf and mypdb_log_2.ldf.
○ Put the original path on the left side of the equal sign and the UNC pathname of the share folder on the
right side.

[myrs:mypdb]
C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA=\
\<host_name>\mssql_data

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 313
5. When you create the remote source, set the value of the Use Remote Database parameter to True.

Results

By default, during a failover event, the agent tries to reopen an inaccessible log file three times at intervals of 5
seconds. If the agent is unable to open the log file after these attempts, the task fails.

You can modify the number of attempts and the retry interval by changing the lr_reopen_device_times
and lr_reopen_device_interval parameters in <DPAgent_root>\LogReader\config\mssql.cfg.

6.16.1.2 Installing Data Provisioning Agent and Microsoft


SQL Server on Different Servers

More steps are necessary when installing the Data Provisioning Agent and Microsoft SQL server on different
computers.

Context

The following example shows you how to set up an environment with a Microsoft SQL Server database named
“ mypdb” on computer A and a Data Provisioning Agent installed on another computer B.

Procedure

1. Install and configure Sybfilter on computer A (<host_name>).

Sybfilter can be copied from the Data Provisioning Agent installation directory on computer B. For
example, C:\usr\sap\dataprovagent\LogReader\sybfilter.
2. Run a SQL query to get the exact location of the log files.

SELECT physical_name FROM sys.database_files WHERE type=1;

For example, you might get a return of the following paths:


○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
\mypdb_log.ldf
○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
\mypdb_log_2.ldf
○ C:\MSSQL_LOG\mypdb\mypdb_log_3.ldf
3. Share the folders that contain mypbd database log files on computer A.

Installation and Configuration Guide


314 PUBLIC Configure Data Provisioning Adapters
 Note

Grant READ permissions for the shared folders to the DPAGENT user on computer B. If you haven't
done so already, make sure that your log files are readable by following the instructions in Make Log
Files Readable [page 306].

For example, share the folders:


○ C:\MSSQL_LOG\mypdb
○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA
4. Edit and include the mapping relationship into the mssql_log_path_mapping.props file as shown in the
following example. Also, provide the database name, as shown in the following example.

○ Because the mapping is based on a parent directory and not on the log file itself, only one entry is
sufficient for both mypdb_log.ldf and mypdb_log_2.ldf
○ Put the original path on the left side of the equal symbol and the UNC path name of the share folder on
the right side.

○ C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQL2K12SP1\MSSQL\DATA=\


\<host_name>\mssql_data
○ C:\MSSQL_LOG\mypdb=\\<host_name>\mssql_log\mypdb
○ You can also include multiple databases in the same file.
5. If you are using remote databases, you should edit the mssql_log_path_mapping.props file to
differentiate database names and instances.

For example, suppose that you have the following scenario:


○ User1 creates remote source RS1 connecting to DB1
○ User2 creates remote source RS2 connecting to DB2
In this case, you would add the following to the mssql_log_path_mapping.props file:

If DB1 and DB2 have different names:

[DB1]
D:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA=\
\computer1\mssql_data
[DB2]
D:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA=\
\computer2\mssql_data

If DB1 and DB2 have the same name, add a remote source name to differentiate:

[RS1:DB1]
D:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA=\
\computer1\mssql_data
[RS2:DB1]
D:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA=\
\computer2\mssql_data

6. When you create the remote source, set the value of the Use Remote Database parameter to True.

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 315
Make Log Files Readable [page 306]

6.16.1.3 Connecting Multiple Remote Sources to the Same


SQL Server Source Database

You can connect multiple remote sources to the same remote database, providing that you meet the following
conditions:

● Each remote source uses a unique schema, specified in the LogReader Objects Schema in Remote
Database remote source configuration parameter.
● Each remote source uses a unique name, in case the remote sources are created on different SAP HANA
instances.

6.16.1.4 Remote Database Cleanup for Microsoft SQL Server


Real-time Replication

Run SQL scripts to disable replication and clean up objects manually from the Microsoft SQL Server source
database.

Cleanup scripts disable replication of a source database and drop database-level objects. Usually, you do not
need to execute a cleanup script after an adapter is dropped, because replication is disabled and the adapter
automatically drops database-level objects. However, in some cases, if any errors occur during or before
automatically disabling replication and dropping these objects, the replication may still be enabled and objects
may not be dropped. At that point, you may need to execute the cleanup script to drop the objects.

You can find the Microsoft SQL Server cleanup script files at <DPAgent_root>\LogReader\scripts.

The script to be executed depends on which Database Data Capture Mode you select in your remote source
configuration. If you select MSSQL CDC Mode, execute mssql_logreader_mscdc_cleanup.sql. If you
select Native Mode, execute mssql_logreader_native_cleanup.sql.

You can find Trigger-based cleanup scripts at <DPAgent_root>\Trigger.

Installation and Configuration Guide


316 PUBLIC Configure Data Provisioning Adapters
6.16.1.5 Validate the Microsoft SQL Server Log Reader
Environment

You can use the Data Provisioning Agent command-line configuration tool to validate the configuration of the
Microsoft SQL Server log reader environment, before creating remote sources that use the SQL Server Log
Reader adapter.

Prerequisites

Before validating the log reader environment, be sure that you have downloaded and installed the correct JDBC
libraries. For information about the proper JDBC library for your source, see the SAP HANA Smart Data
Integration Product Availability Matrix (PAM).

Before performing these steps, place your files in <DPAgent_root>/lib and manually create the /lib folder.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose Microsoft SQL Server Replication Setup.
4. Choose Config Mssql Connection Info to configure the connection used for other validation tasks.
Specify the information required for the configuration tool to connect to the database:
○ The data server, port number, and database name for the Microsoft SQL Server database
○ Whether to use SSL
○ The username and password to use to connect to the database
The configuration tool connects to the database with the specified parameters when performing other
validation tasks.
5. Perform validation tasks for the Microsoft SQL Server log reader environment.

○ To test whether the Microsoft SQL Server environment is ready for replication, choose Mssql
Replication Precheck.
○ To create a new Microsoft SQL Server user with the permissions required for replication, choose Create
A Mssql User With All Permissions Granted.

For each task, provide any additional parameters required by the task. For example, to test whether the
Microsoft SQL Server environment is ready for replication, you must specify the name of the Microsoft SQL
Server user and whether CDC is being used.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 317
Next Steps

After you have validated the configuration of the Microsoft SQL Server log reader environment, you can create
remote sources with the Microsoft SQL Server Log Reader adapter. You can manually create remote sources or
generate a creation script with the command-line configuration tool.

Related Information

Generate a Log Reader Remote Source Creation Script [page 318]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

6.16.1.6 Generate a Log Reader Remote Source Creation


Script

Use the Data Provisioning Agent command-line configuration tool to validate parameters and generate a
usable script to create a remote source for log reader adapters.

Prerequisites

Before generating a remote source creation script for your source, be sure that you have downloaded and
installed the correct JDBC libraries. For information about the proper JDBC library for your source, see the SAP
HANA smart data integration Product Availability Matrix (PAM).

Before performing these steps, place your files in <DPAgent_root>/lib. Note that you must manually create
the /lib folder.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose the appropriate replication setup option for your remote source type.
4. Choose the appropriate log reader setup option for your remote source type.
5. Provide the configuration details for your remote source as prompted.

Specify the name of the agent to use and the name of the remote source to create, as well as any
connection and configuration information specific to your remote source.

Installation and Configuration Guide


318 PUBLIC Configure Data Provisioning Adapters
For more information each configuration parameter, refer to the remote source configuration section for
your source type.

Results

The configuration tool validates the configuration details for your remote source and generates a script that
can be used to create the remote source. You can view the validation results in the Data Provisioning Agent log.

By default, the configuration tool generates the remote source creation script in the user temporary directory.
For example, on Windows: C:\Users\<username>\AppData\Local\Temp\remoteSource-
<remote_source_name>.txt.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

6.16.1.7 Microsoft SQL Server Trigger-Based Replication

Unlike like log reader functionality, which reads a remote database log to get changed data, trigger-based
replication is based on triggers capturing changed data, and then the adapter continuously queries the source
database to get the changed data. When a table is subscribed to replicate, the adapter creates three triggers
(INSERT, UPDATE, and DELETE) on the table for capturing data. The supported operations are:

● Add a column
● Delete a column
● Alter a column datatype
● Rename a column

The adapter also creates a shadow table for the subscribed table. Except for a few extra columns for
supporting replication, the shadow table has the same columns as its replicated table. Triggers record changed
data in shadow tables. For each adapter instance (remote source), the adapter creates a Trigger Queue table to
mimic a queue. Each row in shadow tables has a corresponding element (or placeholder) in the queue. The
adapter continuously scans the queue elements and corresponding shadow table rows to get changed data
and replicate them to the target SAP HANA database.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 319
Related Information

Required Permissions for SQL Server Trigger-Based Replication [page 320]


System Objects Created in Microsoft SQL Server [page 321]

6.16.1.7.1 Required Permissions for SQL Server Trigger-Based


Replication

Grant permissions and privileges to use MS SQL Server trigger-based replication.

Creating a DML trigger requires ALTER permission on the table or view on which the trigger is being created.

Creating a DDL trigger with database scopes (ON DATABASE) requires ALTER ANY DATABASE DDL TRIGGER
permission in the current database.

GRANT CREATE PROCEDURE TO [pds_user].

GRANT SELECT, INSERT, UPDATE, DELETE, ALTER, EXECUTE, VIEW DEFINITION ON SCHEMA::[schema of
the target subscribed table] TO [pds_user].

GRANT VIEW SERVER STATE permission to view data processing state, such as transaction ID. This must be
granted on the master database.

 Note

“GRANT VIEW SERVER STATE TO SDI_USER” isn’t permitted for SQL Server on Azure. On SQL Database
Premium Tiers, the VIEW DATABASE STATE permission is required in the database. On SQL Database Standard
and Basic Tiers, the Server admin or an Azure Active Directory admin account is required.

Related Information

sys.dm_tran_current_transaction (Transact-SQL)

Installation and Configuration Guide


320 PUBLIC Configure Data Provisioning Adapters
6.16.1.7.2 System Objects Created in Microsoft SQL Server

When you create a remote source to use trigger-based replication, a few system objects—such as tables,
triggers, or procedures—are created on the SQL Server source.

Remote Source Level

All of the system objects are created under <pds_user>. The “SDI_” prefix is an example, and it is set in the
remote source configuration parameters.

(table) Trigger queue table: "<pds_user>"."SDI_TRIGGER_QUEUE"

(table) Marker table: "<pds_user>"."SDI_MARKERS"

(trigger) Insert trigger on marker table: "<pds_user>"."SDI_MARKERS_I_SDI_TRIG"

(trigger) Delete trigger on marker table: "<pds_user>"." SDI_MARKERS_D_SDI_TRIG"

(trigger) Update trigger on marker table: "<pds_user>"." SDI_MARKERS_U_SDI_TRIG"

(table) Shadow table of Marker table: "<pds_user>"."SDI_SHADOW_SDI_MARKERS"

(trigger) Insert trigger on shadow table of marker table: "<pds_user>"."SDI_MARKERS_SH_I_SDI_TRIG"

(table) DDL table: "pds_user"."SDI_DDL_CHANGE"

(trigger) Insert trigger on DDL table: "<pds_user>"."SDI_ DDL_CHANGE_I_SDI_TRIG"

(trigger) Delete trigger on DDL table: "<pds_user>"." SDI_ DDL_CHANGE_D_SDI_TRIG"

(trigger) Update trigger on DDL table: "<pds_user>"." SDI_ DDL_CHANGE_U_SDI_TRIG"

(table) Shadow table of DDL table: "<pds_user>"."SDI_SHADOW_SDI_DDL_CHANGE"

(trigger) Insert trigger on shadow table of DDL table: "<pds_user>"."SDI_DDL_CHANGE_SH_I_SDI_TRIG"

(procedure) Mark procedure: "<pds_user>"."SDI_PROC_V1"

(sequence) Scan sequence: "<pds_user>"."SDI_SCAN_SEQ"

(sequence) Trans sequence: "<pds_user>"."SDI_TRIGGER_SEQ"

(table) Table to show the table name and its corresponding shadow table: "<pds_user>"."SDI_SRC_TO_ST”

(table) Subscribed table metadata table: "<pds_user>"."SDI_COLUMNS_METADATA"

Source Table Level

(table) Shadow table of source table: "<table_owner>"."SDI_SHADOW_<table_name>"

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 321
(trigger) Insert trigger on shadow table of source table: "<table_owner>"."<table_name>_SH_I_SDI_TRIG"

(trigger) Insert trigger on source table: "<table_owner>"."<table_name>_I_SDI_TRIG"

(trigger) Delete trigger on source table: "<table_owner>"."<table_name>_D_SDI_TRIG"

(trigger) Update trigger on source table: "<table_owner>"."<table_name>_U_SDI_TRIG"

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

6.16.2 MssqlLogReaderAdapter Preferences

Configuration parameters for the Microsoft SQL Server Log Reader adapter.

 Note

Log Reader adapter preferences are no longer set in the Data Provisioning Agent Configuration Tool with
the exception of Number of wrapped log files, Enable verbose trace, and Maximum log file size. They are now
in the remote source configuration options in SAP HANA. If you have upgraded from a previous version, the
settings you find in the Agent Configuration Tool are the previous settings and are displayed for your
reference.

You can adjust Microsoft SQL Server Log Reader adapter preferences in the Data Provisioning Agent
Configuration Tool (<DPAgent_root>/configTool/dpagentconfigtool.exe).

Parameter Description Default value

Maximum operation queue size The maximum number of operations 1000


permitted in the log reader operation
queue during replication.

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Installation and Configuration Guide


322 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Maximum wait interval between log The maximum wait interval between 2
scans Log Reader transaction log scans.

 Note
● The value of the parameter is
the maximum number of sec­
onds that can elapse before
the Log Reader component
scans the transaction log for a
transaction to be replicated,
after a previous scan yields no
such transaction.
● For reduced replication latency
in an infrequently updated da­
tabase, we recommend lower
number settings for the pa­
rameter.
● If the primary database is con­
tinuously updated, the value of
the parameter is not signifi-
cant to performance.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 323
Parameter Description Default value

Seconds to add to each log scan wait The number of seconds to add to each 0
interval wait interval before scanning the trans­
action log, after a previous scan yields
no transaction to be replicated.

 Note
● The value of the parameter is
the number of seconds added
to each wait interval before the
Log Reader component scans
the log for a transaction to be
replicated, after a previous
scan yields no such transac­
tion.
● The number of seconds speci­
fied by the parameter is added
to each wait interval, until the
wait interval reaches the value
specified by the Maximum wait
interval between log scans pa­
rameter.
● For optimal performance, the
value of the parameter should
be balanced with the average
number of operations in the
primary database over a pe­
riod of time. In general, better
performance results from
reading more operations from
the transaction log during
each Log Reader scan.
● With a primary database that
is less frequently updated, in­
creasing the value of the pa­
rameter may improve overall
performance.
● If the database is continuously
updated, the value of the pa­
rameter may not be significant
to performance.

Replicate LOB columns Determines whether the agent applies True


each LOB change.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library (DBLIB, 5


connection fails ODBC, ADO, and so on) to keep retrying
the connection attempt, as long as the
server is not found, for the specified
number of times.

Installation and Configuration Guide


324 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size in 1-K blocks of the 3
agent system log file before wrapping.

Enable verbose trace Enables or disables extra diagnostic in­ False


formation in the agent system log files.

Maximum log file size Limits the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not Log Reader True
should turn on asynchronized logging
mode. (True, False)

Maximum size of work queue for asyn­ The maximum size of the work queue 1000
chronous logging for the asynchronous logging file han­
dler to collect the log records. The
range is 1 to 2147483647.

Discard policy for asynchronous logging Specifies the discard policy for the BLOCKING
file handler asynchronous logging file handler when
the work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offered into the queue
are dropped.
DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried, which can fail
again, causing this process to be
repeated.

6.16.3 Microsoft SQL Server Log Reader Remote Source


Configuration
Configure the following options for a connection to a Microsoft SQL Server remote source. Also included is
sample code for creating a remote source using the SQL console.

 Note

When setting up a remote source and you use a remote source name longer than 30 characters, the
generated log reader folder name under <DPAgent_root>/LogReader/ is converted to AGENT<xxxx>.

The log file is located at <DPAgent_root>/log/framework.trc and reads: The instance name
<original_name> exceeds 30 characters and it is converted to <converted_name>.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 325
Category Option Description

Data Type Conversion Always Map Character Types to Determines whether a CHAR/
Unicode VARCHAR/TEXT column in the source
database is mapped to a Unicode
column type in SAP HANA when the
source database character set is non-
ASCII. The default value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Set this parameter to True only when


the remote database is non-ASCII,
such as UTF-8, GBK, and JA16SJIS.

Map SQL Server Data Type Time to The value is False by default, which
Timestamp means TIME is mapped to TIME.
However, setting this parameter to
False can lead to the loss of precision.
When setting its value to True, TIME
maps to TIMESTAMP.

Generic Load and Replicate LOB columns When this parameter is set to False, the
LOB columns are filtered out when
doing an initial load and real-time
replication. The value of this parameter
can be changed when the remote
source is suspended.

 Note
This option isn’t available for an
ECC adapter.

Database Data Server (serverName The Microsoft SQL Data Server name
\instanceName)
If your Microsoft SQL Server instance
is enabled with dynamic ports, you
must provide the Instance Name of the
Microsoft SQL Server instance instead
of the port number. Provide the data
server name and the instance name in
the format <serverName>
\<instanceName>.

If the instance name isn’t provided, the


default instance name
(MSSQLSERVER) is used.

Port Number The Microsoft SQL Data Server port


number. The value range is 1–65535.

Installation and Configuration Guide


326 PUBLIC Configure Data Provisioning Adapters
Category Option Description

If you’re using the instance name in the


Data Server parameter, you don’t need
to provide the port number.

Database Name The Microsoft SQL Server database


name

Use Remote Database Set to True if you’re running the Data


Provisioning Agent on a different
computer than you source Microsoft
SQL Server database.

The default value is False.

Include Table/Columns Remarks ● True: Returns a description of the


table/column. If you have many
tables, setting this parameter to
True can impede performance.
● False (Default): Turns off the
return of descriptions

You can add SQL Server Extended


Properties for objects (Table/View/
Column) to define a description of a
Microsoft SQL Server object. To create
a description of an object, you must
add a property called
“MS_Description”, and then add a
description of the object as the value.

If the parameter Include Table/


Columns Remarks is set to True, the
descriptions of tables/views are
returned when
GET_REMOTE_SOURCE_OBJECTS_LIS
T is called. The descriptions of tables/
views and columns are returned when
GET_REMOTE_SOURCE_TABLE_DEFI
NITIONS is called.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Whitelist Table in Remote Database Enter the name of table that contains
the whitelist in the remote database.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 327
Category Option Description

SQL Server Always On Specifies whether Microsoft SQL


Server is configured for Always On
availability group support.

Availability Group Listener Host The host name of the listener for the
Always On availability group

Availability Group Listener Port The port used by the listener for the
Always On availability group

Schema Alias Replacements Schema Alias Schema name to be replaced with the
schema given in Schema Alias
Replacement. If given, accessing tables
under this alias is considered to be
accessing tables under the schema
given in Schema Alias Replacement.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Schema Alias Replacement Schema name to use to replace the


schema given in Schema Alias

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Security Use SSL Specify whether you’re using SSL.

The default value is False.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Host Name in Certificate Enter the host name that is in the SSL
certificate.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Use Windows Authentication Specifies whether Windows credentials


on local machine are allowed to use for
connecting to a source database.

Installation and Configuration Guide


328 PUBLIC Configure Data Provisioning Adapters
Category Option Description

The default value is False.

 Note
The value of this parameter may
not be changed when the remote
source is suspended.

 Note
If set to True, the Credentials Mode
parameter must be set to Technical
user.

Use Agent Stored Credential Set to True to use credentials that are
stored in the Data Provisioning Agent
secure storage.

The default value is False.

CDC Properties Capture mode ● LogReader: Choose Log Reader to


enable log-based change data
capture.
● Trigger: Choose Trigger to enable
trigger-based change data
capture.

Table Subscribing Mode ● Native Mode (default). SAP HANA


smart data integration installs
some procedures into the
Microsoft SQL Server
mssqlsystemresource database.
These procedures are called every
time you mark a table for
replication.
● Microsoft SQL CDC Mode: The
adapter uses the Microsoft SQL
CDC API to mark a table for
replication, so that the first time
you use it, server-level initialization
isn’t required. When the Database
Data Capture Mode option is set to
Microsoft SQL CDC Mode, the
adapter doesn’t support
replicating the TRUNCATE TABLE
operation.

To switch to another mode, you must


reset all of your subscriptions and then
alter this mode.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 329
Category Option Description

 Note
You don’t need to enable Microsoft
SQL Server CDC.

 Tip
Both of these database data
capture modes require the
SYSADMIN role to execute.

LogReader objects schema in remote Optional. The schema name to use


database (Case Sensitive)
when creating log reader objects in the
remote database. This schema name
uniquely identifies the objects
belonging to a specific remote source,
and enables replication for multiple
remote sources on a single source
database.

 Note
When replicating using multiple
remote sources and a single
source database, each schema
name and each remote source
name must be unique.

Maintenance User Filter (Case Optional. Enter a source database user


Sensitive) name. Source database transactions
(INSERT, UPDATE, DELETE, and DDL
changes such as ALTER TABLE)
conducted by this user are filtered out
(ignored) and not propagated to the
SAP HANA target. For example, if you
log in to the source database with this
maintenance user and delete a row
from a source table that is subscribed
for replication, this row isn’t deleted
from the SAP HANA target table.

Don’t use the same name as the User


Name credential.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


330 PUBLIC Configure Data Provisioning Adapters
Category Option Description

 Note
If the S-ID of this user is changed
using ALTER USER DDL, the
Maintenance User Filter doesn’t
work.

Interval of transaction log truncation The interval to truncate the transaction


log in minutes. Set to 0 to disable the
truncation.

The default value is 10 minutes.

The value of this parameter can be


changed when the remote source is
suspended.

Ignore log record processing errors Specifies whether the Log Reader
ignores the errors that occur during log
record processing. If set to True, the
replication doesn’t stop if log record
processing errors occur. The default
value is False.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Ignore log record decluster errors


 Note
This parameter is available only
when you’re using the Microsoft
SQL Server Log Reader ECC
adapter.

Specifies whether to ignore log record


declustering errors. If set to True, the
replication doesn’t stop if log record
declustering errors occur. The default
value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Maximum operation queue size The maximum number of operations


permitted in the log reader operation
queue during replication

The default value is 1000. The value


range is 25–2147483647 .

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 331
Category Option Description

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Maximum scan queue size The maximum number of log records


permitted in the log reader log scan
queue during replication.

The default value is 1000. The value


range is 25–2147483647.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Maximum wait interval between log The default value is 2 seconds. The
scans value range is 1–3600.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Seconds to add to each log scan wait The default value is 0. The value range
interval is 0–3600.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Database connection pool size Maximum number of connections


allowed in the connection pool on a
secondary node.

The default value is 15. The value range


is 1–64.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Installation and Configuration Guide


332 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Number of times to retry to connect if Instructs the client library (DBLIB,


a connection fails
ODBC, ADO, and so on) to keep
retrying the connection attempt as
long as the server isn’t found for the
specified number of times.

The default value is 5. The value range


is 0–2147483647.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Timeout in seconds to retry connecting The number of seconds the agent waits

between retry attempts to connect to


the primary database.

The default value is 10. The value range


is 0–3600.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: System object prefix (Case Insensitive) The prefix of the


names of the SQL Server adapter
system objects created in the source
SQL Server database by the adapter.
We recommend keeping the default
value of “SDI_”.

Trigger-based: Connection pool size Maximum number of connections


allowed in the connection pool. The
default value is 4.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: Minimum scan interval The minimum interval in seconds that


in seconds the adapter scans the Trigger Queue
table to get change data. The default
value is 0 (seconds), which means
there’s no waiting time before the next
scan.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 333
Category Option Description

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: Maximum scan interval The maximum interval in seconds that


in seconds the adapter scans the Trigger Queue
table to get change data. The default
value is 10 (seconds). If the adapter
scans the queue and finds that the
queue is empty, it will gradually
increase the scan interval from the
minimum scan interval to the
maximum scan interval.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: Maximum batch size The maximum number of consecutive


change data on the same table that is
batched to process and send to Data
Provisioning Server together. The
default value is 128.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: Batch queue size The internal batch queue size. The
batch queue size determines the
maximum number of batches of
change data that are queued in
memory. The default value is 64.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Trigger-based: Maximum transaction The maximum number of transactions


count in scan being processed in a scan of the
remote source database.

Trigger-based: Maximum scan size The maximum number of rows being


fetched from the trigger queue table in
one scan and assigned to batch jobs
for further processing.

Installation and Configuration Guide


334 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Trigger-based: Triggers record PK only Set to True to have the triggers record
only primary keys of delta data during
CDC processing. This action may
improve the DML performance in the
source database.

The default value is False.

 Note
When this parameter is set to True,
only support DML (INSERT &
DELETE) is supported; no DDL is
supported.

Credentials Credentials Mode Remote sources support two types of


credential modes to access a remote
source: technical user and secondary
credentials.

● Technical User: A valid user and


password in the remote database.
This valid user is used by anyone
using the remote source.
● Secondary User: A unique access
credential on the remote source
assigned to a specific user.

User Name Microsoft SQL Server user name

Password Microsoft SQL Server user password

 Note
The value of this parameter can be
changed when the remote source
is suspended.

The following examples illustrate how to create a remote source using the SQL console.

Basic

Example

CREATE REMOTE SOURCE "MySQLServerSource" ADAPTER "MssqlLogReaderAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="data_type_conversion" displayName="Data Type Conversion">

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 335
<PropertyEntry name="map_char_types_to_unicode" displayName="Always Map
Character Types to Unicode">false</PropertyEntry>
<PropertyEntry name="map_time_to_timestamp" displayName="Map SQL Server Data
Type Time to Timestamp">true</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_server_name" displayName="Host">myserver.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">1433</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc" displayName="CDC Properties">
<PropertyEntry name="pdb_dcmode" displayName="Database Data Capture
Mode">MSCDC</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader" displayName="LogReader">
<PropertyEntry name="skip_lr_errors" displayName="Ignore log record
processing errors">false</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
'WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>'

Microsoft SQL Server AlwaysOn

Example

 Sample Code

CREATE REMOTE SOURCE "MySQLServerSource" ADAPTER "MssqlLogReaderAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_always_on" displayName="SQL Server Always
On">true</PropertyEntry>
<PropertyEntry name="pds_aglistener_host" displayName="Availability Group
Listener Host">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="pds_aglistener_port" displayName="Availability Group
Listener Port">1433</PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>'

Installation and Configuration Guide


336 PUBLIC Configure Data Provisioning Adapters
Related Information

CREATE REMOTE SUBSCRIPTION Statement [Smart Data Integration] [page 543]


Create Credentials for a Secondary User
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Security Aspects of SAP HANA Smart Data Access (SAP HANA Security Guide)
MssqlECCAdapter Preferences [page 429]
Configuring Windows Authentication [page 340]
Creating a Whitelist to Limit Access to a Source Database [page 341]
Using a Schema Alias [page 337]
Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.16.4 Using a Schema Alias

Using a schema alias can help you manage multiple schema, remote sources, and tables more easily.

The Schema Alias and Schema Alias Replacement options, available in the remote source configuration
parameters for some Data Provisioning adapters, allow you to switch easily between schema, remote sources,
and tables. The Schema Alias is the name of the schema in the original system. The Schema Alias Replacement
is the name of the schema in the current system that replaces the Schema Alias name.

A common use case is to create a remote source pointing to a development database (for example, DB_dev),
and then create virtual tables under that remote source. Afterward, you may switch to the production database
(for example, DB_prod) without needing to create new virtual tables; the same tables exist in both DB_dev and
DB_prod, but under different schema and databases.

During the development phase, you may create a virtual table for a source table OWNER1.MYTABLE in DB_dev,
for example. Note that OWNER1.MYTABLE is the unique name of the source table, and it is a property of the
virtual table. With it, the adapter knows which table in the source database it is expected to access. However,
when you switch to the production database (DB_prod), there is no OWNER1.MYTABLE, only
OWNER2.MYTABLE. The unique name information of the virtual table cannot be changed once created.

You can resolve this problem using the Schema Alias options. In this case, we want to tell the adapter to replace
OWNER1 with OWNER2. For example, when we access OWNER1.MYTABLE, the adapter should access
OWNER2.MYTABLE. So here, OWNER1 is Schema Alias from the perspective of DB_prod, while OWNER2 is
Schema Alias Replacement.

To use this functionality, you must populate both of these options.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 337
Oracle Log Reader Remote Source Configuration [page 370]
SAP HANA Remote Source Configuration [page 444]
SDI DB2 Mainframe [page 460]

6.16.5 Log Reader Adapter Log Files

You can review processing information in the Log Reader log files.

The following files are available:

Log file name and location Description

<DPAgent_root>/LogReader/admin_logs/ Log Reader administration log


admin<instance_name>.log

<DPAgent_root>/log/<instance_name>.log Log Reader instance log

 Note

By default, the adapter instance name is the same as the remote source name when the remote source is
created from the SAP HANA Web-based Development Workbench.

6.16.6 Configure SSL for the Microsoft SQL Server Log


Reader Adapter

Set up secure SSL communication between Microsoft SQL Server and the Data Provisioning Agent.

Context

If you want to use SSL communication between your Microsoft SQL Server source and the Data Provisioning
Agent, you must create and import certificates and configure the source database.

Procedure

1. On the Microsoft SQL Server host, create a certificate authority (CA) certificate using the sha1 algorithm.
You can also create a certificate using the makecert.exe utility included in the Windows SDK.
For example:

makecert -r -pe -n "CN=<hostname>" -b 01/01/2017 -e 01/01/2023 -eku


1.3.6.1.5.5.7.3.1 -ss my -sr localmachine -sky exchange -sp "Microsoft RSA
SChannel Cryptographic Provider" -sy 21 -a sha1

Installation and Configuration Guide


338 PUBLIC Configure Data Provisioning Adapters
2. Import the new certificate on the Microsoft SQL Server host.
You can use the Certificates snap-in for the Microsoft Management Console (MMC) to import the
certificate.

a. In the Microsoft Management Console, choose File Add/Remove Snap-in and add the
Certificates snap-in to the MMC.
In the wizard, specify the account and local computer.
b. In Certificates (Local Computer), right-click on the CA certificate that you created and choose All
Tasks Manage Private Keys .

 Note

If the CA certificate does not appear, first choose All Tasks Import to import the certificate.

c. In Group or user names, click Add and specify the name of the account used by the Microsoft SQL
Server service.
d. Copy the certificate and paste it under Certificates (Local Computer) Trusted Root Certification
Authorities Certificates .
3. Specify the certificate for the Microsoft SQL Server instance.
Use the SQL Server Configuration Manager (SSCM) to specify the certificate.

a. Expand SQL Server Network Configuration, and choose Protocols for <SQL Server instance>
Properties .
b. In the Certificate tab, select the certificate that you imported and click OK.

 Tip

If the certificate does not appear, verify that the hostname in the certificate is correct, and that the
Microsoft SQL Server service user has been added to the certificate.

4. Restart Microsoft SQL Server to ensure that the new certificate is picked up.

In the SQL Server error log, a message such as the following should appear:

The certificate [Cert Hash(sha1) "<hash>"] was successfully loaded for


encryption.

5. Export the certificate from the Microsoft SQL Server host.

a. In the Certificates snap-in for the Microsoft Management Console, navigate to Personal
Certificates .
b. Right-click on the certificate and choose All Tasks Export .

Export the certificate in the DER encoded binary X.509 (.CER) format. You do not need to export the
private key with the certificate.
6. Prepare the Data Provisioning Agent for SSL connections.
a. Copy the certificate from the Microsoft SQL Server host to the Data Provisioning Agent installation.
b. Import the certificate into the Data Provisioning Agent keystore.

Use the Java keytool to import the certificate. By default, keytool is located in <DPAgent_root>/
sapjvm/bin.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 339
For example:

keytool -importcert -alias mssql -keystore <DPAgent_root>\ssl\cacerts -


storepass <password> -file <path_to_exported_certificate> -noprompt

c. Configure the SSL password with the Data Provisioning Agent configuration tool.

Specify the same password used when importing the certificate, and then restart the Data Provisioning
Agent.

Next Steps

When you create a Microsoft SQL Server remote source, ensure that the following parameters are set
appropriately:

● Use SSL: True


● Host Name in Certificate: The host name specified when creating the certificate on the Microsoft SQL
Server host.

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]

6.16.7 Configuring Windows Authentication

To configure Windows authentication, copy an installed DLL file to your Windows system.

To use integrated authentication, the sqljdbc_auth.dll file must be copied to a directory in the Windows
system path on the computer where the JAVA installation is located.

The sqljdbc_auth.dll file can be copied from the following location:

<JDBC driver installation directory>\sqljdbc_<version>\<language>\auth\

Copy the sqljdbc_auth.dll file to the following default location:

<JAVA installation directory>\jdk_<version>\bin

 Note

When you run a 32-bit Java Virtual Machine (JVM), use the sqljdbc_auth.dll in the x86 folder, even if
the operating system is the x64 operation. When you run a 64-bit JVM on a x64 processor, use the
sqljdbc_auth.dll file in the x64 folder.

Installation and Configuration Guide


340 PUBLIC Configure Data Provisioning Adapters
Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
SAP HANA Smart Data Integration: Potential issues when connecting to SQL Server using the MssqlLogReader
Adapter and Windows Authentication

6.16.8 Creating a Whitelist to Limit Access to a Source


Database

There are times when you may want to limit access to all of the tables in a source database. For data
provisioning log reader adapters, as well as SAP HANA and SAP ECC adapters, an efficient way to limit access
is to create a whitelist.

Restricting access to only those tables that are to be replicated is done by creating a whitelist of source
database objects in a separate table.

 Note

The whitelist impacts only the virtual table created and the replications created after the whitelist was
created.

You can use SQL to create the whitelist table.

 Note

● The whitelist table, which can have any name, must have two columns named
REMOTE_SOURCE_NAME and WHITELIST.
● The whitelist items are separated by a comma.
● You can use an asterisk (*) to represent any character or empty string. However, the asterisk must be
placed at the end of a whitelist item. Otherwise, it is treated as a normal character.
● You can add multiple rows of whitelisted tables for a single remote source.

Microsoft SQL Server Example

create table whitelist(REMOTE_SOURCE_NAME varchar(128), WHITELIST varchar(4000));

To add a whitelist for the remote source called “localmssqldb”, insert a row into the whitelist table:

insert into whitelist values('localmssqldb', 'object.A, object.B*');


insert into whitelist values('localmssqldb', 'object.C, object.D*');

object.A, object.B*, and so on, means that the table (or procedure) object.A and the table (or procedure)
starting with object.B are filtered for the remote source “localmssqldb”.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 341
SAP HANA Example

create schema SAP_RESTRICTIONS;


create table WHITE_LIST(REMOTE_SOURCE_NAME varchar(128) primary key, WHITELIST
varchar(4000));

To add a whitelist for the remote source called “localhadp”, insert a row into the whitelist table:

insert into WHITE_LIST values('localhadp', 'APP_USER.MERCHANT,APP_PRODUCT.B*');

APP_USER.MERCHANT,APP_PRODUCT.B* means that the table (or procedure) APP_USER.MERCHANT and


the table (or procedure) starting with APP_PRODUCT.B are filtered for remote source “localhadp”.

6.16.9 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

Installation and Configuration Guide


342 PUBLIC Configure Data Provisioning Adapters
 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.16.10 Configure Microsoft Windows Authentication

Install a JDBC driver and configure your remote source to enable Windows authentication.

Context

Procedure

1. Download and install the Windows JDBC driver to a location of your choice.

You will find the sqljdbc_auth.dll file in the /x64 directory at the installation location. For example,
<JDBC installation directory>\ sqljdbc_<version>\<language>\auth
\x64\sqljdbc_auth.dll
2. Set the system environment Path variable to the location of the sqljdbc_auth.dll file.
3. Start the Data Provisioning Agent.

Related Information

Microsoft SQL Server Log Reader Remote Source Configuration [page 325]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 343
SAP HANA Smart Data Integration: Potential issues when connecting to SQL Server using the MssqlLogReader
Adapter and Windows Authentication

6.17 OData

Set up access to the OData service provider and its data and metadata.

Open Data Protocol (OData) is a standardized protocol for exposing and accessing information from various
sources, based on core protocols including HTTP, AtomPub (Atom Publishing Protocol), XML, and JSON (Java
Script Object Notation). OData provides a standard API on service data and metadata presentation, and data
operations.

The SAP OData adapter provides OData client access to the OData service provider and its data and metadata.
The OData service provider is created as a remote source. OData resources are exposed as metadata tables of
the remote source. These metadata tables can be added as virtual tables. An SAP HANA SQL query can then
access the OData data. Collections of OData data entries are represented as rows of the virtual table.

The OData adapter supports the following functionality:

● Virtual table as a source


● Virtual table as a target using a Data Sink in a flowgraph

The data of the main navigation entities can be accessed via SQL with the following restrictions:

● Without a join, selected projection columns appear in the OData system query “$select”.
● With a join, columns of the joined table, which is the associated OData entity, can occur in the projection.
Selected projection columns appear in the OData system query “$select”. All joined tables appear in the
OData system query “$expand”.
● Due to a restriction of the OData system queries “$select” and “$orderby”, no expressions can occur
in the Projection and the Order By clause.
● The Where clause supports logical, arithmetic, and ISNULL operators, string functions, and date functions.
The expression is translated into the OData system query “$filter”.

Refer to OData documentation for the OData URI conventions.

Related Information

Installation and Deployment [page 345]


Consume HTTPS OData Services [page 348]
URI Conventions

Installation and Configuration Guide


344 PUBLIC Configure Data Provisioning Adapters
6.17.1 Installation and Deployment

You must configure the SAP HANA server and provide the appropriate settings when you create a remote
source to connect to the service provider.

Unlike other adapters, the OData adapter is not installed with the Data Provisioning Agent.

Related Information

Set up the SAP HANA Server [page 345]


Create an OData Remote Source [page 345]
OData Remote Source Configuration [page 346]

6.17.1.1 Set up the SAP HANA Server

Follow these steps to set up the SAP HANA server before using the OData adapter.

Procedure

1. Ensure that the Data Provisioning server is enabled.


2. If the OData service provider site supports only HTTPS connection, use the SAP HANA cryptography tool
SAGENPSE to create a personal security environment (PSE) file and to import the public certificate
provided by the server.
Make sure that you place the PSE file into the SECUDIR (<HDB_INSTANCE>/<HOST_NAME>/sec) folder.
3. If the OData service provider requires HTTP basic authentication, set up a user and password.

6.17.1.2 Create an OData Remote Source

Follow these steps to create an OData remote source.

Procedure

1. Register the OData adapter to the ADAPTERS table.

CREATE ADAPTER "ODataAdapter" PROPERTIES 'display_name=OData


Adapter;description=OData Adapter' AT LOCATION DPSERVER;

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 345
You can verify whether an entry for the OData adapter exists in the ADAPTERS table:

SELECT * FROM ADAPTERS

2. Create an ODataAdapter-type remote source and enter the configuration information.


3. Expand the new OData adapter remote source to browse for table metadata information and add tables
from that remote source as virtual tables.
4. Expand Catalog/<SCHEMA>/Tables to find the added virtual tables and to view the table definition or to
preview table data.

Related Information

OData Remote Source Configuration [page 346]


Create Credentials for a Secondary User

6.17.1.3 OData Remote Source Configuration

Configuration settings for accessing an OData source. Also included is sample code for creating a remote
source using the SQL console.

Configure the following options in smart data access.

Option Description

URL OData service provider URL.

Proxy Server Proxy host if URL is outside the firewall.

Proxy Port Proxy port if URL is outside the firewall.

Trust Store The trust store that contains the OData client public
certificate, either a file in SECUDIR or a database trust
store.

Is File Trust Store Select True if the trust store is a file in SECUDIR, or False if
the trust store resides in the SAP HANA database. The
default value is True.

Support Format Query If set to True, $format=json is appended to get OData


entities in JSON format. If set to False, no format query is
appended. The default value is True.

Require CSRF Header Enter True if OData Service requires CSRF Header. The
default value is True.

CSRF Header Name Enter the name used for CSRF Header. The default value is
X-CSRF-Token.

Installation and Configuration Guide


346 PUBLIC Configure Data Provisioning Adapters
Option Description

CSRF Header Fetch Value Enter the value used for CSRF Header Fetch. The default
value is Fetch.

Support Date Functions Select False if the OData service site does not support the
date functions hour, minute, month, or year. The default
value is True.

Show Navigation Properties Select True or False for the OData Service to return
Navigation Properties. The default value is False.

If Show Navigation Properties is False, the select * SQL


query returns only the regular properties.

If Show Navigation Properties is True, the select * SQL


query also returns the navigation properties.

 Note
Due to an HTTP request maximum length restriction,
avoid using the select * query if the total lengths for
all Property and Navigation Property names exceed the
restriction.

Support accept-encoding:gzip Select True if the OData Service supports accept-


encoding:gzip. The default value is False.

If Support accept-encoding:gzip is True, the OData HTTP


request adds the header accept-encoding:gzip. If
the OData Service HTTP response contains the header
Content-Encoding: gzip, the response body is
unzipped.

Follow Redirects Select True for the OData adapter to follow redirected URLs.
The default value is False.

Extra Connection Parameters Enter extra connection parameters or leave blank.

Verify Server Certificate Select True to have the OData adapter verify the server
certificate. The default value is False.

Extra Header Parameters Enter extra header parameters or leave blank.

Convert to Local Timezone Select True or False for the OData adapter to convert the
timestamp value to a local timezone. The default value is
True

Credentials Mode Remote sources support two types of credential modes to


access a remote source: technical user and secondary
credentials.

● Technical User: A valid user and password in the remote


database. This valid user is used by anyone using the
remote source.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 347
Option Description

● Secondary User: A unique access credential on the


remote source assigned to a specific user.

User Name User name for HTTP Basic Authentication in


<username@companyId> format.

Password Password for HTTP Basic Authentication.

Example

CREATE REMOTE SOURCE "MyODataSource” ADAPTER "ODataAdapter" AT LOCATION DPSERVER


CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="connection_properties">
<PropertyEntry name="URL" displayName=”URL”>http://host:port/path1/
path2/pathN/MyODataService.svc</PropertyEntry>
<PropertyEntry name="proxyserver" displayName=”Proxy
Server”>myproxyserver</PropertyEntry>
<PropertyEntry name="proxyport" displayName=”Proxy Port”>8080</
PropertyEntry>
<PropertyEntry name="supportformatquery" displayName=”Support
Format Query”>true</PropertyEntry>
<PropertyEntry name="extraHeaderparameters">APIKey:
pX7dvtdvXLUjVCVAWsTAud0ilyluH8aC</PropertyEntry>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="password">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

6.17.2 Consume HTTPS OData Services

Steps to configure the consumption of HTTPS OData services.

Context

If you want to consume HTTPS-based OData Services, as opposed to non-secured HTTP-based OData
Services, you must import the SSL certificate from the OData Services provider into the trust store on your
SAP HANA platform.

Set up the Trust Manager to consume the OData Services.

Installation and Configuration Guide


348 PUBLIC Configure Data Provisioning Adapters
Procedure

1. Obtain the SSL certificate from the OData Services provider.

You can use your browser to navigate to the OData URL and export the certificate from the browser.
2. Import the SSL certificate using the SAP HANA XS Admin Trust Manager.

○ For file trust stores, import the certificate to the Trust Manager SAML trust store. This action imports
the certificate to the sapsrv.pse file in SECUDIR.
○ For database trust stores, create a database trust store and import the certificate to that new trust
store.

See the SAP HANA Administration Guide for more information about the Trust Manager and trust
relationships.
3. Create the remote source:

○ For file trust stores, set Trust Store to the sapsrv.pse file.
○ For database trust stores, set Trust Store to the new database trust store and Is File Trust Store to
False.

For file trust stores, add the certificate to the file trust store using the following steps:

a. In the browser for the source site click Padlock DetailsDetails Copy to File Next DER
encoded binary Next Next Finish , and select a location to download.
b. Copy the certificate to the HANA machine, and use sapgenpse to import the server, logged in as the
<SID>adm user (for example a71adm).

sapgenpse maintain_pk -p <path to your Hana sec dir>/sapcli.pse -a <full


path to your downloaded certificate>

Path to HANA sec directory example: /usr/sap/XXX/HDBXX/<hostname>/sec


4. Use SAP HANA studio or Web Workbench to browse the remote source and to create virtual tables.

Related Information

6.18 Oracle Log Reader


Use the Oracle Log Reader adapter to connect to an Oracle source.

The Oracle Log Reader adapter provides real-time changed-data capture capability to replicate changed data
from a database to SAP HANA. You can also use it for batch loading.

The Log Reader service provider is created as a remote source, and it requires the support of artifacts like
virtual tables and remote subscriptions for each source table to perform replication.

With this adapter, you can add multiple remote sources using the same Data Provisioning Agent.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 349
 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

Adapter Functionality

This adapter supports the following functionality:

● Oracle 12c multitenant database support


● Virtual table as a source
● Real-time change data capture (CDC) including support for database or table-level (default) supplemental
logging.

 Note

Log Reader adapters do not support the truncate table operation.

● Trigger-based real-time CDC


● Virtual table as a target using a Data Sink node in a flowgraph
● Loading options for target tables
● DDL propagation. The supported schema changes are:
○ ADD COLUMN
○ DROP COLUMN
○ RENAME TABLE
○ RENAME COLUMN
○ ALTER COLUMN DATA TYPE

 Note

For trigger-based CDC, the supported schema changes are:


○ ADD COLUMN
○ DROP COLUMN
○ ALTER COLUMN DATA TYPE

● Replication monitoring and statistics


● Search for tables
● Connect multiple remote sources in HANA to the same source database
● LDAP Authentication
● Virtual procedures

In addition, this adapter supports the following capabilities:

Installation and Configuration Guide


350 PUBLIC Configure Data Provisioning Adapters
Table 47: Global Settings

Functionality Supported?

SELECT from a virtual table Yes

INSERT into a virtual table Yes

Execute UPDATE statements on a virtual table Yes

Execute DELETE statements on a virtual table Yes

Different capabilities per table No

Different capabilities per table column No

Real-time Yes

Table 48: Select Options

Functionality Supported?

Select individual columns Yes

Add a WHERE clause Yes

JOIN multiple tables Yes

Aggregate data via a GROUP BY clause Yes

Support a DISTINCT clause in the select Yes

Support a TOP or LIMIT clause in the select Yes

ORDER BY Yes

GROUP BY Yes

Related Information

Oracle Database Permissions [page 352]


Oracle Real-time Replication [page 358]
OracleLogReaderAdapter Preferences [page 367]
Oracle Log Reader Remote Source Configuration [page 370]
Using a Schema Alias [page 386]
Oracle RAC Configuration [page 387]
Amazon Web Services Configuration [page 389]
Log Reader Adapter Log Files [page 390]
Synchronize the Oracle and Data Provisioning Agent Timestamp [page 390]
Configure SSL for the Oracle Log Reader Adapter [page 391]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 351
Creating a Whitelist to Limit Access to a Source Database [page 394]
Disable Adapter Write-back Functionality [page 395]
Connecting Multiple Remote Sources to the Same Oracle Source Database [page 364]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.18.1 Oracle Database Permissions

Oracle database users must have certain permissions granted to them in order to carry out real-time change
data capture or batch or initial load transactions.

You can run a script to assign all necessary permissions, or choose which ones suit users best. The following
scripts can be found in the oracle_init_example.sql file, which is located in the Scripts folder of the
Data Provisioning Agent installation at <DPAgent_root>\LogReader\scripts.

 Note

Be aware that the oracle_init_example.sql file is a template script. You may need to alter the
following:

● Change LR_USER to the configured database user name in the remote source options, if it is not
LR_USER.
● Change <_replace_with_password> to the password of the database user.

For on-premise deployment, grant select access to the log reader user by issuing the following statement. In
these examples – taken from the oracle_init_example.sql file – the user is named LR_USER. Change this
user name to whatever you need.

GRANT SELECT ON <table_to_be_replicated> TO LR_USER;

For convenience, you can also grant SELECT ANY TABLE.

However, for cloud deployment such as when accessing a database instance on Amazon Web Services (AWS)
as a Relational Database Service (RDS), some privileges require granting using the AWS rdsadmin package.
The following example shows how to GRANT SELECT on SYS.INDCOMPART$ to the LR_USER using the
rdsadmin package. The privileges that require this method are noted in the oracle_init_example.sql file.

begin
rdsadmin.rdsadmin_util.grant_sys_object(
p_obj_name => 'INDCOMPART$',
p_grantee => 'LR_USER',
p_privilege => 'SELECT',
p_grant_option => true);
end;
/

 Note

● As of 2.0 SP 03 Patch 53, the list of Oracle users can be accessed through the RA_ALL_USERS_VIEW
instead of directly accessing SYS.USERS$.

Installation and Configuration Guide


352 PUBLIC Configure Data Provisioning Adapters
Create this view manually following the example in oracle_init_example.sql. Note that the default
view is based on ALL_USERS. Although this view requires lesser permission privileges, it may not
include all Oracle users and may affect the replication process.
For additional information, see SAP Note 2757950
● We have removed the following permissions, as of SPS 11:
○ CREATE PUBLIC SYNONYM
○ DROP PUBLIC SYNONYM
○ ALTER SYSTEM
○ EXECUTE on DBMS_FLASHBACK
● If you are using Oracle 12c, the permission LOGMINING is required.
Additionally, the permission SELECT ANY TRANSACTION is not required.
● The GRANT SELECT ON SYS.DEFERRED_STG$ TO LR_USER permission is not required for versions of
Oracle below 11gR2.

Permission Reason Required For CDC/Non-CDC

GRANT CREATE SESSION TO Required to connect to Oracle CDC and Non-CDC


LR_USER;

GRANT CREATE TRIGGER TO Required to administer the DDL trigger CDC


LR_USER; used for Schema change (DDL) replica­
tion.

GRANT CREATE SEQUENCE TO Required to create a sequence that SDI CDC


LR_USER; needs

GRANT CREATE TABLE TO LR_USER; Required to create tables in the primary CDC
database that SDI needs.

GRANT CREATE PROCEDURE TO Required to create rs_marker and CDC


LR_USER; rs_dump stored procedures.

GRANT ALTER ANY TABLE TO Temporary permission to turn on table CDC


LR_USER; level supplemental logging when a table
is marked for replication in the source
system. Needed only for the mark.
However, if you turn on DDL replication
and you expect to create tables, it must
be left on so that tables can be altered
by having supplemental logging turned
on.

GRANT EXECUTE_CATALOG_ROLE TO Required to use Oracle LogMiner. CDC


LR_USER;

GRANT LOGMINING TO LR_USER; Required to use LogMiner for Oracle CDC


12c.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 353
Permission Reason Required For CDC/Non-CDC

GRANT SELECT ANY TRANSACTION Required to use Oracle LogMiner. CDC


TO LR_USER;

GRANT SELECT ON SYS.ATTRIBUTE$ Required to process Oracle types. CDC


TO LR_USER;

GRANT SELECT ON SYS.CCOL$ TO Required to support table replication CDC


LR_USER; (column constraint information).

GRANT SELECT ON SYS.CDEF$ TO Required to support table replication CDC


LR_USER; (constraint information).

GRANT SELECT ON SYS.COL$ TO Required to support table replication CDC


LR_USER; (column information).

GRANT SELECT ON SYS.COLLECTION$ Required to support table replication. CDC


TO LR_USER; (column information)

GRANT SELECT ON SYS.CON$ TO Required to support table replication CDC


LR_USER; (constraint information).

GRANT SELECT ON SYS.DEFER­ Required to suppress replication of CDC


RED_STG$ TO LR_USER; compressed tables in versions of Ora­
cle, on which LogMiner does not sup­
port compressed tables, such as Oracle
11g Release 2.

GRANT SELECT ON SYS.ICOL$ TO Required to support the use of a unique CDC


LR_USER; index on columns as the primary key of
the replication definition when there is
no primary key defined for that table.

GRANT SELECT ON SYS.IND$ TO Required when marking tables and to CDC


LR_USER; identify indexes.

GRANT SELECT ON SYS.INDCOMPART Required when marking tables and to CDC


$ TO LR_USER; identify indexes.

GRANT SELECT ON SYS.INDPART$ TO Required when marking tables and to CDC


LR_USER; identify indexes.

GRANT SELECT ON SYS.INDSUBPART Required when marking tables and to CDC


$ TO LR_USER; identify indexes.

GRANT SELECT ON SYS.LOB$ TO Required for LOB replication. CDC


LR_USER;

GRANT SELECT ON SYS.LOBCOMP­ Required to support partitioned LOB CDC


PART$ TO LR_USER; replication.

Installation and Configuration Guide


354 PUBLIC Configure Data Provisioning Adapters
Permission Reason Required For CDC/Non-CDC

GRANT SELECT ON SYS.LOBFRAG$ TO Required to support partitioned LOB CDC


LR_USER; replication.

GRANT SELECT ON SYS.MLOG$ TO Required to filter materialized view log CDC


LR_USER; tables.

GRANT SELECT ON SYS.NTAB$ TO Required to support table replication. CDC


LR_USER;

GRANT SELECT ON SYS.OBJ$ TO Required for processing procedure DDL CDC


LR_USER; commands in the repository.

GRANT SELECT ON SYS.OPQTYPE$ TO Required for DDL replication and CDC


LR_USER; XMLTYPE data replication. XMLTYPE is
not supported in SDI yet.

GRANT SELECT ON SYS.PARTOBJ$ TO Required to support partitioned table CDC


LR_USER; replication.

GRANT SELECT ON SYS.SEG$ TO Required to suppress replication of CDC


LR_USER; compressed tables in versions of Ora­
cle, on which LogMiner does not sup­
port compressed tables, such as Oracle
11g Release 2.

GRANT SELECT ON SYS.SEQ$ TO Required to support sequence replica­ CDC


LR_USER; tion. Replication of sequences is not
supported in SDI yet.

GRANT SELECT ON SYS.SNAP$ TO Required to filter out materialized view CDC


LR_USER; tables.

GRANT SELECT ON SYS.TAB$ TO Required to support table replication. CDC


LR_USER;

GRANT SELECT ON SYS.TABCOMPART Required when marking partitioned ta­ CDC


$ TO LR_USER; bles.

GRANT SELECT ON SYS.TABPART$ TO Required when marking partitioned ta­ CDC


LR_USER; bles.

GRANT SELECT ON SYS.TABSUBPART Required when marking partitioned ta­ CDC


$ TO LR_USER; bles.

GRANT SELECT ON SYS.TS$ TO Required to identify tablespace encryp­ CDC


tion in Oracle 11g.
LR_USER;

GRANT SELECT ON SYS.TYPE$ TO Required to process Oracle predefined CDC


LR_USER; and user-defined types.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 355
Permission Reason Required For CDC/Non-CDC

GRANT SELECT ON SYS.USER$ TO Required for Oracle user identification. CDC


LR_USER; Required during Schema change (DDL)
replication and when marking tables.

 Note
Required only if your
RA_ALL_USERS_VIEW is based on
SYS.USER$.

GRANT SELECT ON V_$DATABASE TO Required to identify current SCN (for CDC


LR_USER; example, end of log) and information
about supplemental logging.

GRANT SELECT ON V_ Required to use Oracle LogMiner. CDC


$LOGMNR_CONTENTS TO LR_USER;

GRANT SELECT ON V_ Required to use Oracle LogMiner. CDC


$LOGMNR_LOGS TO LR_USER;

GRANT SELECT_CATALOG_ROLE TO Required to use Oracle LogMiner. CDC


LR_USER;

Granting the EXECUTE CATALOG ROLE or the SELECT CATALOG ROLE is not necessary. Instead, you can grant
the following specific permissions that are part of those roles:

Role Permissions

EXECUTE CATALOG ROLE ● GRANT EXECUTE ON SYS.DBMS_LOGMNR TO LR_USER;


● GRANT EXECUTE ON SYS.DBMS_LOGMNR_D TO LR_USER;

Installation and Configuration Guide


356 PUBLIC Configure Data Provisioning Adapters
Role Permissions

SELECT CATALOG ROLE ● GRANT SELECT ON SYS.DBA_ERRORS TO LR_USER;


● GRANT SELECT ON SYS.DBA_LIBRARIES TO LR_USER;
● GRANT SELECT ON SYS.DBA_LOG_GROUPS TO LR_USER;
● GRANT SELECT ON SYS.DBA_OBJECTS TO LR_USER;
● GRANT SELECT ON SYS.DBA_SYNONYMS TO LR_USER;
● GRANT SELECT ON SYS.DBA_TABLES TO LR_USER;
● GRANT SELECT ON SYS.DBA_TRIGGERS TO LR_USER;
● GRANT SELECT ON SYS.GV_$INSTANCE TO LR_USER;
● GRANT SELECT ON SYS.GV_$SESSION TO LR_USER;
● GRANT SELECT ON SYS.V_$ARCHIVE_DEST TO LR_USER;
● GRANT SELECT ON SYS.V_$ARCHIVED_LOG TO LR_USER;
● GRANT SELECT ON SYS.V_$DATABASE TO LR_USER;
● GRANT SELECT ON SYS.V_$DATABASE_INCARNATION TO LR_USER;
● GRANT SELECT ON SYS.V_$INSTANCE TO LR_USER;
● GRANT SELECT ON SYS.V_$LOG TO LR_USER;
● GRANT SELECT ON SYS.V_$LOGFILE TO LR_USER;
● GRANT SELECT ON SYS.V_$LOGMNR_CONTENTS TO LR_USER;
● GRANT SELECT ON SYS.V_$LOGMNR_LOGS TO LR_USER;
● GRANT SELECT ON SYS.V_$PARAMETER TO LR_USER;
● GRANT SELECT ON SYS.V_$TRANSACTION TO LR_USER;

Multitenant Database Permissions

To set permissions for a multitenant database, run the scripts in the following files. They are also located in
<DPAgent_root>\LogReader\Scripts. The same rules concerning <LR_USER> apply to this script, and so
on.

 Note

The <C##LR_USER> in the container database must be the “common user” and the <LR_USER> user in the
pluggable database is the “local user”.

● oracle_multitenant_init_example_for_container_database.sql
● oracle_multitenant_init_example_for_pluggable_database.sql

Permissions for Processing Pool or Cluster Tables

If you want to process pool or cluster tables, you must uncomment the following lines from the
oracle_init_example.sql file:

--grant select on SAPSR3.DM41S to LR_USER;

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 357
--grant select on SAPSR3.DM26L to LR_USER;
--grant select on SAPSR3.DD02VV to LR_USER;
--grant select on SAPSR3.DM40T to LR_USER;
--grant select on SAPSR3.DD02L to LR_USER;
--grant select on SAPSR3.DD16S to LR_USER;
--grant select on SAPSR3.DD03L to LR_USER;
--grant select on SAPSR3.DD02T to LR_USER;
--grant select on SAPSR3.DD03T to LR_USER;
--grant select on SAPSR3.DD04T to LR_USER;
--grant select on SAPSR3.DDNTT to LR_USER;
--grant select on SAPSR3.DDNTF to LR_USER;

For cluster and pool tables, multiple ECC tables are stored in a single physical Oracle table. Grant permission to
access the physical Oracle table associated with the ECC table that you want to access. For example, to access
the ECC BSEG table, you must grant access to the RFBLG Oracle physical. The oracle_init_example.sql
file contains many examples of these tables, such as:

--grant select on SAPSR3.T000 to LR_USER;


--grant select on SAPSR3.KNA1 to LR_USER;
--grant select on SAPSR3.RFBLG to LR_USER;
--grant select on SAPSR3.VBAK to LR_USER;
--grant select on SAPSR3.VBAP to LR_USER;

You may need to add your own tables to this script.

Related Information

Oracle Log Reader Remote Source Configuration [page 370]

6.18.2 Oracle Real-time Replication

Information about setting up your source system and adapter for real-time replication.

 Note

We have found that the Oracle Log Miner maximum throughput is approximately 1 TB/day. With anything
more than that, Oracle Log Miner begins to lag behind.

Therefore, no matter the amount of overage, if the replication volume is greater than 1 TB/day, there will be
a delay in replication.

Related Information

Remote Database Setup for Oracle Real-time Replication [page 359]


Remote Database Cleanup for Oracle Real-time Replication [page 362]
Validate the Oracle Log Reader Environment [page 362]
Generate a Log Reader Remote Source Creation Script [page 363]

Installation and Configuration Guide


358 PUBLIC Configure Data Provisioning Adapters
Connecting Multiple Remote Sources to the Same Oracle Source Database [page 364]
Oracle Trigger-Based Replication [page 365]

6.18.2.1 Remote Database Setup for Oracle Real-time


Replication

The remote Oracle database must be set up properly for this adapter to function correctly when using real-time
replication.

This setup process is necessary only when using real-time replication.

Oracle 12c Multitenant support

Multitenant databases are supported for Oracle 12c. Be aware that some of the setup procedures are different
for multitenant. For example, in remote sources, the configuration, permissions, and cleanup procedures are
different.

LOB replication

When attempting LOB replication, be sure to set the db_securefile parameter to “PERMITTED” in the
Oracle system. Depending on the Oracle version, the parameter may be set to a different value by default.

To do this, you can uncomment the following in the oracle_init_example.sql file:

ALTER SYSTEM SET db_securefile='PERMITTED';

 Note

SecureFiles LOB replication is not supported.

Oracle to SAP HANA replication limitation

During real-time (CDC) replication for Oracle to SAP HANA, if the table in Oracle has a BLOB column as the first
column, the replication fails due to NullPointerException, which LogMiner returns as an invalid SQL statement.
This exception occurs on Oracle 11.2.0.3 and 11.2.0.4.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 359
Other Real-time Replication Limitations

The following limitations exist when performing real-time replication:

● Unsupported table types:


○ Table with all LOB columns
○ Table with computed columns
○ Table with LOB column and no primary key or unique index
○ Table with duplicated rows and no primary key
○ Table with user-defined identifier
○ Nested table

Related Information

Oracle Supplemental Logging [page 360]

6.18.2.1.1 Oracle Supplemental Logging

Decide which logging level is best for you and set it up.

Set your logging level in the Adapter Preferences window of the Data Provisioning Agent configuration tool for
the Oracle Log Reader adapter. Then, run the necessary scripts found in the oracle_init_example.sql file,
located in <DPAgent_root>\LogReader\Scripts.

 Note

Be aware that the oracle_init_example.sql file is a template script. Execute only the DDL statements
for your logging level by commenting or uncommenting lines as necessary.

Table-level Logging

We recommend table-level logging, which turns on supplemental logging for subscribed tables and some
required system tables.

To configure table-level logging, execute the following DDL statements from oracle_init_example.sql on
your Oracle client and set the Oracle supplemental logging level Adapter Preferences option to Table.

ALTER DATABASE ADD SUPPLEMENTAL LOG DATA;

ALTER TABLE <table_name> ADD SUPPLEMENTAL ...

Installation and Configuration Guide


360 PUBLIC Configure Data Provisioning Adapters
 Restriction

When using Amazon Web Services in the cloud, you can configure only database-level supplemental
logging for Oracle.

Database-level Logging

Database-level logging turns on supplemental logging for all tables, including system tables.

To configure database-level logging, execute the following DDL statements from oracle_init_example.sql
on your Oracle client and set the Oracle supplemental logging level Adapter Preferences option to Database.

ALTER DATABASE ADD SUPPLEMENTAL LOG DATA;


ALTER DATABASE ADD SUPPLEMENTAL LOG DATA (PRIMARY KEY, UNIQUE) COLUMNS;

Database-level Logging for Amazon Web Services

When using Amazon Web Services in the cloud, instead of using the ALTER DATABASE ADD SUPPLEMENTAL
commands, enable database-level supplemental logging as shown in the following example:

begin
RDSADMIN.RDSADMIN_UTIL.ALTER_SUPPLEMENTAL_LOGGING(
P_ACTION => 'ADD');
END;
/
begin
RDSADMIN.RDSADMIN_UTIL.ALTER_SUPPLEMENTAL_LOGGING(
P_ACTION => 'ADD',
P_TYPE => 'PRIMARY KEY');
RDSADMIN.RDSADMIN_UTIL.ALTER_SUPPLEMENTAL_LOGGING(
P_ACTION => 'ADD',
P_TYPE => 'UNIQUE');
END;
/

Related Information

OracleLogReaderAdapter Preferences [page 367]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 361
6.18.2.2 Remote Database Cleanup for Oracle Real-time
Replication

Run SQL scripts to clean objects manually from the source database.

Cleanup scripts are used to drop database-level objects. Usually, you do not need to execute a cleanup script
after an adapter is dropped, because the adapter drops these database-level objects automatically. However, in
some cases, if any errors occur during or before automatically dropping these objects, the objects may not be
dropped. At that point, you may need to execute the cleanup script to drop the objects.

You can find the script file at <DPAgent_root>\LogReader\scripts\oracle_logreader_cleanup.sql.

6.18.2.3 Validate the Oracle Log Reader Environment

You can use the Data Provisioning Agent command-line configuration tool to configure and validate the Oracle
log reader environment before creating remote sources that use the Oracle Log Reader adapter.

Prerequisites

Before validating the log reader environment, be sure that you have downloaded and installed the correct JDBC
libraries. For information about the proper JDBC library for your source, see the SAP HANA Smart Data
Integration Product Availability Matrix (PAM).

Place your files in <DPAgent_root>/lib. Note that you must manually create the /lib folder.

Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose Oracle Replication Setup.
4. Choose Config Oracle Connection Info to configure the connection used for other validation tasks.
Specify the information required to connect the configuration tool to the database:
○ Whether to use SSL
○ Whether the Oracle database is configured as a multitenant database
○ Whether to use LDAP authentication
○ The hostname, port number, database name, and service name for the Oracle database
○ The Oracle username and password to use to connect to the database
The configuration tool connects to the database with the specified parameters when performing other
validation tasks.

Installation and Configuration Guide


362 PUBLIC Configure Data Provisioning Adapters
5. Perform validation and configuration tasks for the Oracle log reader environment.

○ To test whether the Oracle environment is ready for replication, choose Oracle Replication Precheck.
○ To retrieve a list of all open transactions, choose List Open Transactions.
○ To create an Oracle user with the permissions required for replication, choose Create An Oracle User
With All Permissions Granted.

For each task, provide any additional parameters required by the task. For example, to test whether the
Oracle environment is ready for replication, you must specify the supplemental logging level when
prompted.

Next Steps

After you have validated the configuration of the Oracle log reader environment, you can create remote sources
with the Oracle Log Reader adapter. You can manually create remote sources or generate a creation script with
the command-line configuration tool.

Related Information

Generate a Log Reader Remote Source Creation Script [page 363]


Oracle Log Reader Remote Source Configuration [page 370]

6.18.2.4 Generate a Log Reader Remote Source Creation


Script

Use the Data Provisioning Agent command-line configuration tool to validate parameters and generate a
usable script to create a remote source for log reader adapters.

Prerequisites

Before generating a remote source creation script for your source, be sure that you have downloaded and
installed the correct JDBC libraries. For information about the proper JDBC library for your source, see the SAP
HANA smart data integration Product Availability Matrix (PAM).

Before performing these steps, place your files in <DPAgent_root>/lib. Note that you must manually create
the /lib folder.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 363
Procedure

1. At the command line, navigate to <DPAgent_root>\bin.


2. Start the configuration tool with the --replicationSetup parameter.

○ On Windows, agentcli.bat --replicationSetup


○ On Linux, agentcli.sh --replicationSetup
3. Choose the appropriate replication setup option for your remote source type.
4. Choose the appropriate log reader setup option for your remote source type.
5. Provide the configuration details for your remote source as prompted.

Specify the name of the agent to use and the name of the remote source to create, as well as any
connection and configuration information specific to your remote source.

For more information each configuration parameter, refer to the remote source configuration section for
your source type.

Results

The configuration tool validates the configuration details for your remote source and generates a script that
can be used to create the remote source. You can view the validation results in the Data Provisioning Agent log.

By default, the configuration tool generates the remote source creation script in the user temporary directory.
For example, on Windows: C:\Users\<username>\AppData\Local\Temp\remoteSource-
<remote_source_name>.txt.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]

6.18.2.5 Connecting Multiple Remote Sources to the Same


Oracle Source Database

You can connect multiple remote sources to the same remote database when the prerequisites are met.

To connect multiple remote sources to the same remote database, the following conditions must be met:

● Each remote source uses a unique Oracle database user to connect to the source database.
● A different source table is marked for replication; the same table cannot be marked for replication by
different remote sources.

Installation and Configuration Guide


364 PUBLIC Configure Data Provisioning Adapters
6.18.2.6 Oracle Trigger-Based Replication

Unlike like log reader functionality, which reads a remote database log to get changed data, trigger-based
replication is based on triggers capturing changed data, and then the adapter continuously queries the source
database to get the changed data. When a table is subscribed to replicate, the adapter creates three triggers
(INSERT, UPDATE, and DELETE) on the table for capturing data. The supported operations are:

● Add a column
● Delete a column
● Alter a column datatype

The adapter also creates a shadow table for the subscribed table. Except for a few extra columns for
supporting replication, the shadow table has the same columns as its replicated table. Triggers record changed
data in shadow tables. For each adapter instance (remote source), the adapter creates a Trigger Queue table to
mimic a queue. Each row in shadow tables has a corresponding element (or placeholder) in the queue. The
adapter continuously scans the queue elements and corresponding shadow table rows to get changed data
and replicate them to the target SAP HANA database.

Architecture

DDL Propagation

Related Information

System Objects Created in Oracle [page 366]


Required Permissions for Oracle Trigger-Based Replication [page 367]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 365
6.18.2.6.1 System Objects Created in Oracle

When you create a remote source to use trigger-based replication, a few system objects--such as tables,
triggers, or procedures--are created on the Oracel source.

Remote Source Level

(table) Trigger queue table: "LR_USER"."SDI_TRIGGER_QUEUE"

(table) Mapping source to shadow table: "LR_USER"."SDI_SRC_TO_ST"

(table) Marker table: "LR_USER"."SDI_MARKERS"

(table) Shadow table of Marker table: "LR_USER"."SDI_<marker_table_oid>"

(trigger) Insert trigger on marker table: "LR_USER"."SDI_<marker_table_oid>_I"

(trigger) Delete trigger on marker table: "LR_USER"."SDI_<marker_table_oid>_D"

(trigger) Update trigger on marker table: "LR_USER"."SDI_<marker_table_oid>_U"

(trigger) Insert trigger on shadow table of marker table: "LR_USER"."SDI_<marker_table_oid>_SHI"

(table) DDL table: "LR_USER"."SDI_DDL_CHANGE"

(table) Shadow table of DDL table: "LR_USER"."SDI_<DDL_table_oid>"

(trigger) Insert trigger on DDL table: "LR_USER"."SDI_<DDL_table_oid>_I"

(trigger) Delete trigger on DDL table: "LR_USER"."SDI_<DDL_table_oid>_D"

(trigger) Update trigger on DDL table: "LR_USER"."SDI_<DDL_table_oid>_U"

(trigger) Insert trigger on shadow table of DDL table: "LR_USER"."SDI_<DDL_table_oid>_SHI"

(procedure) Mark procedure: "LR_USER"."SDI_PROC_V1"

(sequence) Scan sequence: "LR_USER"."SDI_SCAN_SEQ"

(sequence) Trans sequence: "LR_USER"."SDI_TRIGGER_SEQ"

(trigger) DDL trigger: "LR_USER"."SDI_DDL_TRIG"

Source Table Level

(table) Shadow table of source table: "LR_USER"."SDI_<source_table_oid>"

(trigger) Insert trigger on source table: "LR_USER"."SDI_<source_table_oid>_I"

(trigger) Delete trigger on source table: "LR_USER"."SDI_<source_table_oid>_D"

Installation and Configuration Guide


366 PUBLIC Configure Data Provisioning Adapters
(trigger) Update trigger on source table: "LR_USER"."SDI_<source_table_oid>_U"

(trigger) Insert trigger on shadow table of source table: "LR_USER"."SDI_<source_table_oid>_SHI"

6.18.2.6.2 Required Permissions for Oracle Trigger-Based


Replication

Grant permissions and privileges to use Oracle trigger-based replication.

GRANT CREATE SEQUENCE TO <remote_source_user>;

GRANT DROP SEQUENCE TO <remote_source_user>;

GRANT CREATE PROCEDURE TO <remote_source_user>;

GRANT DROP PROCEDURE TO <remote_source_user>;

GRANT CREATE ANY TRIGGER TO <remote_source_user>;

GRANT DROP ANY TRIGGER TO <remote_source_user>;

GRANT ADMINISTER DATABASE TRIGGER TO <remote_source_user>;

GRANT CREATE TABLE TO <remote_source_user>;

GRANT DROP TABLE TO <remote_source_user>;

GRANT ALTER TABLE TO <remote_source_user>;

GRANT SELECT TABLE TO <remote_source_user>;

GRANT CREATE INDEX TO <remote_source_user>;

6.18.3 OracleLogReaderAdapter Preferences

Configuration parameters for the Oracle Log Reader adapter.

 Note

Log Reader adapter preferences - with the exception of Number of wrapped log files, Enable
verbose trace, and Maximum log file size - are no longer set in the Data Provisioning Agent
Configuration Tool. They are part of the remote source configuration options in SAP HANA. If you have
upgraded from a previous version, then the settings you find in the Agent Configuration Tool are your
previous settings, displayed for your reference.

You can adjust Oracle Log Reader adapter settings in the Data Provisioning Agent Configuration Tool.
(<DPAgent_root>/configTool/dpagentconfigtool.exe)

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 367
Parameter Description Default value

Distinguished Name (DN) in Certificate The distinguished name (DN) of the pri­
mary data server certificate.

● This parameter is valid only if Use


SSL is set to “true”.
● If this parameter is set, the DN field
in the server certificate is verified
to match this parameter. If it does
not match, the connection to the
primary data server fails.

Oracle supplemental logging level Specifies the level of supplemental log­ table
ging.

● Table: Table level turns on supple­


mental logging for subscribed ta­
bles and some required system ta­
bles.
● Database: Database level turns on
supplemental logging for all tables,
including system tables.

Maximum operation queue size The maximum number of operations 1000


permitted in the log reader operation
queue during replication.

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Maximum session cache size The maximum number of Oracle ses­ 1000
sions to be cached in memory during
replication.

Enable parallel scanning Specifies whether to turn on parallel false


scanning.

To achieve better performance for high


volume log throughput, set the parame­
ter to true to enable parallel scanning.

Queue size of parallel scan tasks Specifies the number of tasks in the 0
queue.

Parallel scan SCN range The maximum number of system 1024


change numbers (SCN) processed by
each Oracle LogMiner scanner, when
parallel scan is enabled, that is, when
lr_parallel_scan is true.

Number of parallel scanners Specifies the number of parallel scan­ 4


ners.

Number of log record rows fetched by Specifies the number of log record rows 1
the scanner at a time fetched by the scanner.

Ignore log record processing errors Determines whether to ignore log re­ false
cord processing errors.

Installation and Configuration Guide


368 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Replicate LOB columns Oracle logs all LOB data in the Oracle true
redo log, except for BFILE datatypes .
This allows the agent to apply each LOB
change. However, for BFILE data, the
same technique is used.

Ignore data of unsupported types Specifies whether you want to ignore false
stored in ANYDATA data with unsupported types housed in
ANYDATA wrapper.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library, such as 5


connections fails DBLIB, ODBC, ADO, and so on, to keep
retrying the connection attempt, as
long as the server is not found, for the
specified number of times.

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size, in 1K blocks, of the 3


agent system log file before wrapping.

Enable verbose trace Enables or disables additional diagnos­ false


tic information in the agent system log
files.

Maximum log file size Limit the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not LogReader TRUE


should turn on asynchronous logging
mode. (TRUE, FALSE)

Maximum size of work queue for asyn­ The maximum size of the work queue 1000
for asynchronous logging file handler to
chronous logging
collect the log records (1 to
2147483647)

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 369
Parameter Description Default value

Discard policy for asynchronous logging Specifies the discard policy for the BLOCKING
file handler asynchronous logging file handler when
the work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offerred into queue are
dropped.
● DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried, which can fail
again, causing this to be repeated.

Related Information

Oracle Database Permissions [page 352]


Oracle Supplemental Logging [page 360]

6.18.4 Oracle Log Reader Remote Source Configuration

Configure the following options for a connection to an Oracle remote source.

 Note

When setting up a remote source and you use a remote source name longer than 30 characters, the
generated log reader folder name under <DPAgent_root>/LogReader/ is converted to AGENT<xxxx>.

The log file is located at <DPAgent_root>/log/framework.trc, and reads: “The instance name
<original_name> exceeds 30 characters and it is converted to <converted_name>.”

Category Option Description

Generic Always Map Character Types to Determines whether a CHAR/


Unicode VARCHAR2/CLOB column in the
source database is mapped to a
Unicode column type in SAP HANA
when the source database character
set is non-ASCII. The default value is
False.

Installation and Configuration Guide


370 PUBLIC Configure Data Provisioning Adapters
Category Option Description

The value of this parameter can be


changed when the remote source is
suspended.

 Note
Set this parameter to True only
when the remote database is
multibyte character sets, such as
UTF-8, GBK, and JA16SJIS.

Map INTEGER/NUMBER to Set this parameter to True when you


DECIMAL(38,0) want to map INTEGER/NUMBER to
DECIMAL(38,0). Otherwise, INTEGER/
NUMBER maps to DECIMAL, which has
a precision of 34.

The default is False.

Timezone Format The time zone format to use for time


stamps that include a time zone data
type.
● TZR: The time zone name. For
example, US/Pacific
● TZH:TZM: The hour and minute
time zone offset. For example,
+8:00

Load and Replicate LOB columns When this parameter is set to false, the
LOB columns are filtered out when
doing an initial load and real-time
replication.

 Note
This option isn’t available for an
ECC adapter.

The value of this parameter can be


changed when the remote source is
suspended.

Database Multitenant Database Specifies whether to enable


multitenant support.
● True: Replicate multitenant
database
● False: Replicate normal database

Use Oracle TNSNAMES File Specifies whether to use the


connection information from the
Oracle tnsnames.ora file to connect
to the Oracle database. If set it to False,
you must configure the Host, Port

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 371
Category Option Description

Number, and Database Name


parameters. If set to True, configure
the Oracle TNSNAMES File and Oracle
TNSNAMES Connection parameters.

The default value is False.

Host The host name or IP address on which


the remote Oracle database is running.

The value of this parameter can be


changed when the remote source is
suspended.

Port Number The Oracle database server port


number

Database Name The Oracle database name

Service Name Specifies the service name of Oracle


database. When creating a remote
source, you must set only one of the
following parameters: Database Name
and Service Name. If you set both, the
Data Provisioning agent connects to
Oracle by the service name as the first
choice.

Container Database Service Name The service name of the container


database

Pluggable Database Service Name The service name of the pluggable


database

Oracle TNSNAMES File The full path of the Oracle


tnsnames.ora file. For example, C:
\usr\sap\dataprovagent\lib
\tnsnames.ora.

 Note
The tnsnames.ora file must be
local to the Data Provisioning
Agent machine or available to the
Data Provisioning Agent. Copy the
file from the Oracle location to the
Agent machine.

The tnsnames.ora file is


typically located at
$ORACLE_HOME\NETWORK
\ADMIN\tnsnames.ora on the
Oracle database machine.

Installation and Configuration Guide


372 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Oracle TNSNAMES Connection The Oracle connection name that


identifies the primary database
connection in the Oracle
tnsnames.ora file.

Container Database TNSNAMES The Oracle connection name that


Connection identifies the container database
connection in the Oracle
tnsnames.ora file.

Pluggable Database TNSNAMES The Oracle connection name that


Connection identifies the pluggable database
connection in the Oracle
tnsnames.ora file.

Whitelist Table in Remote Database Enter the name of table that contains
the whitelist in the remote database.

LDAP Authentication Use LDAP Authentication Set to True to enable LDAP


authentication for the Oracle database.
The default is False.

 Note
The Oracle log reader adapter
doesn’t support the following
LDAP scenarios:

● Oracle multi-tenant
architecture
● LDAP + SSL authentication
● LDAP + Kerberos
authentication
● LDAP failover mode

LDAP Server The host name or IP address of the


LDAP server

LDAP Port The port number of the LDAP server

Database Service Name The service name of the Oracle


database

Base Distinguished Name (DN) The base distinguished name of a


directory user on the LDAP server for
authentication.

Schema Alias Replacements Schema Alias Schema name to be replaced with the
schema provided in the Schema Alias
Replacement parameter. If given,
accessing tables under this alias is
considered to be accessing tables
under the schema given in Schema
Alias Replacement.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 373
Category Option Description

The value of this parameter can be


changed when the remote source is
suspended.

Schema Alias Replacement Schema name to be used to replace


the schema given in Schema Alias.

The value of this parameter can be


changed when the remote source is
suspended.

Security Use SSL Specifies whether you’re using SSL.

The default value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Distinguished Name (DN) in Certificate The distinguished name (DN) of the


primary data server certificate.

 Note
● This parameter is valid only if
Use SSL is set to True.
● If this parameter is set, the DN
field in the server certificate is
verified to match this
parameter. If it doesn’t match,
the connection to the primary
data server fails.

The value of this parameter can be


changed when the remote source is
suspended.

Require Client Authentication Specifies whether client authentication


is required. If client authentication is
required, the client sends its own
certificate to the server and the server
verifies that the client certificate is
signed by a trusted CA.

 Note
The value of this parameter can be
changed when the remote source
is suspended.

Use Agent Stored Credential Set to True to use credentials that are
stored in the Data Provisioning Agent
secure storage.

Installation and Configuration Guide


374 PUBLIC Configure Data Provisioning Adapters
Category Option Description

The default value is False.

 Note
When you use credentials stored in
the agent secure storage, you must
still specify the user name in
Credentials. Additionally, the
Credential Mode must not be none
or empty.

JDBC Driver Configuration Include Table/Columns Remarks ● True: Returns a description of the
table/column. If you have many
tables, setting this parameter to
“True” can impede performance.
● False (Default): Turns off the
return of descriptions.

The value of this parameter can be


changed when the remote source is
suspended.

CDC Properties > Database Oracle Supplemental logging level Specifies the level of supplemental
Configuration logging.
● Table: Enables supplemental
logging for subscribed tables and
some required system tables.
● Database: Enables supplemental
logging for all tables including
system tables.

The default value is Table.

The value of this parameter can be


changed when the remote source is
suspended.

CDC Properties > Parallel Scan Enable parallel scanning Specifies whether to enable parallel
scanning.

To achieve better performance for high


volume log throughput, set the
parameter to True to enable parallel
scanning.

The default value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Number of parallel scanners Specifies the number of parallel


scanners. The value range is 1–250.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 375
Category Option Description

As a general rule, the more scanners


you have, the higher the memory usage
and the better the throughput. Fewer
scanners means less memory usage
and lower throughput.

The value of this parameter can be


changed when the remote source is
suspended.

Queue size of parallel scan tasks Specifies the number of tasks in the
queue. The value range is 0–
2147483647 .

Setting Queue size of parallel scan


tasks to zero (0) means that each
parallel scanner queue will be of
unlimited size (based on the SCN range
of parallel scan tasks parameter). This
puts a lot of records in the queue and,
because processing the queue is
slower, the scanned records pile up and
can lead to out-of-memory events.

The value of this parameter can be


changed when the remote source is
suspended.

Enable parallel scanning by archived Determines whether the Replication


log
Agent should run parallel Oracle
LogMiner scanners using archive logs.

This option takes effect when Enable


parallel scanning is set to True, Enable
parallel scanning by archived log is set
to True.

The default value is False.

When Enable parallel scanning by


archived log is set to True, Redo logs
with a “current” status are never
touched. Oracle Logminer may read
transactions from a redo log that has a
status of archived=yes. There may
be a delay in replication until the redo
logs get saved to an archived status.

Installation and Configuration Guide


376 PUBLIC Configure Data Provisioning Adapters
Category Option Description

 Note
This parameter isn’t supported for
an Oracle RAC remote source.

 Note
Use this option only after
consultation with SAP support.

The value of this parameter can be


changed when the remote source is
suspended.

SCN range of parallel scan tasks The maximum number of system


change numbers (SCN) processed by
each Oracle LogMiner scanner when
the Enable parallel scanning parameter
is set to True. The value range is 0–
2147483647 .

The value of this parameter can be


changed when the remote source is
suspended.

CDC Properties Capture mode ● Trigger: Choose Trigger to enable


trigger-based change data
capture.
● LogMiner: Choose LogMiner to
enable log-based change data
capture.

Maintenance User Filter (Case Optional. Enter a source database user


Sensitive) name. Source database transactions
(INSERT, UPDATE, DELETE, and DDL
changes such as ALTER TABLE)
conducted by this user is filtered out
(ignored) and not propagated to the
SAP HANA target. For example, if you
log in to the source database with this
maintenance user and delete a row
from a source table that is subscribed
for replication, this row isn’t deleted
from the SAP HANA target table.

 Note
Don’t use the same name as the
database user name.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 377
Category Option Description

Ignore log record processing errors Specifies whether the Log Reader
should ignore the errors that occur
during log record processing. If set to
True, the replication doesn’t stop if log
record processing errors occur. The
default value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Ignore log record processing errors


 Note
This parameter is available only
when you’re using the Oracle Log
Reader ECC adapter.

Specifies whether to ignore log record


declustering errors. If set to True, the
replication doesn’t stop if log record
declustering errors occur. The default
value is False.

The value of this parameter can be


changed when the remote source is
suspended.

Maximum operation queue size The maximum number of operations


permitted in the log reader operation
queue during replication. The value
range is 25–2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Maximum scan queue size The maximum number of log records


permitted in the log reader log scan
queue during replication. The value
range is 25–2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Maximum session cache size The maximum number of Oracle


sessions to be cached in memory
during replication. The value range is
128–2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


378 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Number of log record rows fetched by Specifies the number of log record
the scanner at a time rows fetched by the scanner. The value
range is 1–1000 .

The value of this parameter can be


changed when the remote source is
suspended.

Use database link to query pluggable Indicates whether the LogReader uses
database
database link instead of the
CONTAINERS clause to query the
pluggable database. The default value
is “true”.

This parameter takes effect only when


the Multitenant Database parameter is
set to True.

 Note
Ensure that the user is granted the
GRANT CREATE DATABASE
LINK to C##LR_USER;
permission, located in the
oracle_multitenant_init
_example_for_pluggable_
database.sql file.

The value of this parameter can be


changed when the remote source is
suspended.

Ignore data of unsupported types Specifies whether you want to ignore


stored in ANYDATA data with unsupported types contained
in the ANYDATA wrapper.

The value of this parameter can be


changed when the remote source is
suspended.

Database connection pool size Maximum number of connections


allowed in the connection pool on a
secondary node. The value range is 1–
64.

The value of this parameter can be


changed when the remote source is
suspended.

Number of times to retry to connect if Instructs the client library, such as


a connection fails DBLIB, ODBC, and ADO, to keep
retrying the connection attempt, as
long as the server isn’t found, for the

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 379
Category Option Description

specified number of times. The value


range is 1 to 2147483647.

The value of this parameter can be


changed when the remote source is
suspended.

Timeout in seconds to retry connecting The number of seconds the Data


Provisioning Agent waits between retry
attempts to connect to the primary
database. The value range is 1 to 3600.

The value of this parameter can be


changed when the remote source is
suspended.

Keep supplemental logging on table Determines whether the Data


Provisioning Agent drops the
supplemental logging when dropping
the subscription of a table.
● True: Keeps the supplemental
logging.
● False: Drops the supplemental
logging. (Default value)

The value of this parameter can be


changed when the remote source is
suspended.

Enable deferrable rescan By default, the Oracle adapter


performs a rescan when encountering
each invalid log record due to an Oracle
LogMiner restriction. If there are many
invalid log records in a transaction, the
rescanning process may become a
performance bottleneck. Deferred
rescan provides a performance
enhancement that performs a
rescanning only one time per
transaction to resolve all invalid log
records together. Deferred rescan can
also solve some types of invalid record
problems in parallel scanning mode.

 Caution
Before using this feature, SAP
Support must analyze to identify
the root cause of performance
issues and determine whether it's
appropriate to enable deferrable
rescan mode. Use the two
deferrable rescan options only

Installation and Configuration Guide


380 PUBLIC Configure Data Provisioning Adapters
Category Option Description

after consultation with SAP


support.

● True: If it encounters
UNSUPPORTED LogMiner
operations, it performs a deferred
rescan on the current transaction.
● False: Disables the deferred rescan
and uses the default transaction
processing logic. (Default value)

Start LogMiner with online dictionary in By default, the Oracle adapter


deferrable rescan performs a rescan when encountering
each invalid log record due to an Oracle
LogMiner restriction. If there are many
invalid log records in a transaction, the
rescanning process may become a
performance bottleneck. Deferred
rescan provides a performance
enhancement that performs a
rescanning only one time per
transaction to resolve all invalid log
records together. Deferred rescan can
also solve some types of invalid record
problems in parallel scanning mode.

 Caution
Before using this feature, SAP
Support must analyze to identify
the root cause of performance
issues and determine whether it's
appropriate to enable deferrable
rescan mode. Use the two
deferrable rescan options only
after consultation with SAP
support.

● True Indicates that the deferred


rescan on the current transaction
uses the LogMiner
DBMS_LOGMNR.DICT_FROM_ON
LINE_CATALOG option. (Default
value)
● False Indicates that the deferred
rescan on the current transaction
doesn’t use the LogMiner
DBMS_LOGMNR.DICT_FROM_ON
LINE_CATALOG option.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 381
Category Option Description

 Note
Use this option only after
consultation with SAP support.

Disable DDL scanner Disable scanning for DDL operations.

Enable rescan for rollback operations Enable rescanning for rollback


operations.

Allow to read Oracle SYS.USER$ Specifies whether the log reader can
access SYS.USER$ for Oracle user
identification.
● True Indicates that the log reader
can access SYS.USER$ directly.
● False Indicates that the log reader
must use a different view for user
identification.
The name of the view must be
specified in the View to obtain
users information parameter.

View to obtain users information Specifies the name of the view to use
(Upper Case) for user identification (upper case).
This option takes effect when Allow to
read Oracle SYS.USER$ is set to False.

The default value is


RA_ALL_USERS_VIEW. The template
for the creation of this view can be
found in
oracle_init_example.ini.

 Note
This view must be created in the
current database user schema and
named in all upper-case
characters.

 Note
The default view is based on
ALL_USERS. Although this view
requires lesser permission
privileges, it may not include all
Oracle users and may affect the
replication process.

Trigger-based: System object prefix (Case Insensitive) The prefix of the


names of the Oracel adapter system
objects created in the source Oracle
database by the adapter. We

Installation and Configuration Guide


382 PUBLIC Configure Data Provisioning Adapters
Category Option Description

recommend keeping the default value


of SDI_.

Trigger-based: Connection pool size Maximum number of connections


allowed in the connection pool. The
default value is 8.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Minimum scan interval The minimum interval in seconds that


in seconds the adapter scans the Trigger Queue
table to get change data. The default
value is 0 (seconds), which means
there is no waiting time before the next
scan.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Maximum scan interval The maximum interval in seconds that


in seconds the adapter scans the Trigger Queue
table to get change data. The default
value is 10 (seconds). If the adapter
scans the queue and finds that the
queue is empty, it will gradually
increase the scan interval from the
minimum scan interval to the
maximum scan interval.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Maximum batch size The maximum number of consecutive


change data on the same table that are
batched to process and send to Data
Provisioning Server together. The
default value is 128.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Batch queue size The internal batch queue size. The
batch queue size determines the
maximum number of batches of
change data that are queued in
memory. The default value is 64.

The value of this parameter can be


changed when the remote source is
suspended.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 383
Category Option Description

Trigger-based: Maximum transaction The maximum number of transactions


count in scan being processed in a scan of the
remote source database. The default
value is 1000.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Maximum scan size The maximum number of rows being


fetched from the trigger queue table in
one scan and assigned to batch jobs
for further processing. The default
value is 50000.

The value of this parameter can be


changed when the remote source is
suspended.

Trigger-based: Triggers record PK only Set to True to have the triggers record
only primary keys of delta data during
CDC processing. This action may
improve the DML performance in the
source database.

The default value is False.

 Note
If this parameter is set to False,
during the time period between
when DDL changes occur on the
source database and when they
are replicated to the target HANA
database, there must be no DML
changes on the subscribed source
tables. Replicating DDL changes
would trigger the Oracle trigger-
based adapter to update (drop and
then re-create) triggers and
shadow tables on the changed
source tables. Errors may result if
any data is inserted, updated, or
deleted on the source tables
during this time period.

2. If this parameter is set to True


simple table structure changes (for
example, adding a non-key field) is
supported in real time.

Installation and Configuration Guide


384 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Trigger-based: Capture before and This option is only valid when Triggers
after images
Record PK Only is set to True.

● True: A trigger captures both


before and after images of
UPDATE operations on the remote
table. Updates of primary key
values are also supported, when
this is set to True.
● False: A trigger captures only the
after image of UPDATE operations
on the remote table.

The default value is False.

Credentials Credentials Mode Remote sources support two types of


credential modes to access a remote
source: technical user and secondary
credentials.

● Technical User: A valid user and


password in the remote database.
This valid user is used by anyone
using the remote source.
● Secondary User: A unique access
credential on the remote source
assigned to a specific user.

Credentials > Oracle Connection User Name Oracle user name (case-sensitive)
Credential

Password Oracle user password

The value of this parameter can be


changed when the remote source is
suspended.

Credentials > Oracle Multitenant Common User Name The common user name in the
Credential container database (case-sensitive)

Common User Password The common user password in the


container database

The value of this parameter can be


changed when the remote source is
suspended.

SQL Example

CREATE REMOTE SOURCE "oracleadapter_zhuj1" ADAPTER "OracleLogReaderAdapter" AT


LOCATION AGENT "JianbingAgentLocal" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 385
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="map_char_types_to_unicode"
displayName="map_char_types_to_unicode" isRequired="true">false</PropertyEntry>
<PropertyEntry name="pds_host_name" displayName="Host"
isRequired="true">10.9.44.56</PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number"
isRequired="true">1521</PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name"
isRequired="true">or1211a</PropertyEntry>
<PropertyEntry name="capture_mode" displayName="Capture Mode"
isRequired="true">logminer</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader" displayName="LogReader">
<PropertyEntry name="lr_parallel_scan" displayName="Enable parallel
scanning" isRequired="false">true</PropertyEntry>
<PropertyEntry name="lr_parallel_scanner_count" displayName="Number of
parallel scanners" isRequired="false">4</PropertyEntry>
<PropertyEntry name="lr_parallel_scan_queue_size" displayName="Queue
size of parallel scan tasks" isRequired="false">0</PropertyEntry>
<PropertyEntry name="lr_parallel_scan_range" displayName="SCN range of
parallel scan tasks" isRequired="false">1024</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>LR_USER</user>
<password>Sybase123</password>
</CredentialEntry>';

Related Information

CREATE REMOTE SUBSCRIPTION Statement [Smart Data Integration] [page 543]


Create Credentials for a Secondary User
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Security Aspects of SAP HANA Smart Data Access (SAP HANA Security Guide)
Creating a Whitelist to Limit Access to a Source Database [page 394]
Using a Schema Alias [page 386]
Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.18.5 Using a Schema Alias


Using a schema alias can help you manage multiple schema, remote sources, and tables more easily.

The Schema Alias and Schema Alias Replacement options, available in the remote source configuration
parameters for some Data Provisioning adapters, allow you to switch easily between schema, remote sources,
and tables. The Schema Alias is the name of the schema in the original system. The Schema Alias Replacement
is the name of the schema in the current system that replaces the Schema Alias name.

A common use case is to create a remote source pointing to a development database (for example, DB_dev),
and then create virtual tables under that remote source. Afterward, you may switch to the production database

Installation and Configuration Guide


386 PUBLIC Configure Data Provisioning Adapters
(for example, DB_prod) without needing to create new virtual tables; the same tables exist in both DB_dev and
DB_prod, but under different schema and databases.

During the development phase, you may create a virtual table for a source table OWNER1.MYTABLE in DB_dev,
for example. Note that OWNER1.MYTABLE is the unique name of the source table, and it is a property of the
virtual table. With it, the adapter knows which table in the source database it is expected to access. However,
when you switch to the production database (DB_prod), there is no OWNER1.MYTABLE, only
OWNER2.MYTABLE. The unique name information of the virtual table cannot be changed once created.

You can resolve this problem using the Schema Alias options. In this case, we want to tell the adapter to replace
OWNER1 with OWNER2. For example, when we access OWNER1.MYTABLE, the adapter should access
OWNER2.MYTABLE. So here, OWNER1 is Schema Alias from the perspective of DB_prod, while OWNER2 is
Schema Alias Replacement.

To use this functionality, you must populate both of these options.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]
SAP HANA Remote Source Configuration [page 444]
SDI DB2 Mainframe [page 460]

6.18.6 Oracle RAC Configuration

Configure an Oracle Real Application Cluster (RAC) source by, among other requirements, setting up the
tnsnames.ora file.

When a Data Provisioning Adapter for an Oracle instance initializes, the Oracle database is queried to
determine how many nodes are supported by the cluster. Based on this information, the Data Provisioning
Adapter automatically configures itself to process the redo log information from all nodes.

You configure the Data Provisioning Adapter to connect to a single Oracle instance by supplying the required
Host, Port Number, and Database Name remote source configuration parameters. However, in an Oracle RAC
environment, the Data Provisioning Adapter must be able to connect to any node in the cluster in the event that
a node fails or otherwise becomes unavailable. To support the configuration of multiple node locations, the
Data Provisioning Adapter supports connectivity to all possible RAC nodes by obtaining necessary information
from an Oracle tnsnames.ora file for one specified entry. As a result, instead of configuring individual host, port,
and instance names for all nodes, the Data Provisioning Adapter requires only the location of a tnsnames.ora
file and the name of the TNS connection to use. Therefore, it's recommended that you point the Data
Provisioning Adapter to a tnsnames.ora entry that contains the address for all nodes in the cluster.

Refer to the following procedure for details on the correct configuration for an Oracle RAC source.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 387
Related Information

Configure an Oracle RAC source [page 388]


Configure an Oracle RAC source [page 388]

6.18.6.1 Configure an Oracle RAC source

Configure the remote source for Oracle Real Application Cluster (RAC) as follows.

Procedure

1. Use the tnsnames.ora file to connect to Oracle, instead of providing individual host names and SIDs, by
setting the remote source property Database Use TNSNAMES file to true.
2. Ensure the tnsnames.ora file includes details for all nodes.

RAC11G =
(DESCRIPTION =
(ADDRESS_LIST =
(LOAD_BALANCE = yes)
(FAILOVER = ON)
(ADDRESS = (PROTOCOL = TCP)(HOST = www.xxx.yyy.zz1)
(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = www.xxx.yyy.zz2)
(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = www.xxx.yyy.zz3)
(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = rac11g)
)
)

3. Configure tnsnames.ora with the entry of the global SID to the remote source.

<net_service_name> =
(DESCRIPTION =
(ADDRESS = (<protocol_address_information>))
(CONNECT_DATA =
(SERVICE_NAME = <service_name>)))

For example:

ABC =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = hostname.com)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ABC) ) )

4. If the Data Provisioning Agent and Oracle source are on different computers, for all versions up to and
including HANA DP AGENT 1.0 SP03 Patch 2 (1.3.2), set the parameter CDC Properties Database

Installation and Configuration Guide


388 PUBLIC Configure Data Provisioning Adapters
Configuration Oracle Timezone File to a location that the Data Provisioning Agent can access. Note that
the Oracle Timezone File parameter was removed in version HANA DP AGENT 1.0 SP03 Patch 3 (1.3.3).

5. Set the parameter Database Oracle TNSNAMES Connection to use <net_service_name>.

6. Set the location of the Database Oracle TNSNAMES File to tnsnames.ora. This location must be
available to the Data Provisioning Agent computer.

Oracle TNSNAMES file = /usr/sap/dataprovagent/tnsnames.ora


7. For HANA DP AGENT 1.0 versions SP00, SP01, and SP02, edit the dpagentconfig.ini file to include the
entry logreader.rasd.type=DERBYEMB and restart the DP Agent.

6.18.7 Amazon Web Services Configuration

Extra configuration steps and tips for Oracle on Amazon Relational Database Service (RDS).

Procedure

1. To avoid remote access issues, in Amazon RDS ensure the database instance setting Publicly Acccessible
has been enabled.
2. To avoid remote access issues, in Amazon RDS configure the security group as follows.
a. Open the EC2 console.
b. Select Security Group in the left pane.
c. Choose the Security Group ID.
d. Click the Inbound tab and click Edit.
e. Click Add Rule and configure the following options:
○ Type = Oracle-RDS
○ Source = Anywhere
f. Click Save.
3. Grant access rights as described in the oracle_init_example.sql template file, which is located in the
Data Provisioning Agent installation folder <DPAgent_root>\LogReader\scripts.
4. Enable database-level supplemental logging as described in the oracle_init_example.sql template
file in <DPAgent_root>\LogReader\scripts.

Related Information

Oracle Database Permissions [page 352]


Oracle Supplemental Logging [page 360]
Amazon Virtual Private Cloud (VPCs) and Amazon RDS
Controlling Access with Amazon RDS Security Groups

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 389
6.18.8 Log Reader Adapter Log Files

You can review processing information in the Log Reader log files.

The following files are available:

Log file name and location Description

<DPAgent_root>/LogReader/admin_logs/ Log Reader administration log


admin<instance_name>.log

<DPAgent_root>/log/<instance_name>.log Log Reader instance log

 Note

By default, the adapter instance name is the same as the remote source name when the remote source is
created from the SAP HANA Web-based Development Workbench.

6.18.9 Synchronize the Oracle and Data Provisioning Agent


Timestamp

Context

If there is timestamp with a local time zone column in an Oracle table, the Data Provisioning Agent must have
the same time zone. To change the timezone, use the following procedure before starting the Data Provisioning
Agent.

Procedure

1. Find the Oracle server time zone. For example, use “date -R” in linux. Example: -04:00.
2. Open the dpagent.ini file in Data Provisioning Agent install root directory.
3. Add “-Duser.timezone=GMT-4” to the dpagent.ini file.
4. Start the Data Provisioning Agent.

Installation and Configuration Guide


390 PUBLIC Configure Data Provisioning Adapters
6.18.10 Configure SSL for the Oracle Log Reader Adapter

Set up secure SSL communication between Oracle and the Data Provisioning Agent.

Context

If you want to use SSL communication between your Oracle source and the Data Provisioning Agent, you must
create and import certificates and configure the source database.

 Note

The SSLv3 protocol is disabled by default in JDK 8 Update 31 and newer. If SSLv3 is absolutely required for
your environment, you can reactivate the protocol by removing SSLv3 from the
jdk.tls.disabledAlgorithms property in the java.security file.

Procedure

1. On the Oracle source database host, create directories for the root certificate authority (CA) and server
certificates.
For example:
○ c:\ssl\oracle\root
○ c:\ssl\oracle\server
2. Create and export a self-signed CA certificate.
Use the orapki tool on the Oracle host system.
a. Create an empty wallet.

orapki wallet create -wallet c:\ssl\oracle\server -auto_login_only

a. Add a self-signed CA certificate to the new wallet.

orapki wallet add -wallet c:\ssl\oracle\root -dn "CN=test_ca,C=US" -


keysize 1024 -self_signed -validity 3650 -pwd <password>

b. Export the certificate.

orapki wallet export -wallet c:\ssl\oracle\root -dn "CN=test_ca,C=US" -


cert c:\ssl\oracle\root\cacert.cer -pwd <password>

3. Create the server certificate.


Use the orapki tool on the Oracle host system.
a. Create a server wallet.

orapki wallet create -wallet c:\ssl\oracle\server -auto_login_only

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 391
b. Add key pairs to the new server wallet.

orapki wallet add -wallet c:\ssl\oracle\server -dn


"CN=PVGN50869480A.SAP.COM,C=US" -keysize 1024 -auto_login_only

c. Export a request to sign the server certificate.

orapki wallet export -wallet c:\ssl\oracle\server -dn


"CN=PVGN50869480A.SAP.COM,C=US" -request c:\ssl\oracle\server
\server_req.cer

d. Sign the exported request using the CA certificate.

orapki cert create -wallet c:\ssl\oracle\root -request c:\ssl\oracle\server


\server_req.cer -cert c:\ssl\oracle\server\server_cert.cer -validity 3650 -
pwd <password>

e. Add the trusted CA certificate into server wallet.

orapki wallet add -wallet c:\ssl\oracle\server -trusted_cert -cert c:\ssl


\oracle\root\cacert.cer -auto_login_only

f. Add the server certificate into server wallet.

orapki wallet add -wallet c:\ssl\oracle\server -user_cert -cert c:\ssl


\oracle\server\server_cert.cer -auto_login_only

4. Configure Oracle server SSL (Optional, if not yet set up).


a. Configure the listener.ora file.

WALLET_LOCATION =
(SOURCE =
(METHOD = FILE)
(METHOD_DATA = (DIRECTORY = C:\ssl\oracle\server)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = PVGN50869480A.SAP.COM)(PORT =
1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
(ADDRESS = (PROTOCOL = TCPS)(HOST = PVGN50869480A.SAP.COM)(PORT =
2484))
)
)

SSL_CLIENT_AUTHENTICATION = FALSE
SSL_CIPHER_SUITES = (SSL_RSA_WITH_RC4_128_SHA) (1)

b. Configure the tnsnames.ora file.

ssl =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCPS)(HOST = PVGN50869480A.SAP.COM)(PORT =
2484))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ORCL)
)
(SSL_SERVER_CERT_DN ="CN=PVGN50869480A.SAP.COM,C=US")
)

Installation and Configuration Guide


392 PUBLIC Configure Data Provisioning Adapters
a. Configure the sqlnet.ora file.

SQLNET.AUTHENTICATION_SERVICES= (BEQ, TCPS, NTS)


SSL_CLIENT_AUTHENTICATION=FALSE
SSL_CIPHER_SUITES = (SSL_RSA_WITH_RC4_128_SHA) (1)
WALLET_LOCATION =
(SOURCE =
(METHOD = FILE)
(METHOD_DATA = (DIRECTORY = C:\ssl\oracle\server)
)
)

5. Configure SSL for the Data Provisioning Agent.


Use the Java keytool utility to configure the agent keystore. By default, keytool is located in
$JAVA_HOME/bin.
a. Copy and import the CA certificate.

keytool -importcert -keystore C:\usr\sap\dataprovagent\ssl\cacerts -


storepass changeit -file c:\ssl\oracle\root\cacert.cer -noprompt -alias
ora_ca_cert

b. Copy and import the server certificate.

keytool -importcert -keystore C:\usr\sap\dataprovagent\ssl\cacerts -


storepass changeit -file c:\ssl\oracle\server\server_cert.cer -noprompt -
alias ora_srv_cert

6. Set the allowed cipher suites in the dpagentconfig.ini file.

oracle.net.ssl_cipher_suites=SSL_RSA_WITH_RC4_128_SHA

For TLS cipher protocols, add the additional jdk.tls.client.protocols parameter to the
dpagentconfig.ini file. For example:

jdk.tls.client.protocols=TLSv1.2

7. Restart the Oracle listener and the Data Provisioning Agent.

Next Steps

When you create an Oracle remote source, ensure that the following parameters are set appropriately:

● Use SSL: true


● Distinguished Name (DN) in Certificate: The distinguished name must contain no quotes, and there must
be a space between CN and C. For example, CN=..., C=....

Related Information

Oracle Log Reader Remote Source Configuration [page 370]


Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 393
6.18.11 Creating a Whitelist to Limit Access to a Source
Database

There are times when you may want to limit access to all of the tables in a source database. For data
provisioning log reader adapters, as well as SAP HANA and SAP ECC adapters, an efficient way to limit access
is to create a whitelist.

Restricting access to only those tables that are to be replicated is done by creating a whitelist of source
database objects in a separate table.

 Note

The whitelist impacts only the virtual table created and the replications created after the whitelist was
created.

You can use SQL to create the whitelist table.

 Note

● The whitelist table, which can have any name, must have two columns named
REMOTE_SOURCE_NAME and WHITELIST.
● The whitelist items are separated by a comma.
● You can use an asterisk (*) to represent any character or empty string. However, the asterisk must be
placed at the end of a whitelist item. Otherwise, it is treated as a normal character.
● You can add multiple rows of whitelisted tables for a single remote source.

Microsoft SQL Server Example

create table whitelist(REMOTE_SOURCE_NAME varchar(128), WHITELIST varchar(4000));

To add a whitelist for the remote source called “localmssqldb”, insert a row into the whitelist table:

insert into whitelist values('localmssqldb', 'object.A, object.B*');


insert into whitelist values('localmssqldb', 'object.C, object.D*');

object.A, object.B*, and so on, means that the table (or procedure) object.A and the table (or procedure)
starting with object.B are filtered for the remote source “localmssqldb”.

SAP HANA Example

create schema SAP_RESTRICTIONS;


create table WHITE_LIST(REMOTE_SOURCE_NAME varchar(128) primary key, WHITELIST
varchar(4000));

Installation and Configuration Guide


394 PUBLIC Configure Data Provisioning Adapters
To add a whitelist for the remote source called “localhadp”, insert a row into the whitelist table:

insert into WHITE_LIST values('localhadp', 'APP_USER.MERCHANT,APP_PRODUCT.B*');

APP_USER.MERCHANT,APP_PRODUCT.B* means that the table (or procedure) APP_USER.MERCHANT and


the table (or procedure) starting with APP_PRODUCT.B are filtered for remote source “localhadp”.

6.18.12 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 395
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.19 PostgreSQL Log Reader

Use the PostgreSQL Log Reader adapter to batch load or replicate changed data in real time from a PostgreSQL
database to SAP HANA.

PostgreSQL, often referred to as “Postgres”, is an object-relational database management system (ORDBMS)


with an emphasis on extensibility and standards compliance.

The PostgreSQL adapter is designed for accessing and manipulating data from a PostgreSQL database.

Assign PostgreSQL Roles

Make sure that all users are assigned the SUPERUSER and REPLICATION roles.

Adapter Functionality

This adapter supports the following functionality:

● Supports the following SQL statements: SELECT, INSERT, UPDATE, and DELETE
● Virtual table as a source, using a Data Source node in a flowgraph
● Real-time change data capture (CDC)
● Virtual table as a target using a Data Sink node in a flowgraph
● Batch loads (only) are supported for Greenplum databases.
● Replication monitoring and statistics
● DDL replication

Installation and Configuration Guide


396 PUBLIC Configure Data Provisioning Adapters
Restrictions

The following restriction applies to the PostgreSQL adapter:

● Remote subscriptions do not work with unlogged tables.

Related Information

Configure PostgreSQL Source for Real-time Replication [page 397]


PostgreSQL Remote Source Configuration [page 398]
Amazon Web Services Configuration [page 401]
Using a Schema Alias [page 402]
Disable Adapter Write-back Functionality [page 403]
PostgreSQL DDL Replication [page 404]

6.19.1 Configure PostgreSQL Source for Real-time


Replication

Information about how to configure your source system for real-time replication.

Context

If you plan on performing real-time replication from a PostgreSQL source, you must prepare that source by
configuring a few system parameters.

Procedure

1. Open the PostgreSQL main server configuration file postgresql.conf.


2. Set the following parameters to the suggested values:

Parameter Value

wal_level logical

archive_mode true

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 397
Parameter Value

max_replication_slots 2

 Note
If you want to replicate multiple databases in one server, set this
value to: “max_replication_slots = database_need_to_replicate * 2”.
You need 2 slots per instance.

3. Restart the PostgreSQL server.

6.19.2 PostgreSQL Remote Source Configuration

Information about configuration parameters for creating a PostgreSQL remote source.

Configure the following options for a connection to a PostgreSQL remote source:

Category Option Description

Database Connection Host Specifies the host name

The default value is localhost

Port Number Specifies the port number

The default value is 5432.

Database Name Specifies the database name

Schema Alias Replacements Schema Alias Schema name to be replaced with the schema given in
the Schema Alias Replacement parameter. If given, ac­
cessing tables under this alias is considered to be ac­
cessing tables under the schema given in the Schema
Alias Replacemen parameter.

Schema Alias Replacement Schema name to use to replace the schema given in the
Schema Alias parameter.

Data Type Mapping Map timestamptz type to ● VARCHAR


● TIMESTAMP
When mapping as VARCHAR, target string values
use a fixed ISO format, such as 2019-04-29
02:08:52.123456-06, using DP Agent's client time
zone.
When mapping as TIMESTAMP, target timestamp
values are always in UTC.
PostgreSQL timestamptz type does not store the
time zone into database storage, so we can't repli­
cate that information.

Installation and Configuration Guide


398 PUBLIC Configure Data Provisioning Adapters
Category Option Description

LogReader Ignore log record processing er­ Specifies whether the Log Reader ignores the errors that
rors
occur during log record processing. If set to True, the rep­
lication does not stop if log record processing errors oc­
cur.

The default value is False.

Enable DDL replication Specifies whether to enable replicating DDL.

The default value is False.

Number of parallel operation Specifies the number of processor threads to use


processor threads
The default value is 4.

Maximum operation queue size The maximum number of log records permitted in the log
reader log operation queue during replication

The default value is 1000.

Maximum scan queue size The maximum number of operations permitted in the log
reader scan queue during replication

The default value is 1000.

Number of rows to fetch for Specifies the batch size for fetching the log record.
each scan
The default value is 1000.

Maximum wait interval for poll­ Specifies the amount of time in seconds to wait for an el­
ing a message
ement to become available for processing

Seconds to add to each log scan The default value is 5 seconds.


wait interval

Maximum wait interval between The default value is 60 seconds.


log scans

Number of parallel formatter Specifies the number of such threads to use to format
threads
the raw records to the change data row set in the Data
Provisioning Agent

The default value is 4.

Maximum sender queue size Specifies the buffer size

Before formatting the raw records to the change data


row, the records are placed into a queue, and then the
formatter component (threads) attempts to pick up re­
cords to format.

The default value is 1000.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 399
Category Option Description

Maximum number of rows sent Specifies the number of rows per batch to send to the
to server in a batch
Data Provisioning Server after the Data Provisioning
Agent processes them.

The default value is 512.

Amount of time to allow for a Specifies the amount of elapsed time in seconds before
batch to fill before flushing the
flushing the batch of rows
batch
Depending on the number of rows you specified, there
may be a lot of time to fill that batch. To avoid a long la­
tency period, you can adjust the amount of time using
this parameter.

The default value is 5 seconds.

Ignore formatting errors Specifies whether to ignore any errors from the formatter
component and allow records to continue processing

Interval of transaction log trun­ The interval to truncate the PostgreSQL transaction log
cation
in minutes. Set to 0 to disable the truncation.

The default value is 10 minutes.

The value of this parameter can be changed when the re­


mote source is suspended.

Security Use Agent Stored Credential Set to True to use credentials that are stored in the Data
Provisioning Agent secure storage.

The default value is False.

Credentials Credentials Mode Remote sources support two types of credential modes
to access a remote source: technical user and secondary
credentials.

● Technical User: A valid user and password in the re­


mote database. This valid user is used by anyone us­
ing the remote source.
● Secondary User: A unique access credential on the
remote source assigned to a specific user.

Postgresql Connection Cre­ User Name The PostgreSQL user name


dentials
Make sure that all users are assigned the SUPERUSER
and REPLICATION roles.

Password The PostgreSQL password

Installation and Configuration Guide


400 PUBLIC Configure Data Provisioning Adapters
SQL Configuration

CREATE REMOTE SOURCE "posgresqladapter_sample" ADAPTER


"PostgreSQLLogReaderAdapter" AT LOCATION AGENT "PostgreSQLAgentLocal"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_host_name" displayName="Host"
isRequired="true">localhost</PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number"
isRequired="true">5432</PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name"
isRequired="true">sample</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader" displayName="logreader">
<PropertyEntry name="skip_lr_errors" displayName="Ignore log record
processing errors">true</PropertyEntry>
<PropertyEntry name="lr_processor_parallelism">5</PropertyEntry>
<PropertyEntry name="lr_max_op_queue_size" >1500</PropertyEntry>
<PropertyEntry name="lr_max_scan_queue_size">1500</PropertyEntry>
<PropertyEntry name="scan_sleep_increment">6</PropertyEntry>
<PropertyEntry name="scan_sleep_max">70</PropertyEntry>
<PropertyEntry name="lr_scan_batch_size">1500</PropertyEntry>
<PropertyEntry name="sender_formatter_parallelism">5</PropertyEntry>
<PropertyEntry name="sender_max_row_queue_size">1500</PropertyEntry>
<PropertyEntry name="skip_format_errors">true</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>postgres</user>
<password>password</password>
</CredentialEntry>';

Related Information

Using a Schema Alias [page 402]


Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.19.3 Amazon Web Services Configuration

More configuration steps and tips for PostgreSQL on Amazon Relational Database Service (RDS).

Procedure

1. To avoid remote access issues, in Amazon RDS ensure the database instance setting Publicly Acccessible
has been enabled.
2. Configure the PostgreSQL database for real-time replication by adding a parameter group in Amazon RDS
as follows.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 401
a. Create a Parameter Group.
b. Search for the parameter rds.logical_replication. Change its Values default to 1.
a. Associate the parameter group to the database instance.
b. Restart the database instance.

Related Information

Amazon Virtual Private Cloud (VPCs) and Amazon RDS


Working with DB Parameter Groups

6.19.4 Using a Schema Alias

Using a schema alias can help you manage multiple schema, remote sources, and tables more easily.

The Schema Alias and Schema Alias Replacement options, available in the remote source configuration
parameters for some Data Provisioning adapters, allow you to switch easily between schema, remote sources,
and tables. The Schema Alias is the name of the schema in the original system. The Schema Alias Replacement
is the name of the schema in the current system that replaces the Schema Alias name.

A common use case is to create a remote source pointing to a development database (for example, DB_dev),
and then create virtual tables under that remote source. Afterward, you may switch to the production database
(for example, DB_prod) without needing to create new virtual tables; the same tables exist in both DB_dev and
DB_prod, but under different schema and databases.

During the development phase, you may create a virtual table for a source table OWNER1.MYTABLE in DB_dev,
for example. Note that OWNER1.MYTABLE is the unique name of the source table, and it is a property of the
virtual table. With it, the adapter knows which table in the source database it is expected to access. However,
when you switch to the production database (DB_prod), there is no OWNER1.MYTABLE, only
OWNER2.MYTABLE. The unique name information of the virtual table cannot be changed once created.

You can resolve this problem using the Schema Alias options. In this case, we want to tell the adapter to replace
OWNER1 with OWNER2. For example, when we access OWNER1.MYTABLE, the adapter should access
OWNER2.MYTABLE. So here, OWNER1 is Schema Alias from the perspective of DB_prod, while OWNER2 is
Schema Alias Replacement.

To use this functionality, you must populate both of these options.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]
SAP HANA Remote Source Configuration [page 444]
SDI DB2 Mainframe [page 460]

Installation and Configuration Guide


402 PUBLIC Configure Data Provisioning Adapters
6.19.5 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 403
Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.19.6 PostgreSQL DDL Replication

Learn how to replicate your PostgreSQL DDL.

The PostgreSQL adapter uses event triggers to capture changes to tables so that you can apply those same
changes to a target.

Only 'ALTER TABLE' events are supported, and only the following triggers are supported:

● Column added
● Column deleted
● Column modified
● Column renamed

Enabling DDL Replication

You enable DDL replication by setting the PostgreSQL Enable DDL Replication remote source parameter to
True. No other configuration is necessary. The default value is True.

New Repository Objects

For informational purposes, the following repository objects are created in your PostgreSQL database:

● ddl_constraint_keys_shadow (table)
● ddl_tables_shadow (table)
● ddl_columns_shadow (table)
● dpagent_${<pds_database_name>}_replication_ddl_trigger (function)
● dpagent_${<pds_database_name>}_replication_ddl_trigger (event trigger)

Limitations

Currently, replicating DDL and DML in the same transaction is not supported.

Installation and Configuration Guide


404 PUBLIC Configure Data Provisioning Adapters
Related Information

Event Triggers
PostgreSQL Remote Source Configuration [page 398]

6.20 SAP ABAP

Use the ABAP adapter to retrieve various types of SAP data.

The ABAP adapter retrieves data from virtual tables through RFC for ABAP tables and ODP extractors. You can
find more information about setting up your environment and adapter by reading the topics in the Related
Information section of this topic.

ABAP Adapter Functions

The SAP ABAP Adapter is a client to functions delivered via modules that are delivered via PI_BASIS.

Extra coding was required in order for these functions to support RAW and/or STRING data types.

The valid PI_BASIS releases are listed in the Support Packages and Patches section of this SAP Note https://
launchpad.support.sap.com/#/notes/2166986

Please note that these functions were originally developed for SAP Data Services.

All references in this SAP Note relevant to PI_BASIS are also relevant for SAP HANA Smart Data Integration.

Ignore references to the SAP Data Services version. This SAP Note applies to all SAP HANA smart data
integration versions.

Prerequisites

You may need to perform extra tasks to access the data you need. For example:

● To access the M_MTVMA, M_MVERA, KONV, and NWECMD_PRPTDVS tables, via /SAPDS/RFC_READ_TABLES,
you must apply SAP Note 2166986 .

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● Change data capture for ODP extractors

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 405
 Note

Hierarchy extractors are not supported.

● Calling BAPI functions as virtual procedures


● Virtual procedures

In addition, this adapter supports the following capabilities:

● SELECT, WHERE, TOP, or LIMIT

Related Information

Authorizations [page 406]


Using RFC Streaming With Tables [page 412]
SAP ABAP Adapter Preferences [page 414]
SAP ABAP Adapter Remote Source Configuration [page 414]
Installing BW Content DataSources
Installing Application Component Hierarchies
Error opening the cursor for the remote database Error with ASSIGN ... CASTIN in program /SAPDS/
SAPLRS_BASIS

6.20.1 Authorizations

Authorizations for accessing various ABAP adapter operations.

This section describes the authorizations that support SAP ABAP adapter operations. For improved security,
avoid using wildcards, generic values, or blank values for authorization fields, especially in a production
environment. Enter more specific values that are appropriate to your business applications.

 Note

Even though some of the listed authorizations are described as being necessary for SAP Data Services,
they are also necessary for the ABAP adapter.

Related Information

G_800S_GSE [page 407]


S_BTCH_ADM [page 407]
S_BTCH_JOB [page 407]
S_DEVELOP [page 408]
S_RFC [page 409]
S_RFC_ADM [page 409]

Installation and Configuration Guide


406 PUBLIC Configure Data Provisioning Adapters
S_SCRP_TXT [page 410]
S_SDSPGMCK [page 410]
S_SDSDEV [page 410]
S_SDSAUTH [page 411]
S_TABU_DIS [page 411]
S_TCODE [page 412]
S_USER_GRP [page 412]

6.20.1.1 G_800S_GSE

Authorization for SAP Data Services to access ERP hierarchies.

Use: DEV, PROD

Text (Description): Special Purpose Ledger Sets: Set

Class: Financial Accounting

Field Values

Authorization group Not used

Activity 03

6.20.1.2 S_BTCH_ADM

Authorization that checks background processing privileges.

Use: DEV, PROD

Text (Description): Background Processing: background Administrator

Class: Basis

Field Values

Background administrator ID Y

6.20.1.3 S_BTCH_JOB

Authorization that checks privileges for releasing batch jobs.

Use: DEV, PROD

Text (Description): Batch processing

Class: Basis

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 407
Field Values

Job operation RELE

Summary of jobs for a group Not used

6.20.1.4 S_DEVELOP

Authorization for SAP Data Services to perform a column search.

Use: DEV, PROD

Text (Description): ABAP Workbench

Class: Basis - Development Environment

Field Values

Package List of packages for tables that a user is allowed to access

Object type TABL

Object name List of tables that a user is allowed to access

Authorization group ABAP/4 program Not used

Activity 03

Purpose: This authorization allows Data Services to run generated programs on the SAP server.

Use: DEV

Text (Description): ABAP Workbench

Class: Basis - Development Environment

Field Values

Package $TMP

Object type PROG

Object name List of temporary program names that are allowed to be gen­
erated

Authorization group ABAP/4 program Not used

Activity 01 and 02

Purpose: This implementation allows Data Services to import a table or to search for a table.

Use: DEV, PROD (table search)

Text (Description): ABAP Workbench

Class: Basis - Development Environment

Installation and Configuration Guide


408 PUBLIC Configure Data Provisioning Adapters
Field Values

Package List of packages for tables that a user is allowed to access

Object type VIEW, TABL and TTYP

Object name List of tables and views that a user is allowed to access

Authorization group ABAP/4 program Not used

Activity 03

6.20.1.5 S_RFC

Authorization that allows users to execute remote functions on an SAP server.

Use: DEV, PROD

Text (Description): Authorization check for RFC access

Class: Cross-application authorization object

Field Values

Activity 16

Name of RFC to be protected BAPI, CADR, RFC1, SCAT, SDIF, SLST, SUNI, SUTL, SDTX, SYST, /SAPDS/
SAPDS, RSAB, SDIFRUNTIME, and any other required function group

Type of RFC object to be protected FUGR

6.20.1.6 S_RFC_ADM

Authorization for RFC streaming.

Use: DEV, PROD

Text (Description): Administration for RFC Destination

Class: Cross-application

Field Values

Activity 03

Type of Entry in RFCDES Not used

Logical Destination (Specified in Function Call) RFC destination

Internet Communication Framework Values Not used

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 409
6.20.1.7 S_SCRP_TXT

Authorization for SAP Data Services to read SAP texts.

Use: DEV, PROD

Text (Description): SAPscript: Standard text

Class: SBOP Data Services Authorization Object

Field Values

Language Key List of language keys that a user is allowed to access

Text ID List of text IDs that a user is allowed to access

Name List of text names that a user is allowed to access

Activity SHOW

6.20.1.8 S_SDSPGMCK

Authorize specified programs to execute in a production environment.

Use: PROD

Text (Description): SBOP Data Services Authorization Object for program names

Class: SBOP Data Services Authorization Object

Field Values

ACTVT: Activity 16 (Execute)

PROGRAM: ABAP program name Program names that are allowed to be executed in a produc­
tion environment

 Note

In previous SAP Data Services versions, this authorization was named ZPGMCHK in version 3.x and
S_DSPGMCHK in version 4.1 SP3 Patch 2, 4.2 SP1 Patch 5, 4.2 SP2, and some later versions.

6.20.1.9 S_SDSDEV

SAP Data Services general authorization object that is equivalent to the SAP S_DEVELOP authorization.

Use: DEV, PROD

Text (Description): SBOP Data Services Authorization Object for development

Class: SBOP Data Services Authorization Object

Installation and Configuration Guide


410 PUBLIC Configure Data Provisioning Adapters
Field Values

Package List of packages for tables that a user is allowed to access

Object type VIEW, TABL, and TTYP

Object name DD objects that a user is allowed to access

Authorization group ABAP/4 program Not used

Activity 03

 Note

In previous SAP Data Services versions, this authorization was named ZDSDEV in version 3.x and S_DSDEV
in version 4.1 SP3 Patch 2, 4.2 SP1 Patch 5, 4.2 SP2, and some later versions.

6.20.1.10 S_SDSAUTH

Authorizes access to SAP Data Services functions.

Use: DEV, PROD

Text (Description): SBOP Data Services - general authorization

Class: SBOP Data Services Authorization Object

Field Values

ACTVT: Activity 16 (Execute)

 Note

In previous SAP Data Services versions, this authorization was named ZDSAUTH in version 3.x and
S_DSAUTH in version 4.1 SP3 Patch 2, 4.2 SP1 Patch 5, 4.2 SP2, and some later versions.

6.20.1.11 S_TABU_DIS

Authorizes SAP Data Services to access table data in an SAP system.

Use: DEV, PROD

Text (Description): Table Maintenance (via standard tools such as SM30)

Class: Basis

Field Value

Activity 03

Authorization group Table groups that a user is allowed to access

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 411
6.20.1.12 S_TCODE

Data Services uses the S_TCODE authorization in several ways.

Purpose: This authorization grants the user access to specific transactions.

Text (Description): Authorization check for transaction start

Class: Cross-application authorization object

Field Value

Transaction Code SE37, SE38, SU53

Purpose: This authorization allows Data Services to execute functions in the Data Warehousing Workbench.

Use: DEV, PROD

Text (Description): Transaction Code Check at Transaction Start

Class: Cross-application Authorization Objects

Field Values

Transaction Code RSA1

6.20.1.13 S_USER_GRP

Authorization for SAP Data Services to establish a connection to the SAP server.

Use: DEV, PROD

Text (Description): User Master Maintenance: User Groups

Class: Basis: Administration

Field Values

User group in user master maintenance User group for Data Services user

6.20.2 Using RFC Streaming With Tables

There are advantages and disadvantages to using either RFC or non-RFC streaming.

The non-RFC streaming is done by extracting the whole target recordset as one batch. That process is
anywhere between 0.1second and 10 seconds faster (depends on the SAP ECC response) than the small-batch
RFC streaming. So, non-RFC streaming is noticeably faster on very small queries, especially with a slow SAP
ECC system. Extracting a whole recordset at once comes with the obvious requirement to have enough
memory for the whole recordset. A general rule (depending on the record length) is 1 GB of RAM on the Data
Provisioning Agent machine per 1 million records, and several concurrent sessions would require further
calculations. Because the non-RFC streaming mode runs in the ECC “dialog mode,” it is also subject to various
limitations on the ECC side, like dialog mode timeout.

Installation and Configuration Guide


412 PUBLIC Configure Data Provisioning Adapters
We recommend using RFC streaming based on the fact that it works for many different scenarios, such as
small, large, and long queries, multiple concurrent sessions, and so on. There are tradeoffs, such as the
performance cost already mentioned for small queries and the cost of requiring extra configuration, including
on the ECC side.

To activate RFC streaming, you must configure the following ABAP adapter remote source parameters:

● Streaming Read: This parameter must be set to True to expose the following parameters.
The following parameters must be set to have RFC streaming work:
○ Gateway Server
○ Gateway Host
○ RFC Destination
The following parameters are optional when RFC streaming is enabled:
○ Batch size
○ RFC Trace
○ Batch receive timeout

ECC Client and Gateway Service Configuration

● Successful registration on an SAP Gateway requires that suitable security privileges are configured. For
example:
○ Set up an Access Control List (ACL) that controls which host can connect to the gateway. That file
should contain something similar to the following syntax: <permit> <ip-address[/mask]>
[tracelevel] [# comment]
○ You may also want to configure a reginfo file to control permissions to register external programs.
● The host where the Data Provisioning agent is running must have a service configured with the name
matching the remote SAP gateway name.

Related Information

SAP ABAP Adapter Remote Source Configuration [page 414]


Gateway Access Control Lists

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 413
6.20.3 SAP ABAP Adapter Preferences

Options to control the SAP ABAP adapter.

Parameter Description

Context Whitelist The Context Whitelist parameter provides you the ability to restrict which
objects - tables, BAPI functions, ODP extractors - are available to a user. For exam­
ple, shown/imported/executed/selected from/subscribed to.

If the property is empty, there are no restrictions; all objects that the ABAP adapter
reads from an ECC system are exposed to the target SAP HANA system.

The property value is expected to be a comma-separated list of either prefixes,


such as a prefix ending with “*”, or full names of allowed objects or exact full
names. For example:

To allow all BAPI functions and ABAPTABLES and exclude all extractors:

BAPI*,ABAPTABLES*

To allow all BAPI functions starting either with RODPS_* or BAPI_BANK*, and only
one ABAP table KNB1

BAPI.RODPS_*,BAPI.BAPI_BANK*,ABAPTABLES.KNB1

 Note
The asterisk (*) is used only as the last character to distinguish a prefix from
an exact name.

6.20.4 SAP ABAP Adapter Remote Source Configuration

Remote source configuration options for the SAP ABAP adapter. Also included is sample code for creating a
remote source using the SQL console.

 Note

Depending on the values you choose for the remote source configuration parameters, different parameters
appear. Thus, some of the following parameters do not appear.

Category Option Description

Connectioninfo Connection Type Message Server and Custom Application Server

Application Server The name of the host to which you want to connect

Message Server Enter the name of the message server or its IP address.

Message Server Port (Optional) If the message server isn't on the default port, en­
ter the port to use to connect to the message server.

Installation and Configuration Guide


414 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Client The SAP ECC client number

Instance Number The SAP ECC instance number

System ID Specifies the system ID of the SAP system to which you want
to connect.

Server Group The Logon group name.

Connections Pool Size Maximum number of idle connections kept open for the re­
mote source. The default value of 0 states that there is no
connection pooling; that is, connections will be closed after
each request.

Connections Limit Maximum number of active connections that can be created


for a remote source simultaneously.

Extractors ODP Version Specifies the ODP version to use.

ODP 2.0 is the default value.

CDC Batch Size, MB Specifies the CDC batch size in MB.

1 MB is the default value.

Streaming Read Set to On to expose the necessary parameters to enable RFC


streaming.

Set to Off to use non-RFC streaming.

Gateway Host This parameter is optional. It is necessary only if you are


streaming ABAP tables for loading.

Specifies the gateway host where the ABAP adapter would


register an RFC server instance to receive callbacks with the
table data batches. Usually, the gateway host is the same as
the target ECC system host.

Gateway Server This parameter is optional. It is necessary only if you are


streaming ABAP tables for loading.

Specifies the gateway server where the ABAP adapter would


register an RFC server instance to receive callbacks with the
table data batches. The gateway server has the value
sapgw<target_ECC_system_instance_number>.

RFC Destination This parameter is optional. It is necessary only if you are


streaming ABAP tables for loading.

Using transaction SM59, you must create a TCP/IP connec­


tion with a user-defined name and provide that name as the
value of the RFC Destination parameter. The connection in
SM59 should be created with “Registered Server Program” as
“Activation Type”. Specify “IM_HANA_ABAPADAPTER_*” as a
filter for the “Program ID” field, or leave it empty.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 415
Category Option Description

Batch Size, MB (Optional) The size (in MB) of the data packet sent by ECC in
one callback. On the Data Provisioning Agent, upon receiving,
the batch is copied into a queue to be sent to Data Provision­
ing server, and thus the memory requirements for that proc­
ess is “2 x batchsize”. The default value is 1 MB.

RFC Trace (Optional) Set to On to turn RFC tracing on. By default, this
parameter is set to Off.

Batch Receive Timeout (Optional) The maximum time period in seconds that the
adapter would be waiting for the next batch to come or to
push the batch to Data Provisioning server. It wouldn't make
sense for this value to be larger than the value of the “frame­
work.messageTimeout” parameter of Data Provisioning
server. Thus, the default value is the same as the default value
of the Data Provisioning server property (600 seconds).

SNC Mode Activate SNC by setting this parameter to On.

SNC Library Specifies the path and file name of the external library.

The default is the system-defined library as defined in the en­


vironment variable SNC_LIB .

The destination service uses the property snc/


gssapi_lib on SAP NetWeaver AS for Java.

SNC Name of Client Specifies the SNC name of SAP NetWeaver AS for Java.

Although this parameter is optional, we do recommend set­


ting it to make sure that the correct SNC name is used for the
connection.

For the Destination service, set it in the property snc/


identity/as on SAP NetWeaver AS for Java.

SNC Name of SAP Server Specifies the SNC name of SAP NetWeaver Application
Server for ABAP.

This parameter is required, if SNC is turned on.

You can find the application server SNC name in the profile
parameter snc/identity/as on SAP NetWeaver Applica­
tion Server for ABAP.

SNC SSO Turn on/off the SSO mechanism of SNC. If you set this param­
eter to OFF, you must provide alternative credentials.

Installation and Configuration Guide


416 PUBLIC Configure Data Provisioning Adapters
Category Option Description

SNC Quality of Protection Specifies the level of protection to use for the connection.

Possible values:

1: Authentication only

2: Integrity protection

3: Privacy protection (default)

8: Use the value from snc/data_protection/use on


the application server

9: Use the value from snc/data_protection/max on


the application server

Default value = 3

Credentials Credentials Mode Remote sources support two types of credential modes to ac­
cess a remote source: technical user and secondary creden­
tials.

● Technical User: A valid user and password in the remote


database. This valid user is used by anyone using the re­
mote source.
● Secondary User: A unique access credential on the re­
mote source assigned to a specific user.

User Name The user name that is used to connect to the SAP ECC sys­
tem

Password The user password

After you have created the remote source, the directory structure will look similar to the following screenshot,
depending on the structure of the source system.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 417
Example

 Sample Code

CREATE REMOTE SOURCE "MyABAPSource" ADAPTER "ABAPAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyEntry name="host" displayName="Host" isRequired="true"
isPassword="false">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="systemid" displayName="System ID" isRequired="true"
isPassword="false">01</PropertyEntry>
<PropertyEntry name="client" displayName="Client" isRequired="true"
isPassword="false">001</PropertyEntry>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="user">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Using RFC Streaming With Tables [page 412]

Installation and Configuration Guide


418 PUBLIC Configure Data Provisioning Adapters
6.21 SAP ASE

The SAP ASE adapter provides real-time replication and change data capture functionality to SAP HANA or
back to a virtual table.

The SAP ASE Adapter receives the data stream from an SAP ASE database, reformats the data, and then sends
the data change to the downstream Data Provisioning Server to replicate from SAP ASE to SAP HANA.

The SAP ASE adapter service provider is created as a remote source, and requires the support of artifacts like
virtual tables and remote subscription for each source table to perform replication.

 Restriction

For real-time replication, you can initialize each source database by only one instance of the adapter. You
cannot configure two adapter instances for real-time replication of the same source database, even when
using a different Data Provisioning Agent or schema in the source database.

Data Transfer Protocol

Depending on the ASE Server and Data Provisioning Agent platforms you are using, there are restrictions on
what data transfer protocol you can use. Data transfer protocol is set in the remote source configuration
parameters.

ASE Server Platform DP Agent Platform Allowed Data Transfer Protocol

Linux Linux CI and LTL

Linux Linux PPCLE CI and LTL

Linux Windows LTL

Adapter Functionality

The SAP ASE adapter supports the following functionality:

● Virtual table as a source


● Real-time change data capture
● Virtual table as a target using a Data Sink node in a flowgraph
● Loading options for target tables
● Search for a table
● Replication monitoring and statistics

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 419
Real-time Replication Limitations

The following limitations exist when performing real-time replication:

● Unsupported table types:


○ Table with all LOB columns
○ Table with LOB column and no primary key or unique index
○ Table with duplicated rows and no primary key
○ Table with minimal logging option

Related Information

Configure Your SAP ASE Database [page 420]


SAP ASE Adapter Preferences [page 421]
SAP ASE Remote Source Configuration [page 422]
Load Behavior Options for Targets in Replication Tasks

6.21.1 Configure Your SAP ASE Database

The remote database must be set up properly when using the SAP ASE adapter.

Procedure

1. Connect to an SAP ASE data server using ISQL or another utility, and create a database to replicate if one
does not already exist.
2. Create the primary user and grant permissions.

 Sample Code

SQL> use master


SQL> go
SQL> create login <login_name> with password <password> default database
<database_name>
SQL> go
SQL> use <database_name>
SQL> go
SQL> sp_adduser <login_name>
SQL> go
SQL> sp_role ‘grant’, replication_role, <login_name>
SQL> go

3. Create the maintenance user.

Installation and Configuration Guide


420 PUBLIC Configure Data Provisioning Adapters
 Sample Code

SQL> use master


SQL> go
SQL> create login <login_name> with password <password> default database
<database_name>
SQL> go
SQL> use <database_name>
SQL> go
SQL> sp_adduser <login_name>
SQL> go

4. Add an entry for the SAP ASE adapter in the interface file of the SAP ASE data server. For example:

 Sample Code

<entry name>
master tcp ether <host name or IP> <port>
query tcp ether <host name or IP> <port>

 Note

○ The entry name must be the same as the Adapter Instance Name specified when creating the
remote source.
○ The host name or IP must be the same IP of the computer where the SAP ASE adapter is running.
○ The port must be the same as the SAP ASE Adapter Server port that you set up in the SAP ASE
adapter interface file located in <DPAgent_root>/Sybase/interfaces.

5. Reboot the SAP ASE data server.

Related Information

SAP ASE Remote Source Configuration [page 422]


SAP ASE Adapter Preferences [page 421]

6.21.2 SAP ASE Adapter Preferences

Options to control the SAP ASE adapter.

Parameter Description

Adapter Server Name The name of the SAP ASE adapter server that receives data changes from the SAP
ASE data server.

Adapter Server Port The port number for the SAP ASE adapter server.

Enable SSL for Adapter Server Specifies whether to use SSL for the adapter server.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 421
Parameter Description

SSL Certificate File Path Location of the SSL certificate file.

SSL Certificate File Password The password for accessing the SSL certificate file.

6.21.3 SAP ASE Remote Source Configuration

Options for connecting to the remote SAP ASE data server. Also included is sample code for creating a remote
source using the SQL console.

Category Option Description

Data Server Information Data Server Name The SAP ASE data server name.

Data Server Host Host name or IP address on which the remote SAP
ASE data server is running.

Data Server Port Number The SAP ASE data server port number.

Database Name The SAP ASE database name.

Security Properties Enable SSL Encryption Specifies whether to SSL encryption between the
source SAP ASE data server and SAP ASE adapter.

 Note
The CA certificate for the remote source must
be imported into the adapter truststore on the
Data Provisioning Agent host.

Common Name in Server Certifi- The common name in SAP ASE Adapter certificate
cate file.

Adapter Properties Adapter Instance Name The SAP ASE adapter instance name, which must
be specified when creating remote source. You can
name the adapter instance anything you want, and it
should be unique in the same SAP HANA server.

ASEAdapter sends this name to the source ASE,


then ASE RepAgent (the log extract and transfer en­
gine) searches this name from its specified interfa­
ces file to find the section of the same name. So in
the source ASE's interfaces files, there must be a
section that contains the connection information.

Installation and Configuration Guide


422 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Data Transfer Protocol The protocol the SAP ASE data server and SAP ASE
adapter uses to transfer data.

LTL: The Sybase Log Transfer Language. Logs are


transferred in text format. A syntax parser in ASEA­
dapter will parse data from the text. This mode is a
traditional method, and the log data is transferred in
readable format, which is helpful when an error oc­
curs.

CI: The Sybase Component Interfaces. Logs are


transferred in binary format. The data extractor in
ASEAdapter translates the binaries into actual data.
Usually, CI has better performance than LTL mode.

Only CI or LTL is allowed. The default value is CI.

Maintenance User The maintenance user that is used by the SAP ASE
LogReader Thread to filter transactions applied by
this user.

Read-only Remote Source Specifies that the remote source should be a read-
only resource and disables write-back functionality,
including INSERT, UPDATE, and DELETE queries.

Credential Properties Credentials Mode Remote sources support two types of credential
modes to access a remote source: technical user
and secondary credentials.

● Technical User: A valid user and password in the


remote database. This valid user is used by
anyone using the remote source.
● Secondary User: A unique access credential on
the remote source assigned to a specific user.

User Name The SAP ASE database user, which the adapter
needs to log on to the SAP ASE database to config-
ure the ASE log reader, query data for initial load,
and write back data into SAP ASE. Certain permis­
sions may be required. See Configure Your SAP ASE
Database [page 420] for more information.

Password SAP ASE database user password.

LTL mode with SSL

Example

 Sample Code

CREATE REMOTE SOURCE "MyASESource" ADAPTER "ASEAdapter" AT LOCATION AGENT


"MyAgent"

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 423
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations" displayName="Configurations">
<PropertyGroup name="dataserver" displayName="Data Server Information">
<PropertyEntry name="dataserver_name" displayName="Data Server
Name">myserver</PropertyEntry>
<PropertyEntry name="host" displayName="Data Server
Host">myhost.sjc.sap.corp</PropertyEntry>
<PropertyEntry name="port" displayName="Data Server Port Number">12020</
PropertyEntry>
<PropertyEntry name="database_name" displayName="Database Name">mydb</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security Properties">
<PropertyEntry name="ssl_enable" displayName="Enable SSL
Encryption">true</PropertyEntry>
<PropertyEntry name="cn_in_certificate" displayName="Common Name in
Server Certificate">myserver</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="aseadapter" displayName="Adapter Properties">
<PropertyEntry name="adapter_instance_name" displayName="Adapter Instance
Name" isRequired="true">myinstance</PropertyEntry>
<PropertyEntry name="data_transfer_protocol" displayName="Data Transfer
Protocol" isRequired="true">LTL</PropertyEntry>
<PropertyEntry name="maint_user" displayName="Maintenance User"
isRequired="true">mydb_maint</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>'

Related Information

Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Configure Your SAP ASE Database [page 420]

6.22 SAP ECC

SAP ERP Central Component (ECC) adapters are a set of data provisioning adapters to provide access to and
interaction with SAP ECC data and metadata.

All adapters designed to work with SAP ECC are built on top of Data Provisioning log reader adapters for the
same database. Currently supported are the following:

● IBM DB2
● Oracle

Installation and Configuration Guide


424 PUBLIC Configure Data Provisioning Adapters
 Note

The Oracle Log Miner maximum throughput is approximately 1 TB per day; therefore, for replication
volumes greater than 1 TB per day, expect delays in replication.

● Microsoft SQL Server


● SAP ASE

These adapters provide extra ECC-specific functionality: ECC metadata browsing and support for cluster tables
and pooled tables in SAP ECC. Please see the description of Log Reader adapters for the common functionality.

 Note

For IBM DB2, Oracle, and Microsoft SQL Server (does not apply to SAP ASE), before registering the adapter
with the SAP HANA system, download and install the correct JDBC libraries. See the SAP HANA smart data
integration Product Availability Matrix (PAM). In the <DPAgent_root> folder, create a /lib

Adapter Functionality

The ECC adapters support the following functionality:

● Real-time change-data capture

 Restriction

For real-time replication, you can initialize each source database by only one remote source. You cannot
configure two remote sources for real-time replication of the same source database, even when using a
different Data Provisioning Agent or schema in the source database.

● DDL propagation (transparent tables only, not supported for SAP ASE ECC)
● Search for tables
● Agent-stored credentials (not supported for SAP ASE ECC)
● SELECT, WHERE, JOIN, GROUP BY, DISTINCT, TOP, LIMIT

Limitations

There is a 30,000 column limit for records.

Related Information

Terminology [page 426]


Installation and Setup [page 426]
SAP ECC Adapter Preferences [page 427]
Permissions for ECC Dictionary Tables [page 436]
Create an ECC Remote Source [page 436]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 425
SAP ECC Remote Source Configuration [page 437]
Creating a Whitelist to Limit Access to a Source Database [page 439]
SQL Pushdown for Pooled and Cluster Tables [page 440]
Loading Metadata for Cluster and Pooled Tables [page 441]
SAP ASE [page 419]
IBM DB2 Log Reader [page 254]
Microsoft SQL Server Log Reader [page 301]
Oracle Log Reader [page 349]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

SAP Note 2166986

6.22.1 Terminology

Setting up ECC adapters requires an understanding of certain SAP ERP and ECC concepts.

Here are some key terms and concepts that help you understand how to set up your ECC adapters.

Term Description

SAP ERP Enterprise Resource Planning software that allows you to leverage role-based access to criti­
cal data, applications, and analytical tools – and streamline your processes across procure­
ment, manufacturing, service, sales, finance, and HR.

SAP ECC (SAP ERP Central The central technical component of SAP ERP system.
Component)

Cluster table A logical table type, where the data of several such tables are stored together as a table clus­
ter in the database. The intersection of the key fields of the cluster tables forms the primary
key of the table cluster. Therefore, a cluster table is known in the ABAP Dictionary, but not in
the database.

Pooled table A logical table type, where the data of several such tables are stored together as a table pool
in the database. Therefore, a pooled table is known in the ABAP Dictionary, but not in the
database.

Related Information

Loading Metadata for Cluster and Pooled Tables [page 441]

6.22.2 Installation and Setup

Refer to Log Reader and SAP ASE adapters for installation and setup information.

Because the SAP ECC adapters are built on top of existing Data Provisioning adapters, you must use the
procedures of those adapters to build your SAP ECC adapters.

Installation and Configuration Guide


426 PUBLIC Configure Data Provisioning Adapters
Related Information

SAP ASE [page 419]


Oracle Log Reader [page 349]
Microsoft SQL Server Log Reader [page 301]
IBM DB2 Log Reader [page 254]

6.22.3 SAP ECC Adapter Preferences

Access adapter settings specific to your source.

You can adjust adapter settings specific to your source in the Data Provisioning Agent Configuration Tool by
running <DPAgent_root>/configTool/dpagentconfigtool.exe.

Use these settings to tune performance, enhance security, and so on.

Related Information

DB2ECCAdapter Preferences [page 427]


MssqlECCAdapter Preferences [page 429]
OracleECCAdapter Preferences [page 432]
SAP ASE ECC Adapter Preferences [page 435]

6.22.3.1 DB2ECCAdapter Preferences

Configuration parameters for the DB2 ECC adapter.

 Note

Log Reader and ECC adapter preferences, except for Number of wrapped log files, Enable verbose trace, and
Maximum log file size, are no longer set in the Data Provisioning Agent Configuration Tool. They are now
moved to the remote source configuration options in SAP HANA. If you have upgraded from a previous
version, then the settings you find in the Agent Configuration Tool are your previous settings, displayed for
your reference.

Parameter Description Default value

Maximum operation queue size The maximum number of operations 1000


permitted in the log reader operation
queue during replication.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 427
Parameter Description Default value

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Ignore log record processing errors Determines whether to ignore log re­ false
cord processing errors.

Replicate LOB columns Determines whether the agent applies true


each individual LOB change.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library (DBLIB, 5


connection fails ODBC, ADO, and so on) to keep retrying
the connection attempt, as long as the
server is not found, for the specified
number of times.

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size, in 1-K blocks, of the 3
LogReader system log file before wrap­
ping.

Enable verbose trace Enables or disables extra diagnostic in­ false


formation in the agent system log files.

Maximum log file size Limit the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not LogReader TRUE


should turn on a-synchronized logging
mode. (TRUE, FALSE)

Maximum size of work queue for asyn­ The Maximum size of the work queue 1000
chronous logging for asynchronous logging file handler to
collect the log records (1 to
2147483647)

Installation and Configuration Guide


428 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Discard policy for asynchronous logging Specifies the discard policy for asyn­ BLOCKING
file handler chronous logging file handler when the
work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offered into queue are
dropped.
● DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried, which can fail
again, causing this process to be
repeated.

6.22.3.2 MssqlECCAdapter Preferences

Configuration parameters for the MS SQL ECC adapter.

 Note

Log Reader and ECC adapter preferences, except for Number of wrapped log files, Enable verbose trace, and
Maximum log file size, are no longer set in the Data Provisioning Agent Configuration Tool. They are now
moved to the remote source configuration options in SAP HANA. If you have upgraded from a previous
version, then the settings you find in the Agent Configuration Tool are your previous settings, displayed for
your reference.

Parameter Description Default value

Maximum operation queue size The maximum number of operations 1000


permitted in the log reader operation
queue during replication.

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 429
Parameter Description Default value

Maximum wait interval between log The maximum wait interval between 60
scans Log Reader transaction log scans.

 Note
● The value of the parameter is
the maximum number of sec­
onds that can elapse before
the Log Reader component
scans the transaction log for a
transaction to be replicated,
after a previous scan yields no
such transaction.
● For reduced replication latency
in an infrequently updated da­
tabase, we recommend lower
number settings for the pa­
rameter.
● If the primary database is con­
tinuously updated, the value of
the parameter is not signifi-
cant to performance.

Installation and Configuration Guide


430 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Seconds to add to each log scan wait The number of seconds to add to each 5
interval wait interval before scanning the trans­
action log, after a previous scan yields
no transaction to be replicated.

 Note
● The value of the parameter is
the number of seconds added
to each wait interval before the
LogReader component scans
the log for a transaction to be
replicated, after a previous
scan yields no such transac­
tion.
● The number of seconds speci­
fied by the parameter is added
to each wait interval, until the
wait interval reaches the value
specified by the “Maximum
wait interval between log
scans” parameter.
● For optimum performance, the
value of the parameter should
be balanced with the average
number of operations in the
primary database over a pe­
riod of time. In general, better
performance results from
reading more operations from
the transaction log during
each LogReader scan.
● With a primary database that
is less frequently updated, in­
creasing the value of the pa­
rameter may improve overall
performance.
● If the database is continuously
updated, the value of the pa­
rameter may not be significant
to performance.

Replicate LOB columns Determines whether the agent applies true


each individual LOB change.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library (DBLIB, 5


connection fails ODBC, ADO, and so on) to keep retrying
the connection attempt, as long as the
server is not found, for the specified
number of times.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 431
Parameter Description Default value

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size, in 1 K blocks, of the 3


agent system log file before wrapping.

Enable verbose trace Enables or disables extra diagnostic in­ false


formation in the agent system log files.

Maximum log file size Limit the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not LogReader TRUE


should turn on a-synchronized logging
mode. (TRUE, FALSE)

Maximum size of work queue for asyn­ The Maximum size of the work queue 1000
chronous logging for asynchronous logging file handler to
collect the log records (1 to
2147483647)

Discard policy for asynchronous logging Specifies the discard policy for asyn­ BLOCKING
file handler chronous logging file handler when the
work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offered into queue are
dropped.
● DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried (which can fail
again, causing this process to be
repeated.).

6.22.3.3 OracleECCAdapter Preferences

Configuration parameters for the Oracle ECC adapter.

 Note

Log Reader and ECC adapter preferences, except for Number of wrapped log files, Enable verbose trace, and
Maximum log file size, are no longer set in the Data Provisioning Agent Configuration Tool. They are now
moved to the remote source configuration options in SAP HANA. If you have upgraded from a previous
version, then the settings you find in the Agent Configuration Tool are your previous settings, displayed for
your reference.

Installation and Configuration Guide


432 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Distinguished Name (DN) in Certificate The distinguished name (DN) of the pri­
mary data server certificate.

● This parameter is only valid if Use


SSL is set to “true”.
● If this parameter is set, the DN field
in the server certificate is verified
to match this parameter. If it does
not match, the connection to the
primary data server fails.

Oracle supplemental logging level Specifies the level of supplemental log­ table
ging.

● Table: Table level turns on supple­


mental logging for subscribed ta­
bles and some required system ta­
bles.
● Database: Database level turns on
supplemental logging for all tables,
including system tables.

Maximum operation queue size Specifies the maximum number of op­ 1000
erations permitted in the log reader op­
eration queue during replication.

Maximum scan queue size The maximum number of log records 1000
permitted in the log reader log scan
queue during replication.

Maximum session cache size The maximum number of Oracle ses­ 1000
sions to be cached in memory during
replication

Enable parallel scanning Specifies whether to turn on parallel false


scanning.

To achieve better performance for high-


volume log throughput, set the parame­
ter to true to enable parallel scanning.

Queue size of parallel scan tasks Specifies the number of tasks in the 0
queue.

Parallel scan SCN range The maximum number of system 1024


change numbers (SCN) processed by
each Oracle LogMiner scanner, when
parallel scan is enabled, that is, when
lr_parallel_scan is true.

Number of parallel scanners Specifies the number of parallel scan­ 4


ners.

Number of log record rows fetched by Specifies the number of log record rows 1
the scanner at a time fetched by the scanner.

Ignore log record processing errors Determines whether to ignore log re­ false
cord processing errors.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 433
Parameter Description Default value

Replicate LOB columns Oracle logs all LOB data (except for true
BFILE datatypes) in the Oracle redo log.
This action allows the agent to apply
each individual LOB change. However,
for BFILE data, the same technique is
used.

Ignore data of unsupported types Specifies whether you want to ignore false
stored in ANYDATA data with unsupported types housed in
ANYDATA wrapper.

Database connection pool size Maximum number of connections al­ 15


lowed in the connection pool on a sec­
ondary node.

Number of times to retry to connect if a Instructs the client library (DBLIB, 5


connection fails ODBC, ADO, and so on) to keep retrying
the connection attempt, as long as the
server is not found, for the specified
number of times.

Timeout in seconds to retry connecting The number of seconds the agent waits 10
between retry attempts to connect to
the primary database.

Number of wrapped log files The maximum size, in 1-K blocks, of the 3
agent system log file before wrapping.

Enable verbose trace Enables or disables extra diagnostic in­ false


formation in the agent system log files.

Maximum log file size Limit the size of the message log to 1000
conserve disk space.

Turn on asynchronous logging mode Specifies whether or not LogReader TRUE


should turn on asynchronous logging
mode. (TRUE, FALSE)

Maximum size of work queue for asyn­ The Maximum size of the work queue 1000
chronous logging for asynchronous logging file handler to
collect the log records (1 to
2147483647)

Installation and Configuration Guide


434 PUBLIC Configure Data Provisioning Adapters
Parameter Description Default value

Discard policy for asynchronous logging Specifies the discard policy for asyn­ BLOCKING
file handler chronous logging file handler when the
work queue is saturated.

● BLOCKING: If the executor is not


shut down, insert the specified ele­
ment at the end of this queue and
wait for space to become available.
● DISCARD: The log records that
cannot be offered into queue are
dropped.
● DISCARD_OLDEST: The log record
at the head of the work queue is
dropped, and then the log record
offering is retried (which can fail
again, causing this process to be
repeated.).

Related Information

Oracle Database Permissions [page 352]


Oracle Supplemental Logging [page 360]

6.22.3.4 SAP ASE ECC Adapter Preferences

Options to control the SAP ASE ECC adapter.

Parameter Description

Adapter Server Name The name of the SAP ASE adapter server that receives data changes from the SAP
ASE data server.

Adapter Server Port The port number for the SAP ASE adapter server.

Enable SSL for Adapter Server Specifies whether to use SSL for the adapter server.

SSL Certificate File Path Location of the SSL certificate file.

SSL Certificate File Password The password for accessing the SSL certificate file.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 435
6.22.4 Permissions for ECC Dictionary Tables

To replicate SAP ECC dictionary tables, you need specific permissions, depending on the database you are
using.

Table 49:

Database Permissions or instructions

DB2 GRANT DBADM, CREATETAB, BINDADD, CONNECT, CREATE_NOT_FENCED_ROUTINE, IM­


PLICIT_SCHEMA, LOAD, CREATE_EXTERNAL_ROUTINE, QUIESCE_CONNECT ON DATA­
BASE TO USER DPADM

Oracle Permissions are granted when setting up your adapter by running the script found in the
oracle_init_example.sql file, which is located in the Scripts folder of the Data
Provisioning Agent installation (<DPAgent_root>\LogReader\Scripts).

Related Information

Remote Database Setup for Oracle Real-time Replication [page 359]


Remote Database Setup for DB2 Real-time Replication [page 256]

6.22.5 Create an ECC Remote Source

Create a remote source for your ECC adapter.

Context

The following is an example of creating an ECC Adapter remote source in SAP HANA studio.

Procedure

1. In the Systems view, open Provisioning Remote Sources .


2. Right-click Remote Sources, and select New Remote Source.
3. Enter the required information for your particular database and ECC information.
4. Click the Save icon in the upper right-hand corner of the screen.

Installation and Configuration Guide


436 PUBLIC Configure Data Provisioning Adapters
Related Information

SAP ECC Remote Source Configuration [page 437]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
DB2 Log Reader Remote Source Configuration [page 270]
Oracle Log Reader Remote Source Configuration [page 370]
Create Credentials for a Secondary User
SAP ASE Remote Source Configuration [page 422]

6.22.6 SAP ECC Remote Source Configuration

Configuration settings for accessing ECC remote sources. Also included are sample codes for creating remote
sources using the SQL console.

The following ECC-specific parameter is for creating a remote source. You can find information about database-
specific parameter information in the remote source parameter topics for Log Reader adapters.

ERP Additional Info Options Description

Owner/Schema The source database owner/schema for all ECC tables.


Typically, this value is “SAPSR3”.

Dictionary Schema If you want to use pool or cluster tables, you have to
replicate a set of DD* tables into SAP HANA. The Dictionary
Schema must be the schema name where those tables are
replicated.

 Note
This parameter is available only with the SAP ASE ECC
adapter.

Use empty string for values only containing white space Set this parameter to True so that any column value
containing only white space is converted to an empty string;
otherwise, the white space remains. The default value is
False.

The value of this parameter may not be changed when the


remote source is suspended.

Example: IBM DB2 ECC Adapter

 Sample Code

CREATE REMOTE SOURCE "MyDB2Source" ADAPTER "DB2ECCAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 437
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_host_name" displayName="Host">myhost.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">50000</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>
<PropertyEntry name="pds_datasource_name" displayName="Database
SourceName">mydb</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="erpadditionalinfo" displayName="ERP Additional Info">
<PropertyEntry name="schema" displayName="Owner/Schema">SAPSR3</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Example: Microsoft SQL Server ECC Adapter

 Sample Code

CREATE REMOTE SOURCE "MySQLServerSource" ADAPTER "MssqlECCAdapter" AT


LOCATION AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="data_type_coversion" displayName="Data Type Coversion">
<PropertyEntry name="map_char_types_to_unicode" displayName="Always Map
Character Types to Unicode">false</PropertyEntry>
<PropertyEntry name="map_time_to_timestamp" displayName="Map SQL Server Data
Type Time to Timestamp">true</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_server_name" displayName="Host">myserver.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">1433</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">mydb</
PropertyEntry>
<PropertyEntry name="pdb_dcmode" displayName="Database Data Capture
Mode">MSCDC</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc" displayName="CDC Properties">
<PropertyGroup name="logreader" displayName="LogReader">
<PropertyEntry name="skip_lr_errors" displayName="Ignore log record decluster
errors">false</PropertyEntry>
</PropertyGroup>
</PropertyGroup>
<PropertyGroup name="erpadditionalinfo" displayName="ERP Additional Info">
<PropertyEntry name="schema" displayName="Owner/Schema">SAPSR3</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>'

Installation and Configuration Guide


438 PUBLIC Configure Data Provisioning Adapters
Example: Oracle ECC Adapter

 Sample Code

CREATE REMOTE SOURCE "MyOracleSource" ADAPTER "OracleECCAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="pds_host_name" displayName="Host">myhost.sap.corp</
PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">1521</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database Name">myoradb</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="erpadditionalinfo" displayName="ERP Additional Info">
<PropertyEntry name="schema" displayName="Owner/Schema">SAPSR3</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

6.22.7 Creating a Whitelist to Limit Access to a Source


Database

There are times when you may want to limit access to all of the tables in a source database. For data
provisioning log reader adapters, as well as SAP HANA and SAP ECC adapters, an efficient way to limit access
is to create a whitelist.

Restricting access to only those tables that are to be replicated is done by creating a whitelist of source
database objects in a separate table.

 Note

The whitelist impacts only the virtual table created and the replications created after the whitelist was
created.

You can use SQL to create the whitelist table.

 Note

● The whitelist table, which can have any name, must have two columns named
REMOTE_SOURCE_NAME and WHITELIST.
● The whitelist items are separated by a comma.
● You can use an asterisk (*) to represent any character or empty string. However, the asterisk must be
placed at the end of a whitelist item. Otherwise, it is treated as a normal character.
● You can add multiple rows of whitelisted tables for a single remote source.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 439
Microsoft SQL Server Example

create table whitelist(REMOTE_SOURCE_NAME varchar(128), WHITELIST varchar(4000));

To add a whitelist for the remote source called “localmssqldb”, insert a row into the whitelist table:

insert into whitelist values('localmssqldb', 'object.A, object.B*');


insert into whitelist values('localmssqldb', 'object.C, object.D*');

object.A, object.B*, and so on, means that the table (or procedure) object.A and the table (or procedure)
starting with object.B are filtered for the remote source “localmssqldb”.

SAP HANA Example

create schema SAP_RESTRICTIONS;


create table WHITE_LIST(REMOTE_SOURCE_NAME varchar(128) primary key, WHITELIST
varchar(4000));

To add a whitelist for the remote source called “localhadp”, insert a row into the whitelist table:

insert into WHITE_LIST values('localhadp', 'APP_USER.MERCHANT,APP_PRODUCT.B*');

APP_USER.MERCHANT,APP_PRODUCT.B* means that the table (or procedure) APP_USER.MERCHANT and


the table (or procedure) starting with APP_PRODUCT.B are filtered for remote source “localhadp”.

6.22.8 SQL Pushdown for Pooled and Cluster Tables

There are limitations for SQL pushdown operations to SAP ECC pooled and cluster tables.

There is no SQL pushdown for pool tables. For cluster tables, there is limited SQL pushdown.

If SQL pushdown is not available for a given SQL statement, then the SQL is performed within the SAP HANA
system. Pushing down the SQL results in better performance.

Keep the following in mind when using pushdown for cluster tables:

● The SELECT statement’s WHERE clause must contain only fields that are keys in both the parent table
cluster and the contained cluster table.
● The SELECT clause is limited to field names from the cluster table or *.

For example, the cluster table KONV is contained within the table cluster KOCLU. The table cluster KOCLU has
three keys MANDT, KNUMV, and PAGENO. The cluster table KONV has keys MANDT, KNUMV, KPOSN, STUNR,
ZAEHK. The only keys which they have in common are MANDT and KNUMV. So, the WHERE clause cannot
refer to any fields other than MANDT and KNUMV.

If VT_KONV is a virtual table to the KONV cluster table, then:

SELECT * FROM VT_KONV WHERE MANDT=’001’ AND KNUMV=’321’

Installation and Configuration Guide


440 PUBLIC Configure Data Provisioning Adapters
can be pushed down, because both MANDT and KNUMV are keys in both the KONV cluster table and the
parent KOCLU table cluster.

However,

SELECT COUNT(*) FROM VT_KONV WHERE MANDT=’001’ AND KNUMV=’321’

cannot be pushed down, because the SELECT clause contains something other than KONV field names or *.

6.22.9 Loading Metadata for Cluster and Pooled Tables

Load cluster and pooled table metadata. This only applies to the SAP ASE ECC adapter.

Before working with SAP ASE ECC cluster or pooled tables, their metadata must be loaded into SAP HANA into
a schema specified by the dictionarySchema attribute. To do this, execute the
replicate_dictionary.sql script, and then create and execute the stored procedures that are listed
below.

 Note

We previously created remote subscriptions for the dictionary tables (DD* tables). Because these tables
are typically static, it suffices to materialize these tables once. If there are changes to the contents of the
dictionary tables, you will need to truncate and reload these dictionary tables again by running Step 3.

 Note

Beginning with the ABAP Platform 1808/1809 release, cluster and pooled tables are not supported in SAP
S/4 HANA.

1. In SAP HANA studio, choose File Open and navigate to <DPAgent_root>/LogReader/scripts.


2. Select replicate_dictionary.sql
3. Right click on the text screen, and click Choose Connection. Select your connection, and click OK.
4. Click Execute.
5. Call this stored procedure with the following parameters, after making appropriate replacements for
<HANA_SCHEMA> and <remote_source_name> in replicate_dictionary.sql:

 Note

<HANA_SCHEMA> should be replaced with the name of the schema where you would replicate the DD*
tables. This schema is also specified as the Dictionary Schema while configuring the remote source.
The source (virtual tables) and target tables must also reside in the same schema as the Dictionary
Schema.

○ call materialize_dictionary_table('<HANA_SCHEMA>','<remote_source_name>','DD02L');
○ call materialize_dictionary_table('<HANA_SCHEMA>','<remote_source_name>','DD03L');

 Note

Use this procedure to initial load the DD03L table if your SAP HANA system has plenty of free
memory.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 441
○ call materialize_dictionary_table('<HANA_SCHEMA>','<remote_source_name>','DD16S');
○ call materialize_dictionary_table('<HANA_SCHEMA>','<remote_source_name>','DDNTT');
○ call materialize_dictionary_table('<HANA_SCHEMA>','<remote_source_name>','DDNTF');
○ call
materialize_dictionary_table_dd03l('<HANA_SCHEMA>','<remote_source_name>','<remote_source
_table>');

 Note

This procedure initial loads specific rows for the cluster/pooled table in DD03L if free memory in
your SAP HANA target is limited. Be sure that this procedure is run prior to creating a replication
task or flowgraph for this cluster/pooled table.

6.23 SAP HANA

The SAP HANA adapter provides real-time change data capture capability in order to replicate data from a
remote SAP HANA database to a target SAP HANA database.

Unlike Log Reader adapters, which read a remote database log to get changed data, the SAP HANA adapter is
trigger-based: triggers capture changed data, and the adapter continuously queries the source database to get
the changed data. When a table is subscribed to replicate, the adapter creates three triggers (INSERT, UPDATE,
and DELETE) on the table for capturing data.

The adapter also creates a shadow table for the subscribed table. Except for a few extra columns for
supporting replication, the shadow table has the same columns as its replicated table. Triggers record changed
data in shadow tables. For each adapter instance (remote source), the adapter creates a Trigger Queue table to
mimic a queue. Each row in shadow tables has a corresponding element (or placeholder) in the queue. The
adapter continuously scans the queue elements and corresponding shadow table rows to get changed data
and replicate them to the target SAP HANA database.

Adapter Functionality

This adapter supports the following functionality:

● Source support for ECC on SAP HANA


● Virtual table as a source
● Virtual table as a target using a Data Sink in a flowgraph
● Search for tables in a remote source
● DDL propagation. This adapter supports the ADD COLUMN, and DROP COLUMN operations.
● Real-time change data capture
● Replication monitoring and statistics

In addition, this adapter supports the following capabilities:

Installation and Configuration Guide


442 PUBLIC Configure Data Provisioning Adapters
Table 50: Global Settings

Functionality Supported?

SELECT from a virtual table Yes

INSERT into a virtual table Yes

Execute UPDATE statements on a virtual table Yes

Execute DELETE statements on a virtual table Yes

Different capabilities per table No

Different capabilities per table column No

Real-time Yes

Table 51: Select Options

Functionality Supported?

Select individual columns Yes

Add a WHERE clause Yes

JOIN multiple tables Yes

Aggregate data via a GROUP BY clause Yes

Support a DISTINCT clause in the select Yes

Support a TOP or LIMIT clause in the select Yes

ORDER BY Yes

GROUP BY Yes

Related Information

User Permissions [page 444]


SAP HANA Adapter Preferences [page 444]
SAP HANA Remote Source Configuration [page 444]
SAP HANA DDL Propagation [page 456]
Use a Shadow Remote Source [page 457]
Creating a Whitelist to Limit Access to a Source Database [page 458]
Disable Adapter Write-back Functionality [page 459]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 443
6.23.1 User Permissions

Configure the necessary permissions for SAP HANA adapters.

Ensure that you configure the following permissions:

● For real-time change data capture: TRIGGER on source tables or schema of source tables
● For SAP HANA virtual tables used as a source: SELECT
● For SAP HANA virtual tables used as a target (Data Sink) in an .hdbflowgraph: INSERT, UPDATE, and
DELETE
● If <Schema> is not empty and its value is not equal to <User> in Credentials, GRANT CREATE ANY ON
SCHEMA <Schema> TO <User> WITH GRANT OPTION

6.23.2 SAP HANA Adapter Preferences

Set the thread pool size when executing jobs of querying shadow tables to get change data.

Parameter Description

Thread Pool Size The size of the SAPHANA adapter global thread pool. SAP HANA adapter remote
sources shares the thread pool. The thread pool is used to execute jobs of querying
shadow tables to get change data.

We recommend that you configure the thread pool size to the number of available
processors in the system, if possible.

6.23.3 SAP HANA Remote Source Configuration

Use the SAP HANA adapter to move data from one SAP HANA instance to another. Also included is sample
code for creating a remote source using the SQL console.

Privileges

The following schema privileges on the schemas, under which there are tables to be accessed, must be granted
to the configured user on the remote SAP HANA database:

● For real-time change data capture: TRIGGER on source tables or schema of source tables
● For SAP HANA virtual tables used as a source: SELECT
● For SAP HANA virtual tables used as a target (Data Sink) in an .hdbflowgraph: INSERT, UPDATE, and
DELETE
● If <Schema> is not empty and its value is not equal to <User> in Credentials, GRANT CREATE ANY ON
SCHEMA <Schema> TO <User> WITH GRANT OPTION

Installation and Configuration Guide


444 PUBLIC Configure Data Provisioning Adapters
Remote Source Parameters

Category Option Description

Database Host Auto Failover Enable auto failover for scale-out SAP HANA. The default is
False.

Host The host name or IP address on which the remote SAP


HANA server is running.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Port Number The port number of the remote SAP HANA server.

If the remote SAP HANA server is a single-container system,


the port number is 3<instance>15, and the Database
Name parameter must be empty.

If the remote SAP HANA server is a multiple-container sys­


tem, the port number is 3<instance>13, and the tenant da­
tabase name must be specified in the Database Name pa­
rameter.

 Note
Use an arbitrary port like 1234. Do not put 1433 or 1434
as the instance number.

Execute the following query to obtain the system database


SQL port.

SELECT DATABASE_NAME, SQL_PORT FROM


SYS_DATABASES.M_SERVICES WHERE
DATABASE_NAME='SYSTEMDB' and
SERVICE_NAME='nameserver' and
COORDINATOR_TYPE= 'MASTER';

Auto-Failover Hosts Connec­ The connection string for scale-out HANA auto failover, for­
tion
mat is host1:port1;host2:port2;host3:port3.
This parameter is configurable if Host Auto-Failover is True.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Whitelist Table in Remote Da­ Enter the name of table that contains the whitelist in the re­
tabase mote database.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 445
Category Option Description

Database Name Specifies the database name, if the remote database is a


tenant database. Leave this parameter empty if the remote
database is not a tenant database.

Schema (Case Sensitive) If <Schema> is not empty and its value is not equal to
<User> in Credentials, the SAP HANA adapter creates a ser­
ies of system objects under this schema, instead of <User>.

 Note
This option is no longer required. It is visible solely for
backward compatibility purposes. It was used in previ­
ous versions to restrict the viewing of tables to those ta­
bles under the given schema. Now, you can view all ta­
bles, regardless of the schema they are located under.
For those remote sources that were created in a previ­
ous version, this option value must keep unchanged.

JDBC Connection Properties Extra SAP HANA-supported JDBC connection properties.

Separate each property definition with an ampersand (&).


For example:

distribution=OFF&autocommit=true

For a complete list of supported properties, see “” in the SAP


HANA Client Interface Programming Reference.

Retrieve Last Modified Dates The process of creating a table dictionary queries metadata­
for Objects in Dictionary LastModifiedTimestamp from the source database, which
may take a lot of time.

● True (default): Keeps the current behavior of querying


metadataLastModifiedTimestamp.
● False: Disables the current behavior. If you do not need
the data from metadataLastModifiedTimestamp, set
this parameter to false. Doing so can help with perform­
ance.

Schema Alias Replacements Schema Alias Schema name to be replaced with the schema given in
Schema Alias Replacement. If given, accessing tables under
it is considered to be accessing tables under the schema
given in Schema Alias Replacement.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Installation and Configuration Guide


446 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Schema Alias Replacement Schema name to be used to replace the schema given in
Schema Alias.

 Note
If the schema alias is not configured, leave this blank.

 Note
The value of this parameter can be changed when the
remote source is suspended.

CDC Properties System Object Prefix (Case Insensitive) The prefix of the names of the SAP HANA
adapter system objects created in the source SAP HANA da­
tabase by the adapter. We recommend keeping the default
value of HADP_.

In-Memory Sequences If In-Memory Sequence is set to True, the SAP HANA adapter
creates sequence objects with the statement CREATE
SEQUENCE ... RESET BY ... The default value is
True

Sequence Cache Size If Sequence Cache Size is set to a value of > 1, the SAP HANA
adapter creates sequence objects with statement CREATE
SEQUENCE ... CACHE <cache size> ..., where
<cache size> equals the value of the Sequence Cache Size
parameter. If Sequence Cache Size is set to value of <=1, no
CACHE parameter is appended in the CREATE SEQUENCE
statement.

The default value is 1000. The valid range is 0 to 30000

Reserve System Sequences Set to True (default) if you want the SAP HANA adapter to
reserve the scan_seq and trigger_seq system sequences,
even though all of the subscriptions are dropped or reset.

If you do not want to use this remote source, and you want to
remove the environment, first, set this parameter to False,
then drop the subscription and drop the remote source.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 447
Category Option Description

Connection Pool Size Maximum number of connections allowed in the connection


pool. The default value is 4.

 Note

Minimum Scan Interval in The minimum interval in seconds that the adapter scans the
Seconds Trigger Queue table to get change data. The default value is
0 (seconds), which means there is no waiting time before the
next scan. The value of this parameter can be changed when
the remote source is suspended.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Maximum Scan Interval in The maximum interval in seconds that the adapter scans the
Seconds Trigger Queue table to get change data. The default value is
10 (seconds). If the adapter scans the queue and finds that
the queue is empty, it gradually increases the scan interval
from the minimum scan interval to the maximum scan inter­
val.

 Note
The value of this parameter can be changed when the
remote source is suspended.

DDL Scan Interval in Minutes The interval for detecting DDL changes in the source.

A zero or negative integer disables this parameter.

The default value is 10 (minutes).

 Note
The value of this parameter can be changed when the
remote source is suspended.

Maximum Batch Size The maximum number of consecutive change data on the
same table that is batched to process and send to Data Pro­
visioning Server together. The default value is 128.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Installation and Configuration Guide


448 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Batch Queue Size The internal batch queue size. The batch queue size deter­
mines the maximum number of batches of change data that
are queued in memory. The default value is 64.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Maximum Transaction Count The maximum number of transactions being processed in a


in Scan scan of the remote source database.

Maximum Scan Size The maximum number of rows being fetched from the trig­
ger queue table in one scan and assigned to batch jobs for
further processing.

Maintenance User Filter Optional. Enter a source database user name. Source data­
(Case Sensitive)
base transactions (INSERT, UPDATE, and DELETE) con­
ducted by this user is filtered out (ignored) and not propa­
gated to the SAP HANA target. For example, if you log in to
the source database with this maintenance user and delete a
row from a source table that is subscribed for replication,
this row is not deleted from the SAP HANA target table.

 Note
Do not use the same name as the SAP HANA database
username.

 Note
The value of this parameter can be changed when the
remote source is suspended. However, the changed
value takes effect only on newly created remote sub­
scriptions afterward. The existing subscriptions are still
using the old value.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 449
Category Option Description

Manage System Objects Life- ● Create and Clear Normally: Normal behavior in system
Cycle objects life-cycle (Default). Support for dropping and
creating system objects.
● Clear Only: Support for dropping system objects, if they
exist. This setting is normally used in unsubscribing ta­
bles and cleaning up the environment.
● Create and Reuse: Support for creating system objects,
if they do not exist. For the existing objects, the SAP
HANA adapter reuses them.
● Reuse Only: No support for dropping or creating system
objects. For the existing objects, the SAP HANA adapter
reuses them. This setting is normally used in a shadow
remote source that wants to retrieve the subscription in
a remote source and replicate continuously.

Last Committed Sequence Id Last Committed Sequence Id is required only when Manage

System Objects Life-Cycle is set to Reuse Only.

If you set this parameter to 0, the HANA adapter scans new


cached data without rescanning.

You can get its value by executing the following SQL state­
ment in your target system:

SELECT
MAX(LAST_PROCESSED_COMMIT_SEQUENCE_ID)
FROM M_REMOTE_SUBSCRIPTIONS
WHERE SUBSCRIPTION_NAME IN (
SELECT
SUBSCRIPTION_NAME FROM
"PUBLIC"."REMOTE_SUBSCRIPTIONS"
WHERE
REMOTE_SOURCE_NAME = 'normal_rs'
)

Triggers Record PK Only Set to True to have the triggers record only primary keys of
delta data during CDC processing. This action may improve
the DML performance in the source database.

The default value is False and the SAP HANA adapter does
not support UPDATE primary key value in this mode. If you
want to enable this functionality, please add a system prop­
erty in dpagentconfig.ini first:

hanaadapter.recordPKOnly.capture_before_
and_after_images=true

There are side effects to using this parameter. For example, a


drop in replication performance is expected. This side effect
is a compromise to achieve better trigger/DML performance
on the source DB.

Installation and Configuration Guide


450 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Enable Upsert Trigger This option is only valid when Triggers Record PK Only is set
to True.

● True: A trigger captures change data from the remote


table into shadow table through an UPSERT operation.
● False: A trigger captures change data from the remote
table into shadow table through an INSERT operation.

The default value is False.

Capture Before and After Im­ This option is only valid when Triggers Record PK Only is set
ages
to True.

● True: A trigger captures both before and after images of


UPDATE operations on the remote table.
● False: A trigger captures only the after image of UPDATE
operations on the remote table.

The default value is False.

Shadow Table Type Configures the type of shadow table.

This option is only valid when Triggers Record PK Only is set


to True.

The default value is COLUMN.

Trigger Queue Table Type Configures the type of trigger queue table.

This option is only valid when Triggers Record PK Only is set


to True.

The default value is COLUMN.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 451
Category Option Description

Source Data Pattern Analysis When set to True, files are created to record the scan history.

These files are placed in a folder created in the framework


log directory: <DPAgent_root>/
log<remote_source_prefix>_<timestamp>/
<sequence>.csv

The generated CSV file contains the following columns:


SCAN_NUMBER; START_PROCESS_TIME;
END_PROCESS_TIME; TRANSACTION_ID;
COMMIT_TIME; TABLE_NAME; INSERT_COUNT;
BEFORE_IMAGE_COUNT; AFTER_IMAGE_COUNT;
DELETE_COUNT

You can control the number and size of these files by tuning
the following Agent Adapter Framework Preferences logging
parameters: Log max backup and Log file max file size.

The default value is True.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Transmit Data in Compact Specifies whether to transmit data in compact mode. If you
Mode
set Transmit Data in Compact Mode to True, the SAP HANA
adapter packs and sends out the data of one table together
with other tables, which could speed up applying data in
DPServer. However, doing so breaks referential integrity
among tables.

The default value is False.

Enable Transaction Merge ● True: Transactions on same remote table are grouped
together into one transaction and replicated to the tar­
get.
● False: Transactions are replicated as-is.

The default value is False.

Installation and Configuration Guide


452 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Connection Security Enable SSL Encryption Specifies whether to enable SSL encryption on connections
to a remote SAP HANA database. The default value is False.

To use SSL encryption with a remote SAP HANA database,


the Data Provisioning Agent must already be correctly con­
figured for SSL support:

● Configure SSL for SAP HANA On-Premise [Command


Line Batch] [page 509]

 Note
The value of this parameter can be changed when the
remote source is suspended.

Validate Server Certificate Specifies whether to validate the certificate of a remote SAP
HANA server.

This configuration is only meaningful if Enable SSL


Encryption is set to True. The default value is False.

 Note
The value of this parameter can be changed when the
remote source is suspended.

Host Name in Server Certifi- Controls the verification of the host name field of the server
cate certificate:

● If not set, the host name used for the connection is used
for verification. Note that SSL is name-based; connect­
ing to an IP address, or to “localhost” is unlikely to work.
● If set to a string,
○ If the string is “*”, any name matches.
○ If the string starts with “CN=”, it is treated as a
common name, and the textual representation of
the common name entry in the certificate must be
exactly the same.
○ Enable SSLOtherwise, the host name in the server
certificate must match this string (case insensi­
tive).

 Note
The value of this parameter can be changed when the
remote source is suspended.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 453
Category Option Description

Use Agent Stored Credential Set to True to use credentials that are stored in the Data Pro­
visioning Agent secure storage.

The default value is False.

 Note
When you use credentials stored in the agent's secure
storage, you must still specify the user name in
Credentials User . Additionally, the Credential
Mode must not be None or empty.

Credentials Credentials Mode Remote sources support two types of credential modes to
access a remote source: technical user and secondary cre­
dentials.

● Technical User: A valid user and password in the remote


database. This valid user is used by anyone using the re­
mote source.
● Secondary User: A unique access credential on the re­
mote source assigned to a specific user.

User Database user name (case sensitive)

 Note
The value of this parameter can be changed when the
remote source is suspended.

Password The appropriate corresponding password

 Note
The value of this parameter can be changed when the
remote source is suspended.

Basic

The following sample codes illustrate how to create a remote source using the SQL console.

Example

 Sample Code

CREATE REMOTE SOURCE "MyHanaSource" ADAPTER "HanaAdapter" AT LOCATION AGENT


"MyAgent"

Installation and Configuration Guide


454 PUBLIC Configure Data Provisioning Adapters
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="host" displayName="Host">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="port" displayName="Port Number">30115</PropertyEntry>
<PropertyEntry name="schema" displayName="Schema">myschema</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc_properties" displayName="CDC Properties">
<PropertyEntry name="prefix" displayName="System Object Prefix">HADP_</
PropertyEntry>
<PropertyEntry name="conn_pool_size" displayName="Connection Pool Size">8</
PropertyEntry>
<PropertyEntry name="min_scan_interval" displayName="Minimum Scan Interval in
Seconds">0</PropertyEntry>
<PropertyEntry name="max_scan_interval" displayName="Maximum Scan Interval in
Seconds">10</PropertyEntry>
<PropertyEntry name="max_batch_size" displayName="Maximum Batch Size">128</
PropertyEntry>
<PropertyEntry name="batch_queue_size" displayName="Batch Queue Size">64</
PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

DDL scan enabled

Example

 Sample Code

CREATE REMOTE SOURCE "MyHanaSource" ADAPTER "HanaAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="Database">
<PropertyEntry name="host" displayName="Host">myhost.sap.corp</PropertyEntry>
<PropertyEntry name="port" displayName="Port Number">30115</PropertyEntry>
<PropertyEntry name="schema" displayName="Schema">myschema</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc_properties" displayName="CDC Properties">
<PropertyEntry name="prefix" displayName="System Object Prefix">HADP_</
PropertyEntry>
<PropertyEntry name="ddl_scan_interval" displayName="DDL Scan Interval in
Minutes">1</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 455
Related Information

SAP HANA DDL Propagation [page 456]


Using a Schema Alias [page 277]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Use a Shadow Remote Source [page 457]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Creating a Whitelist to Limit Access to a Source Database [page 458]
Store Source Database Credentials in Data Provisioning Agent [Batch] [page 82]
Store Source Database Credentials in Data Provisioning Agent [Command Line] [page 68]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]
JDBC Connection Properties (SAP HANA Client Interface Programming Reference)
Agent Adapter Framework Preferences [page 104]

6.23.4 SAP HANA DDL Propagation

Information about DDL propagation when using the SAP HANA adapter.

DDL Scan Interval

Enabling DDL propagation can impact the performance of the source SAP HANA database. Setting an
appropriate value for the remote source option DDL Scan Interval in Minutes matters.

From the time the DDL changes occur on the source database to the time the DDL changes are propagated to
the target SAP HANA database, no DML changes on the tables are allowed. At configured intervals (DDL Scan
Interval in Minutes. By default, 10 minutes), the HANA adapter queries the metadata of all subscribed tables
from the source HANA database, and it determines if changes to the DDL have occurred. If changes are
detected, it propagates the DDL changes to the target database through the Data Provisioning Server.

Because the HANA adapter detects DDL changes by querying source HANA system tables, the source
database might be burdened if you configure a small value for the DDL Scan Interval in Minutes option.
However, configuring a large value would increase the latency of DDL propagation. Therefore, you should
experiment to figure out what value works best for you. If changes to the DDL are rare, you might even want to
disable DDL propagation by setting the value of the DDL Scan Interval in Minutes option to zero. Setting to zero
prevents the HANA adapter from querying metadata from the source database periodically.

Limitation

Remember that during the time period between when DDL changes occur on the source database and when
they are replicated to the target HANA, there must be no DML changes on the subscribed source tables.

Installation and Configuration Guide


456 PUBLIC Configure Data Provisioning Adapters
Replicating DDL changes would trigger the SAP HANA adapter to update (drop and then re-create) triggers and
shadow tables on the changed source tables. Errors may result if any data is inserted, updated, or deleted on
the source tables during this time period.

Related Information

SAP HANA Remote Source Configuration [page 444]

6.23.5 Use a Shadow Remote Source

Use a shadow remote source to reduce maintenance while performing real-time replication.

Context

During real-time replication, if there are exceptions that prevent replicating under a current remote source, and
these exceptions cannot be ignored, you can only drop and re-create the replication tasks. This limitation can
be very cumbersome in production environments. In this scenario, you can create a shadow remote source to
mitigate this problem.

The SAP HANA adapter is based on triggers, and it creates system objects when setting up the environment,
such as triggers, shadow tables, and trigger_queue tables. Every remote source has a trigger_queue table, and
every table has a relevant shadow table. A shadow remote source continues to replicate, so all the
subscriptions under it reuse those system objects.

Procedure

1. Suspend the normal remote source (referred to as “normal_rs” in this example).


2. Create a shadow remote source (referred to as “shadow_rs” in this example).

For the Manage System Objects Life-Cycle parameter, choose Reuse Only, and for the Last Committed
Sequence Id parameter, type in the ID. The Schema and System Object Prefix parameters must be the
same as the normal_rs remote source.
3. Create virtual tables at shadow_rs and create subscriptions (for example, subs1_shadow, subs2_shadow,
subs3_shadow...)
4. QUEUE and DISTRIBUTE your remote subscriptions.

When retrieving existing subscriptions, the HANA adapter checks to see if the subscribed tables are legal.
If a user subscribes the wrong table, the following exception occurs: “Add the subscription for table
[<table_name>] is prohibited when Manage System Objects Life-Cycle is Reuse Only! Please check
dpagent framework.trc for the recovery steps”.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 457
5. After shadow_rs is working, if you want to subscribe other tables,
a. Suspend shadow_rs.
b. Change Manage System Objects Life-Cycle to Create and Reuse.
c. Resume shadow_rs.
d. Create and start subscriptions.
6. If you want to reset/drop subscriptions under shadow_rs,
a. Suspend shadow_rs.
b. Change Manage System Objects Life-Cycle to Clear Only.
c. Resume shadow_rs.
d. Reset/drop subscriptions.
7. When cleaning up the environment, do not forget to resume normal_rs, through reset/drop subscriptions.

Related Information

SAP HANA Remote Source Configuration [page 444]

6.23.6 Creating a Whitelist to Limit Access to a Source


Database

There are times when you may want to limit access to all of the tables in a source database. For data
provisioning log reader adapters, as well as SAP HANA and SAP ECC adapters, an efficient way to limit access
is to create a whitelist.

Restricting access to only those tables that are to be replicated is done by creating a whitelist of source
database objects in a separate table.

 Note

The whitelist impacts only the virtual table created and the replications created after the whitelist was
created.

You can use SQL to create the whitelist table.

 Note

● The whitelist table, which can have any name, must have two columns named
REMOTE_SOURCE_NAME and WHITELIST.
● The whitelist items are separated by a comma.
● You can use an asterisk (*) to represent any character or empty string. However, the asterisk must be
placed at the end of a whitelist item. Otherwise, it is treated as a normal character.
● You can add multiple rows of whitelisted tables for a single remote source.

Installation and Configuration Guide


458 PUBLIC Configure Data Provisioning Adapters
Microsoft SQL Server Example

create table whitelist(REMOTE_SOURCE_NAME varchar(128), WHITELIST varchar(4000));

To add a whitelist for the remote source called “localmssqldb”, insert a row into the whitelist table:

insert into whitelist values('localmssqldb', 'object.A, object.B*');


insert into whitelist values('localmssqldb', 'object.C, object.D*');

object.A, object.B*, and so on, means that the table (or procedure) object.A and the table (or procedure)
starting with object.B are filtered for the remote source “localmssqldb”.

SAP HANA Example

create schema SAP_RESTRICTIONS;


create table WHITE_LIST(REMOTE_SOURCE_NAME varchar(128) primary key, WHITELIST
varchar(4000));

To add a whitelist for the remote source called “localhadp”, insert a row into the whitelist table:

insert into WHITE_LIST values('localhadp', 'APP_USER.MERCHANT,APP_PRODUCT.B*');

APP_USER.MERCHANT,APP_PRODUCT.B* means that the table (or procedure) APP_USER.MERCHANT and


the table (or procedure) starting with APP_PRODUCT.B are filtered for remote source “localhadp”.

6.23.7 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 459
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.24 SDI DB2 Mainframe

SDI DB2 Mainframe adapter is designed to replicate transactional operations from IBM DB2 UDB on z/OS to
SAP HANA.

The adapter extracts data from IBM DB2 UDB on z/OS databases as initial load and real-time change data
capture.

 Note

The SDI DB2 Mainframe adapter does not come pre-installed with the Data Provisioning Agent; you must
install it separately. Before installing the SDI DB2 Mainframe adapter, you must install the Data Provisioning
Agent.

This adapter is supported on Linux only.

Installation and Configuration Guide


460 PUBLIC Configure Data Provisioning Adapters
Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source

 Note

INSERT, UPDATE, and DELETE on a virtual table are not supported.

● Initial load
● Real-time change data capture

 Note

DDLs are not supported. Also, transactional operations include only INSERT, UPDATE, and DELETE

Encoding schemes supported on the source system: ASCII, EBCDIC, and Unicode

● Replication Monitoring and Statistics


● Search for Tables

In addition, this adapter supports the following capabilities:

● SELECT (WHERE, JOIN, GROUP BY, DISTINCT, TOP or LIMIT, ORDER BY)

Related Information

SDI DB2 Mainframe Adapter Architecture [page 462]


Mandatory Changes on Mainframe Systems [page 463]
Install the SDI DB2 Mainframe Adapter [page 464]
SDI DB2 Mainframe Adapter Preferences [page 465]
Install Replication Agent for SDI DB2 Mainframe Adapter [page 467]
Replication Agent for SDI DB2 Mainframe Adapter Configuration [page 470]
Change the OCS Server Port Number Using Command-Line Utility [page 472]
Preparing JDBC JAR Files [page 473]
IBM DB2 Mainframe Remote Source Configuration [page 473]
SAP HANA Smart Data Integration and Smart Data Quality Product Availability Matrix
Replication Agent Overview

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 461
6.24.1 SDI DB2 Mainframe Adapter Architecture

As you work with the SDI DB2 Mainframe adapter, it is helpful to know how the adapter interacts with the
various SAP HANA and IBM DB2 components.

The following leads you through a workflow of events that take place after the first subscription is enabled. The
Data Provisioning Agent routes this request to SDI DB2 Mainframe adapter.

 Note

This workflow applies to both Auto and Manual modes, except for 4-11, which apply to only Auto mode.

1. Start OCS listener.


2. The OCS server listens on a predefined port. This port number is configurable. The default listener port
number is 17000.
3. Replication Agent Manager downloads the Replication Agent Configuration File over JDBC connection via
DB2 stored procedure.
4. Replication Agent Manager customizes the Replication Agent Configuration File based on remote source
definition. The OCS server listener port number is also written into the Replication Agent Configuration
File.
5. Replication Agent Manager uploads the modified Replication Agent Configuration File through JDBC
connection.
6. Replication Agent Manager downloads the STARTRA JCL template through JDBC connection.
7. Replication Agent Manager customizes the STARTRA JCL script based on remote source definition.
8. Replication Agent Manager submits the STARTRA JCL through the JDBC connection.
9. DB2 submits the STARTRA JCL to JOB Manager (JES2)
10. After receiving the Job, JOB Manager (JES2) starts the Replication Agent.
11. Once Replication Agent is started, it connects to OCS server automatically based on the server and port
information specified in the Replication Agent Configuration File.
12. DML's on the subscribed table will be identified by the Replication Agent via the DB2 logs.
13. Replication Agent sends the changes to OCS server with LTL protocol.
14. LTL Parser and LTL translator parse the LTL data and translate them into interpretable data.

Installation and Configuration Guide


462 PUBLIC Configure Data Provisioning Adapters
15. The translated data is put into the queue.
16. Rowset assembler thread reads the data from the queue and assembles them into SAP HANA format
rowset.
17. Rowset is put into a queue.
18. Rowset delivery thread decides when to send the rowsets in the queue based on different delivery strategy.
19. Rowsets are sent to DPServer by the Rowset delivery thread, and then DPserver applies them to the SAP
HANA tables.

Related Information

Architecture [page 12]

6.24.2 Mandatory Changes on Mainframe Systems

Ensure that you have made the necessary changes to your mainframe system.

● Ensure that Replication Agent link libraries are APF authorized.


● When replication agent is started in auto mode, SAP HANA needs exclusive access for Replication Agent
installation dataset HLQ.LLQ.VER.JCL. Keeping it open in view/edit mode during Replication Agent startup
results in errors.
● The replication TSO user should have the following permissions:
○ TRACE authority to issue the START TRACE command.
○ DISPLAY authority to issue a DISPLAY TRACE to determine if the MONITOR TRACE is already active.
○ MONITOR2 authority to issue the READS request to get the log data that includes the changes to
capture.
● For auto mode, the following stored procedures must be installed on DB2:
○ ADMIN_DS_BROWSE
○ ADMIN_DS_SEARCH

 Note

Be sure to grant permissions for these stored permissions to the replication TSO user.

● For manual mode, the following stored procedures must be installed on DB2:

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 463
6.24.3 Install the SDI DB2 Mainframe Adapter

You can use either the command-line utility or the GUI mode to install the adapter.

Context

Install the SDI DB2 Mainframe adapter separately; it is not included in the Data Provisioning Agent.

Procedure

1. Download the SDI DB2 MAINFRAME ADAPTER 2.x.x component TGZ file.

Find this file in the software download area where you commonly find the download for the Data
Provisioning Agent and other components.
2. Extract the TGZ file.
3. To use command line, execute the following command. To use the GUI installer, skip to the next step.

cd HANA_SDI_DB2MainframeAdapter_20_LIN_X86_64
./hdbinst --silent --batch --path=<dpagent installation path>

4. Execute the following command to begin the GUI-based installer:

cd HANA_SDI_DB2MainframeAdapter_20_LIN_X86_64
./hdbsetup

The installation GUI appears.


5. Provide the Data Provisioning Agent installation path in the Install new SAP HANA SDI DB2 Mainframe
Adapter box, and then click Next.
6. Confirm the installation path, and click Next.
7. Click Install.
8. When you receive a message that the installation is successful, click Finish.
9. Verify that the following files are installed in the desired location:

○ <DPAgent_root>/plugins/com.sap.hana.dp.db2mainframelogreaderadapter-n.n.n.jar
○ <DPAgent_root>t/lib/libDB2MainframeLogReaderAdapter.so
10. Restart the Data Provisioning Agent.

Installation and Configuration Guide


464 PUBLIC Configure Data Provisioning Adapters
Next Steps

After Data Provisioning Agent is started, you should be able to see the following messages in
<DPAgent_root>/log/framework.trc:

2019-07-24 00:20:32,780 [INFO ] DPFramework | AdapterTracker.addingService [] -


Adapter Type: DB2MainframeLogReaderAdapter is added to framework
2019-07-24 00:20:32,790 [INFO ] DPFramework | AdapterManager.setSDKVersion [] -
DB2MainframeLogReaderAdapter Version: 2.4.0.1 with SDKVersion: 9 (2.4.0)
registered.
2019-07-24 00:20:32,792 [INFO ] Activator | Activator.start [] - Adapter
DB2MainframeLogReaderAdapter started.

Related Information

Software Download [page 39]

6.24.4 SDI DB2 Mainframe Adapter Preferences

Configuration parameters for the SDI DB2 Mainframe adapter in the Data Provisioning Agent.

Parameter Description Default Value

Adapter server name The name of the SDI DB2 Mainframe DB2MFAdapterOCSServer
adapter server that receives data
changes from the DB2 Mainframe data
server.

Adapter server port The port number for the SDI DB2 Main­ 17000
frame adapter's OCS Listener.

Time to wait for Replication Agent to Max time SDI DB2 Mainframe adapter 60
connect (Seconds)
would wait for Replication Agent to start
and send the first transaction to the
adapter.

 Note
Ensure the value of this parameter
is set to double or more than the
retry parameter value in the main­
frame configuration file

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 465
Parameter Description Default Value

Time to wait for Replication Agent to re­ The maximum seconds that the SDI 30
connect (Seconds) DB2 Mainframe adapter waits for Repli­
cation Agent to reestablish the connec­
tion from Replication Agent to the SDI
DB2 Mainframe adapter.

Valid values include:

● Zero (0) - If the connection to Rep­


lication Agent breaks, SDI DB2
Mainframe adapter waits indefi-
nitely for the connection to be re­
established.
● Negative value - SDI DB2 Main­
frame adapter reports an error if
Replication Agent gets discon­
nected. This stops the OCSListner,
which then stops replication.
● Positive value (time in seconds) - If
there is a broken connection, SDI
DB2 Mainframe adapter waits for
the specified time for the connec­
tion to Replication Agent to be re­
established. However, if the con­
nection is not reestablished in the
specified time, OCSListener stops,
which then stops replication.

 Note
In order to avoid data loss, rema­
terialization is required when start­
ing replication again.

Log level (ERROR|WARN|INFO|DEBUG) The log level for the SDI DB2 Mainframe INFO
adapter dynamic library.

Number of wrapped log files The maximum number of dynamic li­ 10


brary log files.

Maximum log file size (KB) Limit the size of the dynamic library log 100000
file.

Convert GRAPHIC/VARGRAPHIC data Indicate whether the GRAPHIC/ TRUE


in Java VARGRAPHIC data is to be converted in
Java code.

Installation and Configuration Guide


466 PUBLIC Configure Data Provisioning Adapters
Related Information

Change the OCS Server Port Number Using Command-Line Utility [page 472]
Start the Configuration Tool [Command Line] [page 51]

6.24.5 Install Replication Agent for SDI DB2 Mainframe


Adapter

Install the Replication Agent to work with the SDI DB2 Mainframe adapter.

Context

The GUI installer walks you through the installation process. Provide information about your DB2 system, OCS
Server, logon credentials, and so on.

Procedure

1. Download the SDI DB2 MF ADAPT REP AGENT 2.0 component (REPAGENTSDI*.EXE), and execute the file.

The graphical interface installer launches.


2. Review the information on the first screen, and click Next.
3. Provide the following information, and click Next

Parameter Notes

JCL Line 1 Add the job card details.

For example, if the mainframe ID is “MDAWAR”, change the JCL Line 1 text box to
MDAWARAB JOB class="A",NOTIFY=&SYSUID

JCL Line 2

JCL Line 3

High Level Qualifier You can find all of your Replication Agent JCLs under the PDS whose qualifier starts
with HLQ.* (For example, “MDAWAR.*”)

This value should not exceed eight characters.

Volume

Unit

Work Unit

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 467
Parameter Notes

TCP Address Space Name

4. Provide the following information, and click Next

Parameter Notes

DB2 DSN Name DB2 subsystem ID (SSID)

DB2 Version

DB2 Plan Name

DB2 System Loadlib

RepAgent System table creator Qualifier of LTMMARKER and LTMOBJECTS system tables
name

Data Sharing

5. Provide the following information, and click Next

Values for these parameters must be specified only when Replication Agent is started in manual mode;
otherwise the parameters can be left unaltered. In auto mode, these parameters are populated
automatically during run-time.

Parameter Notes

OCSServer Name SDI DB2 Mainframe adapter server name as updated in NOTIFY=&SYSUID
<DPAgent_root>/configuration/
com.sap.hana.dp.adapterframework/
DB2MainframeLogReaderAdapter/
DB2MainframeLogReaderAdapter.ini file

OCSServer IP Address SDI DB2 Mainframe adapter server's address

OCSServer Port SDI DB2 mainframe adapter's port as updated in <DPAgent_root>/


configuration/com.sap.hana.dp.adapterframework/
DB2MainframeLogReaderAdapter/
DB2MainframeLogReaderAdapter.in file

Source Data Server DB2 data server name

Source Database DB2 database name

6. Provide the following information, and click Next

Parameter Notes

User ID Your mainframe user ID to be used for FTPing product libraries to the main­
frame.

Password Your mainframe password

NOTIFY=Mainframe Host Name Mainframe server that you are using (either Hostname or IP address)

FTP Port Number 21

VOL/UNIT Assignment

Installation and Configuration Guide


468 PUBLIC Configure Data Provisioning Adapters
Parameter Notes

Log FTP Session? Provide a file name for a file that is created and used for capturing log informa­
tion during FTP. This file will help you analyze issues that might occur during da­
taset upload.

The file name specified here has to be a location on the local machine where the
installer is being executed.

7. Click Install.
8. Click Installation Complete.
9. Log on to the mainframe, and go to PDS with the High Level Qualifier used in Step 3.
10. From the above list, open PDS with low-level qualifier as .JCL.
11. Run the following JCLs in HLQ.*.JCL in order:

○ RECEIVE: This job runs the IKJEFT01 program to use TSO Receive Command to build and populate the
product libraries
○ ALLOC: This job creates TRUNC point Dataset and Generations Data Group (GDG)
12. Execute the following SQL statements:

○ GRANT: To give authorization for BIND and EXECUTE on the plan used
○ SQLINT: To create LTMOBJECTS and LTMMARKER tables
13. Execute LTMBIND job from HLQ.*.JCL PDS

This job binds the DB2 LOG Extract Plan.

 Note

If you get an authorization error, issue the GRANT command for the BIND privilege.

Results

Before starting Replication Agent, be sure that the following pre-requisites are established:

● Link libraries must be APF authorized. Contact your mainframe team for APF authorization.
● Tables to be replicated through Replication Agent must be created with the “DATA CAPTURE CHANGES”
option specified.
● The LTMOBJECT and LTMMARKER tables owner name must match the creator parameter value assigned
in the mainframe configuration file.

Related Information

Replication Agent Overview


Software Download [page 39]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 469
6.24.6 Replication Agent for SDI DB2 Mainframe Adapter
Configuration

Set up the configuration file for Replication Agent for SDI DB2 Mainframe adapter.

Update some of the parameters in the configuration file to work with the SDI DB2 Mainframe adapter.

 Note

In manual mode, the configuration file must be updated manually. When using auto mode, most adapter-
related configuration parameters are updated automatically.

Section Parameters

DB2MFAdapterOCSServer Pa­ The following parameters are auto-populated in auto mode; there is no need to update
rameters them manually. However, in manual mode, these parameters should match the remote
source configuration and OCSServer configuration.

● DP=<host name of DPAgent to connect to>


● DP_source_ds=<DB2 server name>
● DP_source-db=<Database containing system tables>
● *DPHost=<host name of DPAgent to connect to>
● DPIPAddress=<IP address of DP Agent>
● DPPort=<OCS port number>

Update the following parameters manually:

● DP_ccid=<HANA CCID>
● DPCsetname=<HANA Code Setname>

LTM Parameters ● Minimal_cols=N


● Timestamp_in_char=Y
● Date_in_char=Y
● Time_in_char=Y

Log Extract Parameters Creator=<Userid>

Trace Configs The trace configurations are helpful during troubleshooting; however, they are optional
during a normal execution.

 Note
Remember to turn off trace functions after you obtain the necessary information. If
you allow trace functions to continue, the trace output files can fill and consume disk
space, causing abends or impaired LTM for MVS performance.

Example: Sample LTMCFG file

*------------------------RS configs------------------------------------
* Parameter names are not case sensitive.
*----------------------------------------------------------------------
*
*----------------------------------------------------------------------

Installation and Configuration Guide


470 PUBLIC Configure Data Provisioning Adapters
*------ DB2MFAdapterOCSServer Parameters ( Auto Populated )------------
*-----------(DO NOT UPDATE MANUALLY)-----------------------------------
*----------------------------------------------------------------------
DP=DB2MFAdapterOCSServer
DP_source_ds=DSNDB2D
DP_source_db=LTMDB1
DP_ccsid=819  update manually
DPCsetname=iso_1  update manually
*DPHost=
DPIPAddress=10.56.179.10
DPPort=45500
*----------------------------------------------------------------------
*
*-- LTM Parameters ----------------------------------------------------
TCPName=TCPIP name of the TCPIP address space
Communications_Protocol=IBMTCP The only supported protocol
Packet_size=32k Size of OC buffer to be sent
Maximum_connect_retries=10
API_QID_request_interval=1000 How often the API requests a QID
batch_ltl_cmds=on on or off, Y or N
Minimal_cols=N Y or N
Stop_on_error=N Y or N
Suppress_col_names=N Y or N
Support_DB2_comp_rec=Y Y or N
Minimum_year=0000 1949, 1998, etc. must be 4 digits
Long_varchar=Y Y or N < 256 or up to cc 32K
Low_activity_latency=10 To send last Buffer when not full
Timestamp_in_char=Y Y or N
Date_in_char=Y Y or N
Time_in_char=Y Y or N
Ltl_table_col_case=asis asis, upper, lower
DateTime_conv_err=Default
Date_conv_default=1900-01-01 1998-12-25
Time_conv_default=00:00:00 11:22:33
Graphictype=binary
API_com_test=N Y or N
LTL_test_only=N Y or N
*User_exit=
*----------------------------------------------------------------------
*
*-- Log Extract Parameters --------------------------------------------
Log_extractor=LTMEXTX Use LTMEXTX- DB2v11 LTMEXTC- DB2v12
Log_identifier=DB2D DB2 SSID
DataSharingOption=None
*DataSharingMember= Used for DataSharingOption=Single
*BSDS=
DetectDataCapture=Y Yes for DC changes/none
LogTrace=no yes or no
GenID=1 The QID Generation ID
CIMax=20 Maximum CI's for the Log Reader
LogExtractError=Msg Term or Msg
Buffers=25 Max Buffers for the Log Reader
PollInterval=0.0.20.0 How often to check for new data
LTMPlan=RAPLAN76 Log extract plan
SetTruncPoint=10 Trunc point request interval
Creator=TABOWN  update manually it should be Table owner name.
retry=10
tablehandler=LTMINFOX Use LTMINFOX for DB2 Version 11+
datahandler=LTMIFIX Use LTMIFIX for DB2 Version 11
ExtendedRba=Y Use Y for DB2 Version 11
Codepage=500,force DB2 base Code page
*------------------------Trace configs---------------------------------
*trace=Calls
*trace=General
*trace=QIDs
*trace=TruncPoint
*trace=LTLebcdic
*trace=LTLascii

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 471
*trace=Connections
*----------------------------------------------------------------------

6.24.7 Change the OCS Server Port Number Using


Command-Line Utility

The OCS port number (and other adapter preference parameters) can be changed by using Data Provisioning
Agent Configuration Tools (both GUI or Command-Line Utility).

Context

The following instructions are for changing the OCS port number by using the Command-Line Utility:

Procedure

1. Start DPAgent Configuration Tools Command-Line Utility to configure adapters by entering:

dml_test@xiyl50833394a:/usr/sap/dataprovagent> bin/agentcli.sh –
configAdapters.

2. Enter option 2 to set adapter preferences.


3. Enter option 16 to set DB2MainframeLogReaderAdapter preferences.

A wizard appears where you can change values for the adapter preferences. Press Enter to skip optional
or default settings. If a setting cannot be skipped, it is required.
4. Modify the port number in the Enter Adapter Server Port[17000] parameter.

Results

The changes will take place after you restart the Data Provisioning agent.

 Note

In manual mode, make sure to update the Replication agent configuration file with the updated port
number.

Related Information

Start the Configuration Tool [Command Line] [page 51]

Installation and Configuration Guide


472 PUBLIC Configure Data Provisioning Adapters
SDI DB2 Mainframe Adapter Preferences [page 465]

6.24.8 Preparing JDBC JAR Files

Prepare the IBM DB2 JDBC JAR files to use one of the DB2 Mainframe adapters.

To use one of the DB2 Mainframe adapters, you are required to copy the following IBM DB2 JDBC JAR files to
the /lib folder of the Data Provisioning Agent installation directory (<DPAgent_root>\lib).

● db2jcc4.jar (Required)
You can download this file here: http://www-01.ibm.com/support/docview.wss?uid=swg21363866 .
Download the JDBC JAR file according to your DB2 database version.
● db2jcc_license_cisuz.jar (Required)
You can find information about this file here: http://www-01.ibm.com/support/docview.wss?
uid=swg21191319

You can find these JAR files in the following ways:

● These JAR files are available in the installation directory after you installed the IBM DB2 client. For
example, on a Windows system, the JAR files are located in C:\Program Files\IBM\SQLLIB\java.
● Download them from the IBM Support and Download Center.

 Note

If the source z/OS DB2 system contains a non-English CCSID table space, you are required to update the
JVM to an internationalized version. At a minimum, the charsets.jar file within the current JVM should
contain the required CharToByteCP<XXX>.class, where <XXX> corresponds to the source system’s
language locale.

6.24.9 IBM DB2 Mainframe Remote Source Configuration

Options for connecting to the remote mainframe data server. Also included is sample code for creating a
remote source using the SQL console.

Category Option Description

Database Host Mainframe host name or IP address on which the remote


DB2 data server is running

Port Number The DB2 data server port number.

Database Name The DB2 database name where the LTMOBJECTS and
LTMMARKER tables reside.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 473
Category Option Description

Database Source Name The DB2 instance name.

The name of the DB2 subsystem can be found by running


the following command on SPUFI:

.,,. . . . . . . . . . .
. . . . . . . . . . . .
. . . .,.
.,,
DB2 COMMANDS
SSID: P8L0 ,,.
.,,===>,

,,.
.,,

,,.
.,,Position cursor on the command
line you want to execute and press
ENTER ,,.
.,,

,,.
.,,Cmd 1,===>,-DIS
DDF
,,.
DSNL080I -P8L0 DSNLTDDF DISPLAY
DDF REPORT FOLLOWS:,
DSNL081I STATUS=STARTD,
DSNL082I LOCATION
LUNAME GENERICLU,
DSNL083I DDFP8L0
DESAPW00.DB2P8L0 -NONE,
DSNL084I TCPPORT=9023
SECPORT=0 RESPORT=9024 IPNAME=-
NONE,
DSNL085I IPADDR=::10.17.200.30,
DSNL086I SQL
DOMAIN=ihsapke.wdf.sap.corp,
DSNL105I CURRENT DDF OPTIONS ARE:,
DSNL106I PKGREL = COMMIT,
DSNL099I DSNLTDDF DISPLAY DDF
REPORT COMPLETE,
***,

Database Tablespace Name The DB2 database tablespace name.

Installation and Configuration Guide


474 PUBLIC Configure Data Provisioning Adapters
Category Option Description

z/OS DB2 Additional Info Bind Packages When this option is set to Yes, the DB2 mainframe
adapter automatically checks and binds all of the required
missing JAR files.

We recommend that you set this option to Yes the first


time you attempt to establish a connection, then set this
option to No for subsequent attempts.

 Note
If any necessary packages are missing, an error oc­
curs.

Setting this option for subsequent attempts help improve


performance by eliminating the need for redundant
checks for the necessary JDBC packages.

Use Auto Mode If you set this parameter to True, the replication agent
stars automatically.

If you set the parameter to False, you must start the repli­
cation agent manually and create LTMMARKER and
LTMOBJECTS manually on the mainframe.

The default value is True.

LTM Configuration File Lo­ The Replication Agent's configuration file location
cation

LTM Configuration File The Replication Agent's configuration file name


Name

Schema Alias Replacements Alias Name The name of the schema in the original system.

Alias Replacements The name of the schema in the current system that repla­
ces the Schema Alias name.

Security Properties Use SSL Specifies whether you are using SSL.

The default value is False.

Credential Properties Credentials Mode Remote sources support two types of credential modes to
access a remote source: technical user and secondary
credentials.

● Technical User: A valid user and password in the re­


mote database. This valid user is used by anyone us­
ing the remote source.
● Secondary User: A unique access credential on the
remote source assigned to a specific user.

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 475
Category Option Description

User Name The TSO user that would be used to start the replication
agent job in mainframe.

 Note
This user name is only used as an owner of replica­
tion agent start job. The qualifier of system tables
(LTMOBJECTS and LTMMARKER) should match cre­
ator parameter in the configuration file. The creator
parameter in the configuration file does not need to
be the same as the user name parameter in the re­
mote source.

Password The mainframe TSO user password

Example

CREATE REMOTE SOURCE "MyDB2MainframeSource" ADAPTER


"DB2MainframeLogReaderAdapter" AT LOCATION AGENT "DB2MFAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configurations">
<PropertyGroup name="database" displayName="DATABASE">
<PropertyEntry name="pds_host_name" displayName="Host"> <Mainframe Host
Name></PropertyEntry>
<PropertyEntry name="pds_port_number" displayName="Port Number">9023</
PropertyEntry>
<PropertyEntry name="pds_database_name" displayName="Database
Name">LTMDB1</PropertyEntry>
<PropertyEntry name="pds_datasource_name" displayName="Database
SourceName">DDFP8L0</PropertyEntry>
<PropertyEntry name="pds_tablespace_name" displayName="Database
Tablespace Name">LTMTS1</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="zodb2sadditionalinfo" displayName="z/OS DB2 Additional
Info">
<PropertyEntry name="bind_packages" displayName="Bind Packages">Yes</
PropertyEntry>
<PropertyEntry name="auto_mode" displayName="Use auto mode">true</
PropertyEntry>
<PropertyEntry name="ltm_cfg_file_loc" displayName="LTM Configuration
File Location">SYREP.SP09.RA150.JCL</PropertyEntry>
<PropertyEntry name="ltm_cfg_file_name" displayName="LTM Configuration
File Name">LTMCFG</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="schema alias replacements" displayName="Schema Alias
Replacements">
<PropertyEntry name="schema_alias" displayName="Alias name">Schema name</
PropertyEntry>
<PropertyEntry name="schema_alias_replacement" displayName="Alias
replacement">Replacement schema name</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security" displayName="Security Properties">
<PropertyEntry name="pds_use_ssl" displayName="Use SSL">false</
PropertyEntry>
</PropertyGroup>
</PropertyGroup>
</ConnectionProperties>

Installation and Configuration Guide


476 PUBLIC Configure Data Provisioning Adapters
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user><TSO username></user>
<password><TSO password></password>
</CredentialEntry>'
;

Related Information

Using a Schema Alias [page 477]

6.24.9.1 Using a Schema Alias

Using a schema alias can help you manage multiple schema, remote sources, and tables more easily.

The Schema Alias and Schema Alias Replacement options, available in the remote source configuration
parameters for some Data Provisioning adapters, allow you to switch easily between schema, remote sources,
and tables. The Schema Alias is the name of the schema in the original system. The Schema Alias Replacement
is the name of the schema in the current system that replaces the Schema Alias name.

A common use case is to create a remote source pointing to a development database (for example, DB_dev),
and then create virtual tables under that remote source. Afterward, you may switch to the production database
(for example, DB_prod) without needing to create new virtual tables; the same tables exist in both DB_dev and
DB_prod, but under different schema and databases.

During the development phase, you may create a virtual table for a source table OWNER1.MYTABLE in DB_dev,
for example. Note that OWNER1.MYTABLE is the unique name of the source table, and it is a property of the
virtual table. With it, the adapter knows which table in the source database it is expected to access. However,
when you switch to the production database (DB_prod), there is no OWNER1.MYTABLE, only
OWNER2.MYTABLE. The unique name information of the virtual table cannot be changed once created.

You can resolve this problem using the Schema Alias options. In this case, we want to tell the adapter to replace
OWNER1 with OWNER2. For example, when we access OWNER1.MYTABLE, the adapter should access
OWNER2.MYTABLE. So here, OWNER1 is Schema Alias from the perspective of DB_prod, while OWNER2 is
Schema Alias Replacement.

To use this functionality, you must populate both of these options.

Related Information

DB2 Log Reader Remote Source Configuration [page 270]


Microsoft SQL Server Log Reader Remote Source Configuration [page 325]
Oracle Log Reader Remote Source Configuration [page 370]
SAP HANA Remote Source Configuration [page 444]
SDI DB2 Mainframe [page 460]

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 477
6.25 SOAP

The SOAP adapter provides access to SOAP Web Services via HANA SQL.

The SOAP adapter is a SOAP web services client that can talk to a web service using the HTTP protocol to
download the data. The SOAP adapter uses virtual functions instead of virtual tables to expose server-side
operations.

The SOAP adapter supports the following functionality:

● Virtual function as a source

Related Information

SOAP Adapter Remote Source Configuration [page 478]


Setting up the SOAP Adapter: SQL Example [page 480]
CREATE VIRTUAL FUNCTION

6.25.1 SOAP Adapter Remote Source Configuration

Configuration settings for creating a SOAP adapter remote source. Also included is sample code for creating a
remote source using the SQL console.

Category Option Description

Connection WSDL File The location of the WSDL file. Enter a URL or a path to the local WSDL file
where the Data Provisioning Agent is installed.

Use System Proxy If set to Yes, the adapter uses the proxy information saved in the
dpagentconfig.ini file (http.proxyHost, http.proxyPort) or that is
set up in the DP Agent Configuration Tool.

If http.proxyHost and http.proxyPort properties are not in the


dpagentconfig.ini file, you must add them.

Socket Timeout (milli­ The time to establish the connection with the remote host. The default
seconds) value is 6000 ms.

Connection Timeout The time waiting for data after the connection was established (maxi­
(milliseconds) mum time of inactivity between two data packets). The default value is
6000 ms.

Installation and Configuration Guide


478 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Treat WebServiceError If set to Yes, fail the web services call if there is a failure. The default value
(SOAP Fault) as failure
is No.

By default, the SOAP Adapter writes the fault to one of the output col­
umns if the call fails. In certain scenarios, you may want to fail the call it­
self. For example, the proxy was incorrectly configured.

 Sample Code

Select * from getWeatherByZip(….94403…..)

● If set to No, the select call is a success and the actual error is popu­
lated in the SOAP_FAULT column.
● If set to Yes, the select call fails itself and writes the error to a caller.

WS-Security Password ● None: Choose this option if you do not want to use WS-Security.
Type
● plainText: Choose this option if you intend to use WS-Security with a
plaintext password.
● Digest: Choose this option if you intend to use WS-Security with an
encrypted password.

Credentials Credentials Mode Remote sources support two types of credential modes to access a re­
mote source: technical user and secondary credentials.

● Technical User: A valid user and password in the remote database.


This valid user is used by anyone using the remote source.
● Secondary User: A unique access credential on the remote source
assigned to a specific user.

Basic Authentication User The user name, which is case sensitive.

Password The password corresponding to the user.

WS-Security WS-Security User­ The WS-Security user ID


name

WS-Security Password The WS-Security password

SQL Example

CREATE REMOTE SOURCE "soapSalesDemo4" ADAPTER "SOAPAdapter" AT LOCATION AGENT


"MyAgent"
CONFIGURATION '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="Configuration">
<PropertyEntry name="wsdl">https://xxxxxxxx.successfactors.com/sfapi/v1/
soap?wsdl</PropertyEntry>
<PropertyEntry name="axisFault">no</PropertyEntry>
<PropertyEntry name="useProxy">no</PropertyEntry>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialProperties name="Credential">
<CredentialEntry name="basicAuth">

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 479
<user>xxxxx</user>
<password>Password1</password>
</CredentialEntry>
<CredentialEntry name="WSSAuth">
<user>xxxxxx</user>
<password>Password2</password>
</CredentialEntry>
</CredentialProperties>';

6.25.2 Setting up the SOAP Adapter: SQL Example


SQL example for setting up the SOAP adapter to use a remote web service.

The following is an example of how to set up the SOAP adapter to use a remote web service (http://
www.webservicex.net/stockquote.asmx?WSDL). You can use the Web-based Development Workbench to
complete some of these tasks (for example, creating a virtual function).

 Sample Code

drop agent "agent_local" cascade;


CREATE AGENT "agent_local" PROTOCOL 'TCP' HOST
'pald00486396a.amer.global.corp.sap' PORT 5050;
drop adapter "SOAPAdapter" cascade;
CREATE ADAPTER "SOAPAdapter" at location agent "agent_local";
drop remote source "WebServiceRS" cascade;
CREATE REMOTE SOURCE "WebServiceRS" ADAPTER "SOAPAdapter" AT LOCATION AGENT
"agent_local" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8"?>
<ConnectionProperties name="connection">
<PropertyEntry name="wsdl">http://www.webservicex.net/stockquote.asmx?
WSDL</PropertyEntry>
<PropertyEntry name="useProxy">Yes</PropertyEntry>
<PropertyEntry name="axisFault">No</PropertyEntry>
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="webservice_credential"><user></user><password></
password></CredentialEntry>';
--Get the function definition from adapter
CALL "PUBLIC"."GET_REMOTE_SOURCE_FUNCTION_DEFINITION"
('WebServiceRS','{"serviceName":"StockQuote","portName":"StockQuoteSoap",
"operationName":"GetQuote","nodeType":"OPERATION"}',?,?,?);
--Using the json configuration we can now create a virtual function.
drop FUNCTION getStockQuote;
CREATE VIRTUAL FUNCTION getStockQuote(SOAP_REQUEST Nvarchar(5000))
RETURNS TABLE (SOAP_HEADERS Nvarchar(5000), SOAP_FAULT NVARCHAR(5000),
SOAP_BODY NCLOB)
CONFIGURATION 'use the json data returned from
GET_REMOTE_SOURCE_FUNCTION_DEFINITION' AT "WebServiceRS";
--Invoking the SOAP Request is as below.

select * from getStockQuote(


'<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:web="http://www.webserviceX.NET/">
<soapenv:Header/>
<soapenv:Body>
<web:GetQuote xmlns:web="http://www.webserviceX.NET/">
<!--Optional:-->
<web:symbol>NASDAQ</web:symbol>
</web:GetQuote>
</soapenv:Body>
</soapenv:Envelope> ');

Installation and Configuration Guide


480 PUBLIC Configure Data Provisioning Adapters
6.26 Teradata

The Teradata adapter can be used to connect to a Teradata remote source and create a virtual table to read
from and write to.

 Note

Before registering the adapter with the SAP HANA system, ensure you have downloaded and installed the
correct JDBC libraries. See the SAP HANA smart data integration Product Availability Matrix (PAM) for
details. Place the files in the <DPAgent_root>/lib folder.

Adapter Functionality

This adapter supports the following functionality:

● Virtual table as a source


● Real-time change data capture
● Search for tables
● Loading options for target tables
● DDL propagation
● Replication monitoring and statistics
● Access to multiple schemas

In addition, this adapter supports the following capabilities:

Table 52: Global Settings

Functionality Supported?

SELECT from a virtual table Yes

INSERT into a virtual table Yes

Execute UPDATE statements on a virtual table Yes

Execute DELETE statements on a virtual table Yes

Different capabilities per table No

Different capabilities per table column No

Real-time Yes

Table 53: Select Options

Functionality Supported?

Select individual columns Yes

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 481
Functionality Supported?

Add a WHERE clause Yes

JOIN multiple tables Yes

Aggregate data via a GROUP BY clause Yes

Support a DISTINCT clause in the select Yes

Support a TOP or LIMIT clause in the select Yes

ORDER BY Yes

GROUP BY Yes

Related Information

Authentication and User Privileges [page 482]


Teradata Adapter Preferences [page 483]
Teradata Remote Source Configuration [page 483]
Disable Adapter Write-back Functionality [page 490]
Permissions for Accessing Multiple Schemas [page 489]
Update JCE Policy Files for Stronger Encryption [page 518]
SAP HANA smart data integration and all its patches Product Availability Matrix (PAM) for SAP HANA SDI 2.0

6.26.1 Authentication and User Privileges

Authentication and user privileges requirements for connecting to a Teradata remote source.

Authentication

You can set up authentication by using TD2, LDAP, or Kerberos.

If you are using LDAP, provide a user name and password when setting up your remote source.

If you are using Kerberos, the adapter uses the default Kerberos settings of the computer on which it is
deployed. If the Kerberos configuration file (krb5.conf) is in a nonstandard location, the path must be
specified via the java.security.krb5.conf system property by adding it to dpagent.ini file. The Realm
and KDC connection parameters in the remote source are optional. Both must be specified in order to override
the computer's default krb5.conf settings. To use Kerberos, use the Kerberos principal name for the user
name with the corresponding password.

Installation and Configuration Guide


482 PUBLIC Configure Data Provisioning Adapters
Privileges

The following database user privileges are required for accessing databases, tables, and so on, so that the
adapter can read metadata. You need SELECT access on the following DBC tables:

● "DBC"."UDTInfo"
● "DBC"."DBase"
● "DBC"."AccessRights"
● "DBC"."TVM"
● "DBC"."TVFields"

The following privileges are required to support real-time replication (CDC):

● CREATE TABLE
● DROP TABLE
● CREATE TRIGGER
● DROP TRIGGER
● CREATE PROCEDURE
● DROP PROCEDURE

6.26.2 Teradata Adapter Preferences

Options for controlling the Teradata adapter.

Parameter Description

Thread Pool Size The size of the Teradata global thread pool. Teradata adapter remote sources share
the thread pool. The thread pool is used to execute jobs of querying shadow tables
to get change data.

6.26.3 Teradata Remote Source Configuration

Options for setting up the connection to the remote Teradata data server. Also included is sample code for
creating a remote source using the SQL console.

Configuration parameters

Category Option Description

Connection Host Host name or IP address on which the remote Teradata data
server is running

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 483
Category Option Description

Port Number The Teradata data server port number

Encoding Session encoding between the adapter and Teradata. Some re­
strictions apply to UTF-8. For example, character columns with
Graphic encoding are not supported.

Encrypt traffic Specifies whether the traffic between the adapter and the data­
base is encrypted.

If turned off, data exchanged between the adapter and the data­
base is unencrypted, and anyone with access to the network
may be able to the read the data. This setting does not affect
logon data, because this data is always sent encrypted by the
Teradata JDBC driver.

Logon mechanism Specifies the authentication (+authorization) method used, and


which username and password values to enter in the credentials
fields.

● TD2 (Teradata Method 2): Use the database username and


password
● LDAP: Directory authentication. Use credentials of users
defined and configured via LDAP (Database has to be con­
figured to use external LDAP authentication)
● Kerberos (KRB5): Use Kerberos principal and its username
(Database has to be configured to use Kerberos external
authentication)

Realm (Optional when using Kerberos) authenticate using a principal


from this realm (instead of the systems default realm). The
Realm option must be used together with KDC.

KDC (Optional when using Kerberos) address of KDC (Key Distribu­


tion Center) to be used with the specified Realm (has to be used
together with Realm)

JDBC FastExport Speeds up retrieving large amounts of data from Teradata (disa­
bled when using Kerberos authentication)

Installation and Configuration Guide


484 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Transaction Mode Specifies the transaction mode for the connection.

● ANSI: Uses American National Standards Institute (ANSI)


transaction semantics. This mode is recommended. ANSI
is the default value.
● TERA: Uses legacy Teradata transaction semantics. This
mode is only recommended for legacy applications that re­
quire Teradata transaction semantics.
● DEFAULT: Uses the default transaction mode configured for
the Teradata Database, which may be either ANSI or TERA
mode.

Additional Connection Pa­ Extra Teradata JDBC connection options. The parameters must
rameters be specified in the following format: key=value,key=value,...

http://developer.teradata.com/doc/connectivity/jdbc/refer­
ence/current/frameset.html

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

CDC Properties Database Name of the database.

System Object Prefix The prefix of the names of the Teradata adapter system objects
created in the source Teradata database by the adapter. We rec­
ommend keeping the default value of TADP_.

Shadow Table Prefix The prefix of the names of the Teradata adapter shadow tables
created in the source Teradata database by the adapter.

The default value is SHADOW_

Stored Procedure Suffix The prefix of the names of the Teradata adapter stored proce­
dures created in the source Teradata database by the adapter.

The default value is PROC

Trigger Suffix The suffix of the names of the Teradata adapter triggers created
in the source Teradata database by the adapter.

The default value is TRIG

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 485
Category Option Description

Connection Pool Size Maximum number of connections allowed in the connection


pool on a secondary node. The default value is 8.

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

Minimum Scan Interval in


Seconds  Note

Maximum Scan Interval in The minimum interval in seconds that the adapter scans theThe
Seconds maximum interval in seconds that the adapter scans the Trigger
Queue table to get change data. The default value is 10 (sec­
onds). If the adapter scans the queue and finds that the queue
is empty, it gradually increases the scan interval from the mini­
mum scan interval to the maximum scan interval.The value of
this parameter can be changed when the remote source is sus­
pended. The minimum interval in seconds that the adapter
scans the Trigger Queue table to get change data. The default
minimum scan interval is 3 seconds to avoid putting excessive
load on the database with frequent repeat scans.

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

DDL Scan Interval in Mi­ The interval for detecting DDL changes in the source.
nutes
A zero or negative integer disables this parameter.

The default value is 10 (minutes).

 Note
The value of this parameter can be changed when the re­
mote source is suspThe value of this parameter can be
changed when the remote source is suspended.

When querying the trigger queue table, the scanner may en­
counter a “deadlock exception”. Use this option to set the maxi­
mum number of retries before failing (if the retries do not suc­
ceed). The default value is 0, which means the adapter does not
retry any scans when encountering deadlock exceptions.

Installation and Configuration Guide


486 PUBLIC Configure Data Provisioning Adapters
Category Option Description

Scan Retry Wait Time in The number of seconds for the scanner to wait before trying
Seconds again to query the trigger queue table. A retry occurs only when
you encounter a “deadlock exception”. The default value is 30
seconds.

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

Connection Security Use Agent Stored Creden­ Set to True to use credentials that are stored in the DP Agent se­
tial
cure storage.

Credentials Credentials Mode Remote sources support two types of credential modes to ac­
cess a remote source: technical user and secondary credentials.

● Technical User: A valid user and password in the remote da­


tabase. This valid user is used by anyone using the remote
source.
● Secondary User: A unique access credential on the remote
source assigned to a specific user.

Username Database user name (or LDAP username/Kerberos principal


name when using logon mechanisms other than TD2)

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

Password The appropriate corresponding password

 Note
The value of this parameter can be changed when the re­
mote source is suspended.

Example

 Sample Code

CREATE REMOTE SOURCE "MyTeradataSource" ADAPTER "TeradataAdapter" AT LOCATION


AGENT "MyAgent"
CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configuration" displayName="Configurations">
<PropertyGroup name="connectionInfo">
<PropertyEntry name="host" displayName="Host">myhost.sap.corp</
PropertyEntry>

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 487
<PropertyEntry name="database" displayName="Database Name">mydb</
PropertyEntry>
<PropertyEntry name="port" displayName="Port Number">1025</
PropertyEntry>
<PropertyEntry name="encoding">UTF8</PropertyEntry>
<PropertyEntry name="encrypt">ON</PropertyEntry>
<PropertyEntry name="logmech">TD2</PropertyEntry>
<PropertyEntry name="logdata"></PropertyEntry>
<PropertyEntry name="fast_export">OFF</PropertyEntry>
<PropertyEntry name="additional"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc_properties">
<PropertyEntry name="prefix">TADP_</PropertyEntry>
<PropertyEntry name="conn_pool_size">10</PropertyEntry>
<PropertyEntry name="min_scan_interval">2</PropertyEntry>
<PropertyEntry name="max_scan_interval">10</PropertyEntry>
<PropertyEntry name="scan_retry_max_attempts">3</PropertyEntry>
<PropertyEntry name="scan_retry_wait_time">10</PropertyEntry>
</PropertyGroup>
</ConnectionProperties>
' WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="credential">
<user>myuser</user>
<password>mypassword</password>
</CredentialEntry>';

Related Information

Using Prefix and Suffix Options to Manage System Object Name Lengths [page 488]
Permissions for Accessing Multiple Schemas [page 489]
Teradata DDL Propagation Scan Interval [page 489]
Store Source Database Credentials in Data Provisioning Agent [Graphical Mode] [page 93]

6.26.3.1 Using Prefix and Suffix Options to Manage System


Object Name Lengths

The Teradata adapter creates a number of system objects on the source database in order for it to manage
real-time replication. These objects include shadow tables, triggers, and stored procedures. If your Teradata
database has a 30-character name limit, the default remote source settings can lead to Teradata adapter
system objects with names greater than 30 characters. By default, the Teradata adapter’s system object
prefixes and suffixes add up to 12 extra characters, which means that only tables with names of 18 characters
(or less) are supported.

To maximize the number of table name characters supported, edit the four system object prefix and suffix
properties to one character each (they cannot be empty). Doing so ensures that the Teradata adapter uses at
most five extra characters when creating its system objects, meaning that table names of up to 25 characters
can be supported when the 30-character database limit is in place. The following options are available to
configure:

● System Object Prefix

Installation and Configuration Guide


488 PUBLIC Configure Data Provisioning Adapters
● Shadow Table Prefix
● Stored Procedure Prefix
● Trigger Suffix

 Note

When upgrading, if the Teradata adapter tries to read those properties and they are not present (for
example, they are not part of the previous remote source before the upgrade), then the adapter uses the
default values. When the user edits the remote source after the upgrade, they will see those default values
in the remote source description.

Related Information

Teradata Remote Source Configuration [page 483]

6.26.3.2 Permissions for Accessing Multiple Schemas

Grant the necessary permissions before accessing multiple schemas in a Teradata source.

To access multiple schemas, you need the following permissions assigned to you. In the following example, you
are USER2, and you are accessing tables, creating procedures, executing procedures, and so on, belonging to
USER1.

GRANT CREATE TABLE ON USER1 TO USER2


GRANT DROP TABLE ON USER1 TO USER2
GRANT ALL ON USER1.<table_name> TO USER2
GRANT CREATE PROCEDURE ON USER1 TO USER2
GRANT DROP PROCEDURE ON USER1 TO USER2
GRANT CREATE TRIGGER ON USER1 TO USER2
GRANT DROP TRIGGER ON USER1 TO USER2
GRANT EXECUTE PROCEDURE ON USER2 TO USER1

 Note

The EXECUTE PROCEDURE permission allows USER1 to execute the procedures in database USER2.

6.26.3.3 Teradata DDL Propagation Scan Interval

The DDL Scan Interval in Minutes Adapter Preference option is important to review when setting up DDL
propagation.

Enabling DDL propagation can impact the performance of the source Teradata database. Setting an
appropriate value for the remote source option DDL Scan Interval in Minutes matters.

From the time the DDL changes occurs on the source database to the time the DDL changes are propagated to
the target Teradata database, no DML changes on the tables are allowed. At configured intervals (DDL Scan

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 489
Interval in Minutes, by default, 10 minutes), the Teradata adapter queries the metadata of all subscribed tables
from the source Teradata database, and it determines if changes to the DDL have occurred. If changes are
detected, it propagates the DDL changes to the target database through the Data Provisioning Server.

Because the Teradata adapter detects DDL changes by querying source Teradata system tables, the source
database might be burdened if you configure a small value for the DDL Scan Interval in Minutes option.
However, configuring a large value would increase the latency of DDL propagation. Therefore, you should
experiment to figure out what value works best for you. If changes to the DDL are rare, you might even want to
disable DDL propagation by setting the value of the DDL Scan Interval in Minutes option to zero. This prevents
the Teradata adapter from querying metadata from the source database periodically.

Related Information

Teradata Remote Source Configuration [page 483]

6.26.4 Disable Adapter Write-back Functionality

For critical scenarios determined by your business requirements, you can use the agent configuration tool to
disable write-back functionality on supported adapters and run the adapters in read-only mode.
Disabling write-back functionality may help to prevent unexpected modifications to source tables accessed by
an adapter.

 Caution

Setting an adapter to read-only mode affects all remote sources that use the adapter.

Procedure

1. Start the Data Provisioning Agent configuration tool.


2. Navigate to the Agent Adapter Framework Preferences.

○ In graphical mode, choose Config Preferences , and then select Adapter Framework.
○ In command-line interactive mode, choose Set Agent Preferences in the Agent Preferences menu.
3. For the Read-only Adapters property, specify the list of adapters for which you want to disable write-back
functionality, separating each adapter with a comma.

For example, to disable write-back on the Microsoft SQL Server Log Reader, Oracle Log Reader, and SAP
HANA adapters:

MssqlLogReaderAdapter,OracleLogReaderAdapter,HanaAdapter

Installation and Configuration Guide


490 PUBLIC Configure Data Provisioning Adapters
Results

The specified adapters are switched to read-only mode and write-back functionality is disabled.

 Tip

On adapters that are operating in read-only mode, attempted SQL statements other than SELECT result in
adapter exceptions that are logged in the Data Provisioning Agent framework trace file.

For example:

com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed


by this data provisioning agent for adapter: MssqlLogReaderAdapter Context:
com.sap.hana.dp.adapter.sdk.AdapterException: Only SELECT queries are allowed
by this data provisioning agent for adapter: MssqlLogReaderAdapter

Related Information

Start and Connect the Configuration Tool [page 84]


Start the Configuration Tool [Command Line] [page 51]
Agent Adapter Framework Preferences [page 104]

6.27 Twitter

The Twitter adapter provides access to Twitter data via the Data Provisioning Agent.

Twitter is a social media Web site that hosts millions of tweets every day. The Twitter platform provides access
to this corpus of data. Twitter has exposed all its data via RESTful API so that it can be consumed with any
HTTP client. Twitter APIs allow you to consume tweets in different ways, from getting tweets from a specific
user, to performing a public search, or subscribing to real-time feeds for specific users or the entire Twitter
community.

Adapter Functionality

The Twitter adapter supports the following functionality:

● Virtual table or function as a source


● Real-time change data capture (flowgraph and replication task)

In addition, this adapter supports the following capabilities:

● SELECT, WHERE

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 491
Twitter Adapter

The Twitter adapter is a streaming data provisioning adapter written in Java, and utilizes the Adapter SDK to
provide access to Twitter data via SAP HANA SQL (with or without Data Provisioning parameters) or via virtual
functions.

Using the Adapter SDK and the Twitter4j library, the Twitter adapter consumes the tweets from Twitter and
converts to AdapterRow objects to send to SAP HANA server. The tweet is exposed to SAP HANA server via
virtual tables. Each Status table is basically a map of JSON data returned from Twitter to tabular form.
Currently we expose the following columns in all Status tables.

Column name SQL Data Type Dimension

Id BIGINT

ScreenName NVARCHAR 256

Tweet NVARCHAR 256

Source NVARCHAR 256

Truncated TINYINT

InReplyToStatusId BIGINT

InReplyToUserId BIGINT

InReplyToScreenName NVARCHAR 256

Favorited TINYINT

Retweeted TINYINT

FavoriteCount INTEGER

Retweet TINYINT

RetweetCount INTEGER

RetweedByMe TINYINT

PossiblySensitive TINYINT

isoLanguageCode NVARCHAR 256

CreatedAt DATE

Latitude DOUBLE

Longitude DOUBLE

Country NVARCHAR 256

Place_name NVARCHAR 256

Place_type NVARCHAR 256

UserId BIGINT

UserName NVARCHAR 256

UserUrl NVARCHAR 256

CurrentUserRetweetId BIGINT

Installation and Configuration Guide


492 PUBLIC Configure Data Provisioning Adapters
Related Information

Installation and Deployment [page 493]


Twitter Remote Source Configuration [page 495]

6.27.1 Installation and Deployment

Configure your Data Provisioning agent and SAP HANA server to use the Twitter adapter.

Though the Twitter adapter is installed with the Data Provisioning agent, you must configure your agent to
communicate with the SAP HANA server. In addition, you must configure your SAP HANA server and create a
remote source.

Configure the dpagentconfig.ini file

Configure proxy settings in the dpagentconfig.ini file by adding the following to the file:

● proxyHost=<<proxy host name>>


● proxyPort=<<proxy port number>>

Related Information

Set Up a Twitter Account [page 493]


Create a Twitter Remote Source [page 494]
Twitter Adapter Capabilities [page 495]

6.27.1.1 Set Up a Twitter Account

Follow these steps to set up a Twitter account.

Procedure

1. Create a Twitter developer account at https://dev.twitter.com/user/login?destination=home .


2. Create an application in Twitter.
3. Obtain the following:

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 493
○ API Key
○ API Secret
○ Access Token
○ Access Token Secret

See https://dev.twitter.com/docs/auth/oauth/faq to get more insight on how to set up authentication.

6.27.1.2 Create a Twitter Remote Source

Follow these steps to create a Twitter remote source.

Procedure

1. In the Systems view, open Provisioning Remote Sources .


2. Select an agent under Source Location.
3. Right-click Remote Sources, and select New Remote Source.
4. Enter the required remote source configuration information.
5. Set the Credentials Mode parameter to “technical user”.
6. Click the Save the Editor icon in the upper right-hand corner of the screen.

Results

The following directory structure is created, allowing you to create virtual tables or virtual functions as needed.

Installation and Configuration Guide


494 PUBLIC Configure Data Provisioning Adapters
Related Information

Twitter Remote Source Configuration [page 495]


Create Credentials for a Secondary User

6.27.1.3 Twitter Adapter Capabilities

The Twitter adapter supports the following capabilities.

NAME

CAP_NON_TRANSACTIONAL_CDC

CAP_WHERE

CAP_LIKE

CAP_SIMPLE_EXPR_IN_WHERE

CAP_OR

CAP_SELECT

CAP_BIGINT_BIND

CAP_TABLE_CAP

CAP_COLUMN_CAP

CAP_METADATA_ATTRIBUTE

See the description of these capabilities in the Javadoc documentation, which can be found in
<DPAgent_root>/doc/javadoc.

6.27.2 Twitter Remote Source Configuration

Remote source configuration options for the Twitter adapter. Also included is sample code for creating a
remote source using the SQL console.

Option Description

API Key Consumer Key

API Secret Consumer Secret

Access Token Oauth Token

Access Token Secret Oauth Secret

Installation and Configuration Guide


Configure Data Provisioning Adapters PUBLIC 495
Example

 Sample Code

CREATE REMOTE SOURCE "MyTwitterSource" ADAPTER "TwitterAdapter" AT LOCATION


AGENT "MyAgent" CONFIGURATION
'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="configuration">
</ConnectionProperties>'
WITH CREDENTIAL TYPE 'PASSWORD' USING
'<CredentialEntry name="consumerKey" displayName=”API Key (Consumer Key)”>
<password>myapikey</password>
</CredentialEntry>
<CredentialEntry name="consumerSecret" displayName=”API Secret (Consumer
Secret)”>
<password>myapisecret</password>
</CredentialEntry>
<CredentialEntry name="oauthToken" displayName=”Access Token (Oauth Token)”>
<password>myaccesstoken</password>
</CredentialEntry>
<CredentialEntry name="oauthSecret" displayName=”Access Token Secret (Oauth
Secret)”>
<password>myaccesstokensecret</password>
</CredentialEntry>';

Installation and Configuration Guide


496 PUBLIC Configure Data Provisioning Adapters
7 Security

SAP HANA smart data integration adds database objects and communication channels to the SAP HANA
security landscape.

Some aspects of SAP HANA smart data integration require specific security-related considerations such as the
communication channel between SAP HANA and the Data Provisioning Agent. However, in general, SAP HANA
smart data integration follows standard SAP HANA security concepts. For complete information, refer to the
SAP HANA Security Guide.

Related Information

Authentication [page 497]


Configuring SSL [page 498]
Update JCE Policy Files for Stronger Encryption [page 518]
Authorizations [page 519]
Communication Channel Security [page 520]
Auditing Activity on SAP HANA Smart Data Integration Objects [page 521]
Data Protection and Privacy in SAP HANA Smart Data Integration and SAP HANA Smart Data Quality [page
522]
SAP HANA Security Guide

7.1 Authentication

Authentication is the process of verifying the identity of database users accessing SAP HANA . SAP HANA
supports several authentication mechanisms, several of which can be used for the integration of SAP HANA
into single sign-on environments (SSO).

For complete information about authentication and single sign-on within SAP HANA, refer to the SAP HANA
Security Guide.

Authentication with Remote Source Systems

For remote source systems accessed by Data Provisioning adapters, user name and password authentication is
supported. That is, users authenticate themselves by entering their user name and password for the remote
source.

For custom adapters, the developer is free to implement any type of authentication.

Installation and Configuration Guide


Security PUBLIC 497
Kerberos Limitation for Some Data Provisioning Adapters

Some Data Provisioning adapters, such as Hive, Teradata, and Impala, support Kerberos authentication. When
using Kerberos authentication, only encryption types whose key length is fewer than 256 characters are
supported.

This limitation comes from the SAP JVM packaged with the DP Agent. If you need to use strong encryption,
replace the SAP JCE policy files.

Related Information

SAP HANA Security Guide


Update JCE Policy Files for Stronger Encryption [page 518]

7.2 Configuring SSL

Learn an overview of how to configure SSL connections in SAP HANA smart data integration.

You can configure SSL connections from the Data Provisioning Agent to SAP HANA server and, depending on
the adapter you are using, from Data Provisioning Agent to your remote database.

 Note

To configure SSL for the Odata adapter, which does not use the Data Provisioning Agent, refer to Consume
HTTPS OData Services [page 348]

Successful configuration of SSL in SAP HANA smart data integration requires that the following be performed:

Connecting from Data Provisioning Agent to SAP HANA server

1. Enable and configure SAP HANA server for SSL.


For more information, see Secure Communication Between SAP HANA and JDBC/ODBC Clients and
subsequent topics.
2. Create a keystore/truststore on the SAP HANA system and the Data Provisioning Agent, and then obtain
SSL certificates and import them into your SAP HANA system and the Data Provisioning Agent.
There are different methods to accomplish these steps.
○ Command line batch
See Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509] for more
information.
○ Command line interactive
For more information, see Configure SSL for SAP HANA (CA) [page 500] or Configure SSL for SAP
HANA (Self-Signed) [page 505].

Installation and Configuration Guide


498 PUBLIC Security
3. Connect to SAP HANA with SSL.
Once you have configured your certificates for the Data Provisioning Agent and SAP HANA Server, you
need to enable SSL on the Data Provisioning Agent, and so on. For more information, see Connect to SAP
HANA On-Premise with SSL [page 512]

Connecting from Data Provisioning Agent to Your Remote Source

1. Create the Data Provisioning Agent keystore and truststore to house the remote source certificates.
For more information, see Configure the Adapter Truststore and Keystore Using the Data Provisioning
Agent Configuration Tool [page 513].
2. Configure your source database.
Configure your source database for SSL. This includes creating CA certificates and importing them into
Data Provisioning Agent.
3. Configure SSL on the remote source that you are creating.
Adapters that support SSL may have different configuration requirements. At a minimum, you need to
enable SSL in the remote source configuration. Other remote source parameters may also need to be
configured, depending on the adapter that you are using and your preferences.

Encryption Strength

If you require stronger encryption than 128 bit key length, update the existing JCE policy files.

Related Information

Configure SSL for SAP HANA (CA) [page 500]


Configure SSL for SAP HANA (Self-Signed) [page 505]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Connect to SAP HANA On-Premise with SSL [page 512]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]
Change the Agent Configuration Tool SSL Settings [page 515]
Reconfigure an Existing Agent for SSL [page 516]
Troubleshoot the SSL Configuration [page 517]
Configure SSL for the DB2 Log Reader Adapter [page 278]
Configure SSL for the Microsoft SQL Server Log Reader Adapter [page 338]
Configure SSL for the Oracle Log Reader Adapter [page 391]
Cassandra SSL Configuration [page 172]
Update JCE Policy Files for Stronger Encryption [page 518]

Installation and Configuration Guide


Security PUBLIC 499
7.2.1 Configure SSL for SAP HANA (CA)

Use the Data Provisioning Agent Keystore Configuration utility to configure and set up SSL for SAP HANA by
getting a certificate from a certificate authority (CA). This secures connectivity from the SAP HANA database
to the SAP HANA Data Provisioning Agent via SSL.

Prerequisites

You must have the following before configuring SSL:

● Command-line access to SAP HANA Server using the HANA adm user account
● Command-line access to the Data Provisioning Agent using the DPAgent user account
● Back up the following files from the Data Provisioning Agent installation directory:
○ sec and secure_storage (encrypted files to store keystore passwords)
○ dpagentconfig.ini (configuration file to tell the Data Provisioning Agent to use SSL)
○ ssl/cacerts (Java keystore to store server and agent certificates)
● Set the PATH variable to include the Data Provisioning agent sapvim/bin subdirectory so agentcli can
find the keytool executable.
Example: export PATH=/hana1/sapjvm/bin:$PATH
● Set the DPA_INSTANCE variable to the directory where the Data Provisioning agent is installed.
Example: export DPA_INSTANCE=/hana1/bin/dpagent

Context

The Data Provisioning Agent Keystore Configuration utility is a guided interactive tool used to configure SSL for
SAP HANA. Perform the following steps to get a certificate from a certificate authority (CA).

Procedure

1. Start the Data Provisioning Agent Keystore Configuration utility from the terminal by entering ./
agentcli.sh.

 Note

Don’t exit the tool when setting up SSL, even when copying certificates between agent and HANA
hosts.

dpagent@vm:/usr/sap/dpagent/bin> ./agentcli.sh
Environment variable DPA_INSTANCE not found
Environment variable DPA_INSTANCE must point to DPAgent's installation root
directory
Example:: export DPA_INSTANCE=/usr/sap/dataprovagent/ then try again

Installation and Configuration Guide


500 PUBLIC Security
2. If you get an error message stating that the environment variable isn't found, run the following command to
set it up. After a successful execution, it displays a list of available commands.

kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> export DPA_INSTANCE=/hana1/bin/dpagent


kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> ./agentcli.sh
Using the following installation location
/hana1/bin/dpagent
--createFullSystemDump Gathers all related log files and ini settings and
creates an archive
--setSecureProperty Secure Storage Utility
--configAgent DPAgent Configuration Tool
--configAgentKeystore DPAgent Keystore Configuration Utility
<operation> --help To print help for the given operation

3. To view a list of available options, enter the command ./agentcli.sh --configAgentKeystore.

kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> ./agentcli.sh --configAgentKeystore


************************************************************
DPAgent Keystore Configuration Utility
************************************************************
1. Configure SSL for TCP (HANA on-premise) (interactive only)
2. List Agent Certificate
3. List All Certificate
4. List Certificate (by alias)
5. Export Agent Certificate
6. Export Certificate (Base64-Encoded)
7. Import Certificate
8. Delete Certificate
9. Change keystore password
q. Quit
b. Back
************************************************************

4. In the DPAgent Keystore Configuration Utility, use option 1 to configure SSL for TCP (HANA on-premise).

************************************************************
Configure SSL for TCP (HANA on-premise) (interactive only)
************************************************************
Enter Store Password: (*****) [The default password is changeit]
Enter Register Agent on HANA after SSL Configuration(true): Valid options:
true|false [You should always do this to ensure the setup is correct]
true
Enter Agent name to register with(ProductionAgent): [Agent name that you want
to register in HANA with]
SSLAgent
Enter Hana Server Host name(localhost): [This is hana server name and not
the dpagent server name]
mo-1a6803cc5.mo.sap.corp
Enter Hana Server Port Number(30015): [Hana port usually 3xx15 where xx is
your instance id]
30215
Enter Agent Admin HANA User: [HANA user that have AGENT ADMIN privilege]
system
Enter Password for Agent Admin HANA User:
Enter Password for Agent Admin HANA User: (confirm)

5. The following section defines the Data Provisioning Agent certificate and runs the following command. Use
the same key_password as the store_password.

Enter The name of your organizational unit(Test Product):


SAP Tools
Enter The name of your organizational(Test Organization):
SAP
Enter The name of your City or Locality(Palo Alto):
Enter The name of your State or Province(CA):

Installation and Configuration Guide


Security PUBLIC 501
Enter The two-letter country code for this unit(US):

6. Create a certificate signing request, so that the certificate can be signed by a certificate authority, by
selecting false.

Enter Use self-signed certificates for DPAgent?(false): Valid options: true|


false
false
Calling Configure SSL for TCP (HANA on-premise) (interactive only)
(configureKeystore)
*** Executing configureKeystore
************************************************************
Configuring DPAgent Keystore
************************************************************
Checking existing cacerts for dpagent private key
Using DPAgent hostname = mo-1a6803cc5.mo.sap.corp and Alias =
dataprovisioningagent
cacerts does not have dpagent certificate
Creating a backup of existing keystore /hana1/bin/dpagent/ssl/cacerts.bak

7. The fully qualified domain name (FQDN) must match the Data Provisioning Agent host name and the SAP
HANA Server must be able to ping this machine. The HANA Server validates the Data Provisioning Agent
host name and requires it to match what is set up in the AGENTS table.

Server does a host-name validation. Ensure the following FQDN is correct.


Enter dpagent machine host name? (mo-1a6803cc5.mo.sap.corp)
Creating dpagent keystore with Certificate:
CN=mo-1a6803cc5.mo.sap.corp,OU=Test Product,O=Test Organization,L=Palo
Alto,S=CA,C=US
Executing ->[keytool, -genkeypair, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -alias, dataprovisioningagent, -keyalg, RSA, -keysize, 2048, -dname,
CNrganization,L=Palo Alto,S=CA,C=US, -v]
Generating 2,048 bit RSA key pair and self-signed certificate
(SHA256withRSA) with a validity of 3,650 days
for: CN=mo-1a6803cc5.mo.sap.corp, OU=Test Product, O=Test
Organization, L=Palo Alto, ST=CA, C=US
[Storing /hana1/bin/dpagent/ssl/cacerts]
DPAgent keystore created successfully.
Generating Certificate Sign Request at /hana1/bin/dpagent/ssl/
dpagent_CSR.cer
Executing ->[keytool, -certreq, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -alias, dataprovisioningagent, -file, /hana1/bin/dpagent/ssl/
dpagent_CSR.c
DPAgent CSR created at /hana1/bin/dpagent/ssl/cacerts
*) Please request the CA authority to sign the Certificate
Request.
*) Get the CA root certificate as a cer file and import it
here (ex. CA_Root.cer )
*) Get the signed DPAgent Certificate response from the CA.
(ex. CA_DPAgent_Signed.cer
Enter path to CA Root certificate? (/hana1/bin/dpagent/ssl/CA_Root.cer)

The utility creates a Data Provisioning Agent keystore and creates the certificate signing request,
dpagent_CSR.cer. Provide the content of this file to your certificate authority (CA). The CA signs this
certificate, and then provides a signed certificate response. In the response, some certificate authorities
may provide the root, interim, and response all in one file or in multiple files.
8. The Java keystore requires the root to be imported after a response. Using the utility, you must strip the
root certificate from the rest of the chain and import only the root at the first prompt. Save the root CA in
the same folder.

Enter path to CA Root certificate? (/hana1/bin/dpagent/ssl/CA_Root.cer)

Installation and Configuration Guide


502 PUBLIC Security
Executing ->[keytool, -importcert, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -file, /hana1/bin/dpagent/ssl/CA_Root.cer, -alias, dpagentrootca, -
v, -
Certificate was added to keystore
[Storing /hana1/bin/dpagent/ssl/cacerts]
Successfully imported certificate as dpagentrootca
Enter path to signed certificate response for DPAgent? (/hana1/bin/
dpagent/ssl/CA_DPAgent_Signed.cer)

9. After you import the root, you can import the remaining chain or just the agent.

Executing ->[keytool, -importcert, -keystore, /hana1/bin/dpagent/ssl/


cacerts, -file, /hana1/bin/dpagent/ssl/CA_DPAgent_Signed.cer, -alias,
dataprovis
Certificate reply was installed in keystore
[Storing /hana1/bin/dpagent/ssl/cacerts]
Successfully imported certificate as dataprovisioningagent
Executing ->[keytool, -exportcert, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -file, /hana1/bin/dpagent/ssl/dpagent.cer, -alias,
dataprovisioningagen
Certificate stored in file </hana1/bin/dpagent/ssl/dpagent.cer>

The Data Provisioning Agent keystore now has the Data Provisioning Agent certificate and exports the
certificate to the SSL folder. Now, copy the certificate to the SAP HANA machine.
10. On the SAP HANA Server, create the SAP HANA keystore, get the certificate signed, and import the signed
response.

************************************************************
HANA Configuration
************************************************************
Now for the HANA side setup you need to have HANA Shell Access.
* Once you have access please navigate to
=>cd $SECUDIR
*)If sapcli.pse exists there, the server certificate is created
already. If not, create sapcli.pse via the following
=> sapgenpse get_pse -p sapcli.pse "CN=hostname.fully.qualified,
OU=Support, O=SAP, C=CA"
*) Please request the CA authority to sign the Certificate
Request.
*) Get the CA root certificate as a cer file and save it here
(ex. CA_Root.cer)
*) Get the signed DPAgent Certificate response from the CA.
(ex. CA_Signed_Server.cer
*) Once you have all certificate import the CA Response along
with Optional Root Certificates.
=> sapgenpse import_own_cert -c CA_Signed_Server.cer -p
sapcli.pse <-r optional_CA_Root>
*) Import DPAgent Certificate /hana1/bin/dpagent/ssl/dpagent.cer,
which is required by Client Authentication.
-----BEGIN CERTIFICATE-----
MIIDqzCCApOgAwIBAgIJAOdNZo6S7awNMA0GCSqGSIb3DQEBBQUAMCgxCzAJBgNV
BAYTAlVTMQswCQYDVQQIDAJDQTEMMAoGA1UECgwDU0FQMB4XDTE3MDgyMjIwMjMx
OFoXDTE4MDgyMjIwMjMxOFowgYQxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJDQTES
MBAGA1UEBxMJUGFsbyBBbHRvMRowGAYDVQQKExFUZXN0IE9yZ2FuaXphdGlvbjEV
MBMGA1UECxMMVGVzdCBQcm9kdWN0MSEwHwYDVQQDExhtby0xYTY4MDNjYzUubW8u
c2FwLmNvcnAwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCrI9kfAGlq
baTSttC2I3GrbH4FF95/wJ+aMNpVe9quS3qH4cMpN+Bqh2YYq1qucRzjwOiWH8rN
t3eNd4lYw7HvDEN4u/3uhtHCle2tmoOHVdesGZ8Ui2250RXBBEhY2ug48uyFSHp2
60y0NQBLGfSDdV+8ZqGJZ0zZrxHMW9J5DsKB8Yblp5aC8TZHpu5JP6nC2rVM/BmB
LGX1YkTYmaHkzZaRnglWBwaK9l3x3qNOOiDgSFOxJGPrHBuWDM0LQJOQwibpFu6K
RlTlOV8wTYoiS/ETRzEQ2vcHT998uzqKRuaeKAtnMGq+CDHSRSYDb/Q152sJoMmK
GtOvoZZ2vE1hAgMBAAGjezB5MAkGA1UdEwQCMAAwLAYJYIZIAYb4QgENBB8WHU9w
ZW5TU0wgR2VuZXJhdGVkIENlcnRpZmljYXRlMB0GA1UdDgQWBBQ6lejpKojc4Ilr
DUmw+ade6pXewTAfBgNVHSMEGDAWgBSjkBEgkX3wJIWR8Ms1LHm+GSlswzANBgkq
hkiG9w0BAQUFAAOCAQEANv1NoddAZVWxB8H02lpT3IYb38jpPqPp7wX0xlSPfhQJ

Installation and Configuration Guide


Security PUBLIC 503
5mg+5U4igB6qg9cIvbWxwpD2CMmQUHlJ7iuPTNdnnCyvJYkJ5ZTQ2l6L90y24gRo
4khwEBLC9d3V+mF5+ZJspJJey+l76TVu9tve3/GEOsQDqQBlxQd/VJ5j53Ik4mxB
OeFp7OAvFt251QSqGIU8K8lA+6ocB1mYTfKmVVz1f2/5AhdHMMOeQDKEVIjWrz3J
9NtjWXezf1zRiLdT0E9yz1OLaEZ53jC/6ZJv8Ia9L8I8OfBJaumW2477nNXgnvhX
dojfRbepmPQGSj/Z2HozcCfYQCNTOQ63ECNOPuf9+g==
-----END CERTIFICATE-----
*) You can save the above certificate to a file dpagent.cer in the
serverside and import it to sapcli.pse
=> sapgenpse maintain_pk -a dpagent.cer -p sapcli.pse
*)If SSO has not yet been enabled for this keystore, you can do it
with
=> sapgenpse seclogin -lps -p sapcli.pse -O <Instance_Name>adm
*)Export the HANA Server certificate and save it in dpagent machine
=> sapgenpse export_own_cert -o hana_server.cer -p sapcli.pse
Press Enter to continue...

11. After you create the SAP HANA keystore, add the agent certificate, and then export the SAP HANA
certificate and import the SAP HANA certificate into the Data Provisioning Agent.

After exporting the HANA certificate with sapgenpse, copy the HANA certificate hana_server.cer back
to the Data Provisioning Agent host, and put the certificate in the Data Provisioning Agent /ssl
subdirectory (for example, /usr/sap/dataprovagent/ssl). If the Data Provisioning Agent keystore has
a previous alias called hanaserverrootca, delete this alias, because the agentcli imports the HANA
certificate using this alias name.

 Note

The following may not apply, depending on the root CA.

************************************************************
Post HANA Configuration.
************************************************************
Enter path to Server certificate or CA Root certificate path? ()
/hana1/bin/dpagent/ssl/hana_server.cer
Executing ->[keytool, -importcert, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -file, /hana1/bin/dpagent/ssl/hana_server.cer, -alias,
hanaserverrootca
Certificate was added to keystore
[Storing /hana1/bin/dpagent/ssl/cacerts]
Successfully imported certificate as hanaserverrootca

After configuration, the command-line tool updates.


1. It connects to SAP HANA to validate the connection.
2. It registers the agent without SSL to test the SAP HANA connection to the Data Provisioning Agent.
3. If the previous steps are successful, it updates the dpagentconfig.ini and secure_storage, and
persists all of the provided information.
12. Restart the Data Provisioning Agent.
13. Reregister the agent with the SSL flag.

Connecting to HANA Server at pall00553681a.amer.global.corp.sap


Registering agent as ProductionAgent with SSL=false
Enabling SSL on DPAgent TCP Sockets.
Successfully switched dpagent to use SSL.
Press Enter to continue...

Installation and Configuration Guide


504 PUBLIC Security
7.2.2 Configure SSL for SAP HANA (Self-Signed)

Use the Data Provisioning Agent Keystore Configuration utility to configure and set up SSL for SAP HANA by
creating a self-signed certificate. This secures connectivity from the SAP HANA database to the SAP HANA
Data Provisioning Agent via SSL.

Prerequisites

You must have the following before configuring SSL:

● Command-line access to SAP HANA Server using the HANA adm user account
● Command-line access to the Data Provisioning Agent using the DPAgent user account
● Back up the following files from the Data Provisioning Agent installation directory:
○ sec and secure_storage (encrypted files to store keystore passwords)
○ dpagentconfig.ini (configuration file to tell the Data Provisioning Agent to use SSL)
○ ssl/cacerts (Java keystore to store server and agent certificates)
● Set the PATH variable to include the Data Provisioning agent sapvim/bin subdirectory so agentcli can
find the keytool executable.
Example: export PATH=/hana1/sapjvm/bin:$PATH
● Set the DPA_INSTANCE variable to the directory where the Data Provisioning agent is installed.
Example: export DPA_INSTANCE=/hana1/bin/dpagent

Context

The Data Provisioning Agent Keystore Configuration utility is a guided interactive tool used to configure SSL for
SAP HANA. Perform the following steps to create a self-signed certificate.

Procedure

1. To start the Data Provisioning Agent Keystore Configuration utility from the terminal, enter ./
agentcli.sh.

 Note

Don’t exit the tool when setting up SSL, even when copying certificates between agent and HANA
hosts.

dpagent@vm:/usr/sap/dataprovagent/bin> ./agentcli.sh
Environment variable DPA_INSTANCE not found
Environment variable DPA_INSTANCE must point to DPAgent's installation root
directory
Example:: export DPA_INSTANCE=/usr/sap/dataprovagent/ then try again

Installation and Configuration Guide


Security PUBLIC 505
2. If you get an error message stating that the environment variable is not found, run the following command
to set it up. After a successful execution, it displays a list of available commands.

kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> export DPA_INSTANCE=/usr/sap/


dataprovagent/
kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> ./agentcli.sh
Using the following installation location
/hana1/bin/dpagent
--createFullSystemDump Gathers all related log files and ini settings and
creates an archive
--setSecureProperty Secure Storage Utility
--configAgent DPAgent Configuration Tool
--configAgentKeystore DPAgent Keystore Configuration Utility
<operation> --help To print help for the given operation

3. To view a list of available options, enter the command ./agentcli.sh --configAgentKeystore.

kb@mo-1a6803cc5:/hana1/bin/dpagent/bin> ./agentcli.sh --configAgentKeystore


************************************************************
DPAgent Keystore Configuration Utility
************************************************************
1. Configure SSL for TCP (HANA on-premise) (interactive only)
2. List Agent Certificate
3. List All Certificate
4. List Certificate (by alias)
5. Export Agent Certificate
6. Export Certificate (Base64-Encoded)
7. Import Certificate
8. Delete Certificate
9. Change keystore password
q. Quit
b. Back
************************************************************

4. In the DPAgent Keystore Configuration Utility, use option 1 to configure SSL for TCP (HANA on-premise).

************************************************************
Configure SSL for TCP (HANA on-premise) (interactive only)
************************************************************
Enter Store Password: (*****) [The default password is changeit]
Enter Register Agent on HANA after SSL Configuration(true): Valid options:
true|false [You should always do this to ensure the setup is correct]
true
Enter Agent name to register with(ProductionAgent): [Agent name that you want
to register in HANA with]
SSLAgent
Enter Hana Server Host name(localhost): [This is hana server name and not
the dpagent server name]
mo-1a6803cc5.mo.sap.corp
Enter Hana Server Port Number(30015): [Hana port usually 3xx15 where xx is
your instance id]
30215
Enter Agent Admin HANA User: [HANA user that have AGENT ADMIN privilege]
system
Enter Password for Agent Admin HANA User:
Enter Password for Agent Admin HANA User: (confirm)

5. The following section defines the Data Provisioning Agent certificate and runs the following command. Use
the same key_password as the store_password.

Enter The name of your organizational unit(Test Product):


SAP Tools
Enter The name of your organizational(Test Organization):
SAP
Enter The name of your City or Locality(Palo Alto):

Installation and Configuration Guide


506 PUBLIC Security
Enter The name of your State or Province(CA):
Enter The two-letter country code for this unit(US):

6. For a self-signed certificate, select true.

Enter Use self-signed certificates for DPAgent?(false): Valid options: true|


false [We are going to use self-signed certificate here.]
true
Calling Configure SSL for TCP (HANA on-premise) (interactive only)
(configureKeystore)
*** Executing configureKeystore
************************************************************
Configuring DPAgent Keystore
************************************************************
Checking existing cacerts for dpagent private key
Using DPAgent hostname = mo-1a6803cc5.mo.sap.corp and Alias =
dataprovisioningagent
cacerts does not have dpagent certificate
Creating a backup of existing keystore /hana1/bin/dpagent/ssl/cacerts.bak

7. The fully qualified domain name (FQDN) must match the Data Provisioning Agent host name, and the SAP
HANA Server must be able to ping this machine. The HANA Server validates the Data Provisioning Agent
host name and requires it to match what is set up in the AGENTS table.

Server does a host-name validation. Ensure the following FQDN is correct.


Enter dpagent machine host name? (mo-1a6803cc5.mo.sap.corp)
Creating dpagent keystore with Certificate:
CN=mo-1a6803cc5.mo.sap.corp,OU=SAP Tools,O=SAP,L=Palo Alto,S=CA,C=US
Executing ->[keytool, -genkeypair, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -alias, dataprovisioningagent, -keyalg, RSA, -keysize, 2048, -dname,
CN=mo-1a6803cc5.mo.sap.corp,OU=SAP Tools,O=SAP,L=Palo Alto,S=CA,C=US, -v]
Generating 2,048 bit RSA key pair and self-signed certificate
(SHA256withRSA) with a validity of 3,650 days
for: CN=mo-1a6803cc5.mo.sap.corp, OU=SAP Tools, O=SAP, L=Palo
Alto, ST=CA, C=US
[Storing /hana1/bin/dpagent/ssl/cacerts]
DPAgent keystore created successfully.
***Using self-signed certificates for dpagent***
Executing ->[keytool, -exportcert, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -file, /hana1/bin/dpagent/ssl/dpagent.cer, -alias,
dataprovisioningagent, -noprompt]
Certificate stored in file </hana1/bin/dpagent/ssl/dpagent.cer>

The Data Provisioning Agent keystore now has the Data Provisioning Agent certificate and exports the
certificate to the SSL folder. Now, copy the certificate to the SAP HANA machine.
8. On the SAP HANA Server, because this certificate is self-signed, create the SAP HANA keystore with a
noreq flag.

************************************************************
HANA Configuration
************************************************************
Now for the HANA side setup you need to have HANA Shell Access.
* Once you have access please navigate to
=>cd $SECUDIR
*)If sapcli.pse exists there, the server certificate is created
already. If not, create sapcli.pse via the following
=> sapgenpse get_pse -p sapcli.pse -noreq
"CN=hostname.fully.qualified, OU=Support, O=SAP, C=CA"
*) Import DPAgent Certificate /hana1/bin/dpagent/ssl/dpagent.cer,
which is required by Client Authentication.
-----BEGIN CERTIFICATE-----
MIIDhTCCAm2gAwIBAgIEclVYkDANBgkqhkiG9w0BAQsFADBzMQswCQYDVQQGEwJV
UzELMAkGA1UECBMCQ0ExEjAQBgNVBAcTCVBhbG8gQWx0bzEMMAoGA1UEChMDU0FQ
MRIwEAYDVQQLEwlTQVAgVG9vbHMxITAfBgNVBAMTGG1vLTFhNjgwM2NjNS5tby5z

Installation and Configuration Guide


Security PUBLIC 507
YXAuY29ycDAeFw0xNzA4MjIxNzMzMDVaFw0yNzA4MjAxNzMzMDVaMHMxCzAJBgNV
BAYTAlVTMQswCQYDVQQIEwJDQTESMBAGA1UEBxMJUGFsbyBBbHRvMQwwCgYDVQQK
EwNTQVAxEjAQBgNVBAsTCVNBUCBUb29sczEhMB8GA1UEAxMYbW8tMWE2ODAzY2M1
Lm1vLnNhcC5jb3JwMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEApobu
2Z670OByR5PKR8pL5C9jkrgiCIDBXVdY6ZdbZPkrkchIwl3SL6OeRLzxXDeWfVZO
TA5JoIKy7BSuT1SvX/6qN9NHYSFTtEJAV5g01B2fI+mPQ1RpWp/a2IPXUW8Lm1BQ
tAiiFCBazA3nAyf7wn8NvIlM3s3anALgqLrZsZOWc2cWAKv9LZDdJjvZZtdP8zDV
65YUPYxthGOD+K/yftOSlaFmSBOLSzkcUK/hCKy7mDEBjjQbviHVDV43akaRnJEd
ClCCVToJSoprdEgCLabO6vjFPIv37sID4sNhaTEcRDyDIB5eVpYTtd2ZDhEpJk5V
WsKKSmGgnLSmP9gtDQIDAQABoyEwHzAdBgNVHQ4EFgQUZfrkKpGfogzAdknrXOEX
IGdwn3MwDQYJKoZIhvcNAQELBQADggEBADd0sLSyeXOqSUePOhdUS2CLyJkMLgrY
BQ2t6cEyGJ8OPep6qmhTshqyUZ/psgtSDO6YTkD/d0ecBOkp+bXeoeJPfLRb5cLM
HePG39Meu3S1dxoo6ybNsmGWHIzZlk2MhbMBO15zzc9X8FsflsGuRTHGx7Z7q6lE
PwihFNImkEu8uI3Zz8lrT+ggVlJpmm5zqRyS5+iFV4kMjMoimkrgd2sBNY5wpF7O
LO6L/SIzNg9q1//9j2zp/fCSKjjyd/jn/veo10y6rUECOje8B1J5+WGeA6bDsEei
WiAMhF60A+63xXN3tdKIayRl0F8Hvz+ROO81LyAX6U0m4zo4g14OuCo=
-----END CERTIFICATE-----
*) You can save the above certificate to a file dpagent.cer in the
serverside and import it to sapcli.pse
=> sapgenpse maintain_pk -a dpagent.cer -p sapcli.pse
*)If SSO has not yet been enabled for this keystore, you can do it
with
=> sapgenpse seclogin -lps -p sapcli.pse -O <Instance_Name>adm
*)Export the HANA Server certificate and save it in dpagent machine
=> sapgenpse export_own_cert -o hana_server.cer -p sapcli.pse
Press Enter to continue...

9. After you create the SAP HANA keystore, add the agent certificate, and then export the SAP HANA
certificate and import the SAP HANA certificate into the Data Provisioning Agent.

************************************************************
Post HANA Configuration.
************************************************************
Enter path to Server certificate or CA Root certificate path? ()
/hana1/bin/dpagent/ssl/hana_server.cer
Executing ->[keytool, -importcert, -keystore, /hana1/bin/dpagent/ssl/
cacerts, -file, /hana1/bin/dpagent/ssl/hana_server.cer, -alias,
hanaserverrootca
Certificate was added to keystore
[Storing /hana1/bin/dpagent/ssl/cacerts]
Successfully imported certificate as hanaserverrootca

After configuration, the command-line tool updates.


1. It connects to SAP HANA to validate the connection.
2. It registers the agent without SSL to test the SAP HANA connection to the Data Provisioning Agent.
3. If the previous steps are successful, it updates the dpagentconfig.ini and secure_storage, and
persists all of the provided information.
10. Restart the Data Provisioning Agent.
11. Reregister the agent with the SSL flag.

Connecting to HANA Server at pall00553681a.amer.global.corp.sap


Registering agent as ProductionAgent with SSL=false
Enabling SSL on DPAgent TCP Sockets.
Successfully switched dpagent to use SSL.
Press Enter to continue...

Installation and Configuration Guide


508 PUBLIC Security
7.2.3 Configure SSL for SAP HANA On-Premise [Command
Line Batch]

When SAP HANA is installed on-premise, you must obtain a certificate for the agent and import certificates on
both the agent host machine and the SAP HANA system.

Prerequisites

Before configuring the agent, ensure that the SAP HANA system is already configured for SSL. For more
information, see the SAP HANA Security Guide.

You need the password for the keytool Java program to generate a keystore and import an SAP HANA
certificate. You can find the password, commands, and instructions in the keytool.txt file at
<DPAgent_root>\ssl\keytool.txt.

 Note

To safeguard your certificates, change the default password of the keystore.

Also, back up the following:

● SAP HANA sec directory


● Back up your <DPAgent_root>/ssl, <DPAgent_root>/sec, and <DPAgent_root/secure_storage>
directories, if they exist.

Procedure

1. Generate a keystore on the agent host machine.

<DPAgent_root>/sapjvm/bin/keytool -genkeypair -alias DPAgent -keyalg RSA -


keysize 2048 -dname
"CN=<agent_hostname>,OU=<organizational_unit>,O=<organization>,L=<city>,S=<sta
te>,C=<country>" -keypass <key_password> -storepass <store_password> -
keystore <DPAgent_root>/ssl/dpagent.jks

<agent_hostname> must be the fully qualified hostname of the machine where the agent is installed. (For
example, machine.company.com)

 Note

Use the same passwords from above later in steps when accessing the .jks when using -keypass
and -storepass options.

The alias and keystore values can be any value, but if referencing them later on, when creating the
certificate request and when importing the signed agent certificate, these alias and keystore values —
defined here — should be used again. So, the Data Provisioning Agent alias and keystore values should
be the same.

Installation and Configuration Guide


Security PUBLIC 509
2. Obtain a signed certificate for the agent and import the certificate into the keystore.
a. Generate the certificate request.

<DPAgent_root>/sapjvm/bin/keytool -certreq -file <DPAgent_root>/ssl/


Agent_Req.pem -alias Agent_Cert –keystore <DPAgent_root>/ssl/dpagent.jks -
storepass <store password>

b. Verify that the alias entry is of type PrivateKeyEntry.

<DPAgent_root>/sapjvm/bin/keytool –keystore <DPAgent_root>/ssl/dpagent.jks


-list -storepass <store password>

 Note

After generating the agent request, make sure that the alias entry is of type PrivateKeyEntry and
not trustedCertEntry. If the alias entry isn’t PrivateKeyEntry, we recommend that you delete the
alias and rerun the keytool -genkeypair … command to re-create the key pair, before
generating a certificate request for the Data Provisioning Agent.

c. Send the certificate request to a Certificate Authority (CA) to be signed.


d. After receiving the signed certificate from the CA, import it into the agent keystore.

<DPAgent_root>/sapjvm/bin/keytool -importcert -keystore cacerts -storepass


<store_password> -file <signed agent certificate_filename>.der -noprompt -
alias DPAgent

3. Import the SAP HANA agent certificate into the Data Provisioning Agent keystore.

 Note

If you’re importing more than one type of certificate, import them in the order shown. You don’t need to
import a self-signed certificate.

<DPAgent_root>/sapjvm/bin/keytool -importcert -keystore <your_keystore> -


storepass <store_password> -file <CA_certificate_filename>.der -noprompt -
alias <your CA alias> -v
<DPAgent_root>/sapjvm/bin/keytool -importcert -keystore <your_keystore> -
storepass <store_password> -file <intermediate_certificate_filename>.der -
noprompt -alias <your intermediate alias> -v
<DPAgent_root>/sapjvm/bin/keytool -importcert -keystore <your_keystore> -
storepass <store_password> -file <self_signed_certificate_filename>.der -
noprompt -alias <your Agent alias> -v

You can obtain the certificate by exporting it with the SAP Web Dispatcher. For more information, see SAP
Note 2009483 .
4. Use either the SAP HANA command-line tool (sapgenpse) or the Web Dispatcher user interface to import
the signed agent certificate. On SAP HANA, add the signed agent certificate to the sapcli Personal
Security Environment (PSE).
a. Back up sapcli.pse

mv sapcli.pse sapcli.pse.old

 Note

Use sapcli.pse, and not sapsrv.pse trust store, which will be used for client authentication.

Installation and Configuration Guide


510 PUBLIC Security
b. Generate a new PSE file. After this file (<server_certificate_name>.pem) is created, get it signed
by the CA.

sapgenpse get_pse -p sapcli.pse -x <your pin> -r <server cert


name>.pem "CN=…,OU=.., O=.., C=…"

c. Import the <signed_server_certificate_name>.pse file.

sapgenpse import_own_cert -c <signed server cert> -p sapcli.pse -x <your


pin> -r <CA cert> -r <intermediate cert> -v

d. Import the signed agent certificate into the PSE file.

sapgenpse maintain_pk -a <your signed agent cert> -p sapcli.pse -x <your


pin>

e. In SAP HANA, enable SSL logon for a HANA user:

sapgenpse seclogin -p sapcli.pse -x <your pin> -O adm <HANA ADM User>

5. Restart the Data Provisioning Agent.

<DPAgent_root>/bin/dpagent_service.sh stop
<DPAgent_root>/bin/dpagent_service.sh start

Next Steps

 Note

You can also add the certificate with the SAP Web Dispatcher. For more information, see SAP Note
2009483 .

If you require stronger encryption than 128-bit key length, update the existing JCE policy files.

Related Information

Connect to SAP HANA On-Premise with SSL [page 512]


Start and Connect the Configuration Tool [page 84]
Register the Agent with SAP HANA [page 91]
SAP Note 2009483
Update JCE Policy Files for Stronger Encryption [page 518]

Installation and Configuration Guide


Security PUBLIC 511
7.2.4 Connect to SAP HANA On-Premise with SSL

Specify connection information, user credentials, and SSL configuration information (using the Data
Provisioning Agent configuration tool) when the SAP HANA system is located on-premise and requires a secure
SSL connection.

Prerequisites

● Before you can configure the Data Provisioning Agent to use SSL with SAP HANA on-premise, you must
obtain the SSL certificates and import them to both the agent host machine and the SAP HANA system.
See Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509] for more information.
● The Agent Admin HANA User must have the following privileges:

Action Role or Privilege

Connect to SAP HANA System privilege: AGENT ADMIN

System privilege: ADAPTER ADMIN

Procedure

1. Navigate to the <DPAgent_root>/configTool directory.


2. Start the configuration tool.

○ On Windows, run dpagentconfigtool.exe.


○ On Linux, run ./dpagentconfigtool.

 Note

Start the configuration tool using the Data Provisioning Agent installation owner. The installation owner
is the same user that is used to start the agent service.

You may need to set the DISPLAY environment variable:

export DISPLAY <IP address>:0.0

The <IP address> is the IP address of the terminal where you want to send the dpagentconfigtool GUI.
3. In the configuration tool, choose Configure SSL, enter the SSL configuration information, and select Enable
SSL for Agent to HANA communication on TCP.

For all “...Path” parameters, enter “<DPAgent_root>/ssl/cacerts”, or enter the path where you will
find dpagent.jks, if you were using the command line batch process.

For all “...Type” parameters, enter “JKS”

Installation and Configuration Guide


512 PUBLIC Security
 Note

If you don’t specify a distinct Key Password, the value for Keystore Password is used for both the
keystore and individual keys. This value is checked only if a key password was specified during key
generation in the keytool utility.

4. Click Connect to the SAP HANA server.


a. Return to the configuration tool, or restart it if needed.
b. Click Connect to HANA.
c. Specify the hostname, port, and Agent Admin HANA User credentials for the SAP HANA server.

 Tip

To determine the correct port number when SAP HANA is deployed in a multi-database
configuration, execute the following SQL statement:

SELECT DATABASE_NAME,SERVICE_NAME,PORT,SQL_PORT,(PORT + 2) HTTP_PORT


FROM SYS_DATABASES.M_SERVICES WHERE DATABASE_NAME='<DBNAME>' and
((SERVICE_NAME='indexserver' and COORDINATOR_TYPE= 'MASTER') or
(SERVICE_NAME='xsengine'))

5. Click Register Agent, enter the Agent name, and click the Register button.

Next Steps

You can test your connections in the following ways:

● In the Adapters section, select HANAAdapter to perform a test, and click Register Adapter.
● In SAP HANA studio, run SELECT * FROM AGENTS, and check column IS_SSL_ENABLED = true.

Related Information

Default Installation Paths [page 47]


Assign Roles and Privileges [page 25]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Configure the Adapter Truststore and Keystore Using the Data Provisioning Agent Configuration Tool [page
513]

7.2.5 Configure the Adapter Truststore and Keystore Using


the Data Provisioning Agent Configuration Tool

The Data Provisioning Agent uses certificates stored in the adapter truststore and adapter keystore to manage
SSL connections to adapter-based remote sources.The adapter truststore contains the public keys and

Installation and Configuration Guide


Security PUBLIC 513
Certificate Authority (CA) certificates for the remote sources, while the adapter keystore contains private keys
used for client authentication.

Context

Configure the location, type, and password for both the adapter truststore and the adapter keystore with the
Data Provisioning Agent configuration tool.

Procedure

1. Navigate to the <DPAgent_root>/configTool directory.


2. Start the configuration tool using the Data Provisioning Agent installation owner.

○ On Windows, run dpagentconfigtool.exe.


○ On Linux, run ./dpagentconfigtool.

 Note

The installation owner is the same user that is used to start the agent service.

3. In the configuration tool, choose Configure SSL.


4. Enter the path, type, and password for both the adapter truststore and the adapter keystore.

 Note

By default, both the adapter truststore and the adapter keystore use the same settings:
○ Location: <DPAgent_root>/ssl/cacerts
○ Type: jks

 Tip

Use the Java keytool to change the default password to safeguard your certificates.

5. Click Save.

Next Steps

Use the Java keytool to import remote source CA certificates into the adapter truststore.

For example:

keytool -importcert -alias <source_name> -keystore <path_to_truststore> -


storepass <password> -file <path_to_certificate>

By default, keytool is located in <DPAgent_root/sapjvm/bin>.

Installation and Configuration Guide


514 PUBLIC Security
7.2.6 Change the Agent Configuration Tool SSL Settings

You can change the connection settings or certificates used by the Data Provisioning Agent Configuration tool
to connect to the SAP HANA server.

Context

By default, the Data Provisioning Agent Configuration tool does not validate the SAP HANA server against a
certificate stored in the agent truststore when connecting with SSL.

If you want to change the default behavior, advanced properties can be added to the dpagentconfig.ini file
for your agent:

Table 54: JDBC SSL properties for dpagentconfig.ini


Property Type Default Description

jdbc.encrypt boolean false (when Enables or disables TLS/SSL encryption

sslEnforce is
turned off)

true (when
sslEnforce is
turned on)

jdbc.validateCertificate boolean false Specifies whether to validate the server certificate

jdbc.hostNameInCertificate string * Host name used to verify the server identity (CN value in cer­
tificate)

The specified host name is used to verify the identity of the


server instead of the host name with which the connection
was established.

For example, in a single-host system, if a connection is es­


tablished from a client on the same host as the server, a mis­
match would arise between the host named in the certificate
(actual host name) and the host used to establish the con­
nection (localhost).

 Note
If you specify * as the host name, this parameter has no
effect. Other wildcards are not permitted.

Installation and Configuration Guide


Security PUBLIC 515
For example, to validate against a trusted certificate:

Procedure

1. Add the advanced properties to the dpagentconfig.ini file for your agent.

jdbc.encrypt=true
jdbc.hostNameInCertificate=*
jdbc.validateCertificate=true

2. From the SAP HANA server, export the public certificate.


sapgenpse export_own_cert -p sapsrv.pse -o server_jbdc_pubkey.cer
3. Copy the certificate to a location that can be reached from the agent host machine.
4. Use the command-line agent configuration tool to import the server certificate into the agent truststore.

On Windows: agentcli.bat --configAgentKeystore

On Linux: agentcli.sh --configAgentKeystore


5. Restart the Data Provisioning Agent.

7.2.7 Reconfigure an Existing Agent for SSL

When you create and register a Data Provisioning Agent, you can choose to use SSL communication. If you do
not configure SSL during agent creation, you can enable it later.

Prerequisites

Before configuring the agent for SSL, ensure that the SAP HANA system is already configured for SSL. For
more information, see the SAP HANA Security Guide.

 Note

You need the password for the keytool Java program to generate a keystore and import a HANA certificate.
You can find the password, commands, and the instructions in the keytool.txt file at <DPAgent_root>
\ssl\keytool.txt.

Change the default password of the keystore to safeguard your certificates.

Procedure

1. Suspend any active remote source subscriptions on the agent.

You can suspend remote source subscriptions from the Data Provisioning Remote Subscription Monitor.

Installation and Configuration Guide


516 PUBLIC Security
Alternatively, you can use the ALTER REMOTE SOURCE command:

ALTER REMOTE SOURCE <remote_source_name> SUSPEND CAPTURE;

2. Stop the SAP HANA Data Provisioning Agent service.


○ On Windows, use the Services manager in Control Panel.
○ On Linux, run ./dpagent_service.sh stop.
3. Prepare the agent host system by generating a keystore and importing certificates.

For more information, see“Prepare SSL when SAP HANA is On-premise”.


4. Restart the SAP HANA Data Provisioning Agent service.
○ On Windows, use the Services manager in Control Panel.
○ On Linux, run ./dpagent_service.sh start.
5. Alter the agent registration to enable SSL.

You can alter the agent registration from the Data Provisioning Agent Monitor.

Alternatively, you can use the ALTER AGENT command:

ALTER AGENT <agent_name> ENABLE SSL;

6. Resume capture for any remote source subscriptions on the agent.

You can resume remote source subscriptions from the Data Provisioning Remote Subscription Monitor.

Alternatively, you can use the ALTER REMOTE SOURCE command:

ALTER REMOTE SOURCE <remote_souce_name> RESUME CAPTURE;

Related Information

Suspend and Resume Remote Sources


Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]
Manage Agents from the Data Provisioning Agent Monitor [page 103]

7.2.8 Troubleshoot the SSL Configuration

If the configuration process does not succeed due to misconfiguration, unopen ports, or other settings, you
can try these troubleshooting steps.

● View the errors in the log/framework_alert.trc files.


● Verify that in the dpagentconfig.inifile, the framework.enableSSL parameter is set to true.
● Restart the Data Provisioning Agent and run the following command from SAP HANA: ALTER AGENT ""
ENABLE SSL.
● Disable the SSL by setting framework.enableSSL=false. Restart the agent, then run ALTER AGENT ""
DISABLE SSL. Check whether the communication is working. If it is working, then the input might not have
been correct.

Installation and Configuration Guide


Security PUBLIC 517
● To restart from the beginning, remove the ssl/cacerts and rename cacerts.bak to cacerts. Remove
all *.cer and *.pem files. Similarly, on the SAP HANA side, remove the sapcli.pse file and all *.cer and
*.pem files and perform the setup again.
● If you get a “Cipher suite not found” error, or something similar, be sure to upate the JCE policy files. See
Update JCE Policy Files for Stronger Encryption [page 518] for more information.

7.3 Update JCE Policy Files for Stronger Encryption

If you require stronger encryption for Kerberos or TLS/SSL implementations, you may need to update the
existing Java Cryptography Extension (JCE) policy files.

Context

Some TLS/SSL implementations, such as the connections between the Data Provisioning Agent and SAP
HANA and other remote sources, and Kerberos implementations require stronger encryption than what the
SAP JVM provides. If you require more than 128-bit key length encryption, update your JCE policy files to the
latest Oracle JCE policy files, which you can find on the Oracle download Web site.

Procedure

1. Navigate to <DPAgent_root>/sapjvm/lib/security, and backup the local_policy.jar and


US_export_policy.jar files before you update the files, in case you need to restore the Data
Provisioning Agent to its original state.
2. Download the latest Oracle JCE library ZIP file.
3. Unzip the downloaded ZIP file, and copy the local_policy.jar and US_export_policy.jar files to
<DPAgent_root>/sapjvm/lib/security.
4. Restart the Data Provisioning Agent.

Related Information

Authentication [page 497]

Installation and Configuration Guide


518 PUBLIC Security
7.4 Authorizations

SAP HANA smart data integration adds entities that are stored as catalog objects in the SAP HANA database.

Catalog objects such as adapters and remote subscriptions follow standard SAP HANA database security
concepts. That is, they follow standard processes for metadata management, system views, public views,
authorizations, and so on.

In addition to the privileges supported by the GRANT statement in the SAP HANA SQL and System Views
Reference, the following privileges are relevant to SAP HANA smart data integration and its associated catalog
objects:

System Privileges

System Privilege Privilege Purpose

ADAPTER ADMIN Controls the execution of the following adapter-related commands: CREATE
ADAPTER, DROP ADAPTER and ALTER ADAPTER. Also allows access to ADAPT­
ERS and ADAPTER_LOCATIONS system views.

AGENT ADMIN Controls the execution of the following agent-related commands: CREATE
AGENT, DROP AGENT and ALTER AGENT. Also allows access to AGENTS and
ADAPTER_LOCATIONS system views.

Source Privileges

Source Privilege Privilege Purpose

CREATE REMOTE SUBSCRIPTION This privilege allows the creation of remote subscriptions executed on this source
entry. Remote subscriptions are created in a schema and point to a virtual table
or SQL on tables to capture change data.

PROCESS REMOTE SUBSCRIPTION This privilege allows processing exceptions on this source entry. Exceptions that
EXCEPTION are relevant for all remote subscriptions are created for a remote source entry.

Object Privileges

Object Privilege Privilege Purpose Command Types

AGENT MESSAGING Authorizes the user with which the agent communicates DDL
with the data provisioning server using HTTP protocol.

PROCESS REMOTE SUB­ Authorizes processing exceptions of a remote subscription. DDL


SCRIPTION EXCEPTION

Installation and Configuration Guide


Security PUBLIC 519
Related Information

Activating and Executing Task Flowgraphs and Replication Tasks [page 520]
SAP HANA Security Guide
SAP HANA SQL and System Views Reference

7.4.1 Activating and Executing Task Flowgraphs and


Replication Tasks

_SYS_REPO requires additional object or schema authorizations to activate and execute objects such as task
flowgraphs and replication tasks.

To activate and execute these objects, _SYS_REPO requires the following authorizations:

● For any input sources: SELECT


● For any output sources: INSERT, UPDATE, and DELETE
● For any stored procedures or Application Function Library: EXECUTE
● For any sequences: SELECT

For example, the following statement grants all necessary authorizations to _SYS_REPO on a specific schema:

GRANT SELECT, INSERT, UPDATE, DELETE, EXECUTE


ON SCHEMA "<schema_name>" TO _SYS_REPO WITH GRANT OPTION;

Related Information

Assign Roles and Privileges [page 25]

7.5 Communication Channel Security

Communication channel security between SAP HANA and adapters hosted by the Data Provisioning Agent
depends on the SAP HANA deployment.

Additional components added to SAP HANA landscape by SAP HANA Smart Data Integration and SAP HANA
smart data quality require security considerations in addition to the information described in the SAP HANA
Security Guide.

Installation and Configuration Guide


520 PUBLIC Security
SAP HANA On-Premise

When SAP HANA and the Data Provisioning Agent are both installed on-premise, or locally in relation to each
other, communication is performed using TCP/IP encrypted with SSL.

The Data Provisioning Server connects to a port listened to by the agent. The agent generates a key pair and
stores its public certificate in SAP HANA. The Data Provisioning Server then uses this public certificate to
perform SSL server authentication when connecting to the agent.

 Caution

Passwords for remote systems accessed by adapters are sent in plain text over this communication
channel. Therefore, encryption is mandatory.

SAP HANA in the Cloud

When SAP HANA is in the cloud, or a firewall exists between SAP HANA and the Data Provisioning Agent, the
agent connects to SAP HANA using a proxy XS application. The proxy performs authentication and
authorization before passing messages to or from the Data Provisioning Server.

The agent can connect using the user name and password scheme supported by SAP HANA XS applications.

Related Information

SAP HANA Security Guide


Architecture [page 12]
Configure SSL for SAP HANA On-Premise [Command Line Batch] [page 509]

7.6 Auditing Activity on SAP HANA Smart Data Integration


Objects

Auditing provides you with visibility on who did what in the SAP HANA database (or tried to do what) and when.

Actions performed on SAP HANA smart data integration objects can be audited using the standard auditing
tools and processes described in the SAP HANA Security Guide.

In addition to the audit actions listed in the SAP HANA SQL and System Views Reference, the following audit
actions are available:

Audit Action Name Group Number Audit Operation

CREATE AGENT 17 Registering a Data Provisioning Agent

Installation and Configuration Guide


Security PUBLIC 521
Audit Action Name Group Number Audit Operation

ALTER AGENT 17 Altering a Data Provisioning Agent's


registration

DROP AGENT 17 Dropping a Data Provisioning Agent


registration

CREATE ADAPTER 17 Registering a Data Provisioning Adapter

ALTER ADAPTER 17 Altering the registration of a Data Provi­


sioning Adapter

DROP ADAPTER 17 Dropping the registration of a Data Pro­


visioning Adapter

CREATE REMOTE SUBSCRIPTION 17 Creating a subscription to a remote


source

ALTER REMOTE SUBSCRIPTION 17 Altering a subscription to a remote


source

DROP REMOTE SUBSCRIPTION 17 Dropping a subscription to a remote


source

PROCESS REMOTE SUBSCRIPTION 17 Processing exceptions raised by a sub­


EXCEPTION scribed remote source

Related Information

SAP HANA Security Guide


SAP HANA SQL and System Views Reference

7.7 Data Protection and Privacy in SAP HANA Smart Data


Integration and SAP HANA Smart Data Quality

SAP HANA provides the technical enablement and infrastructure to allow you to run applications on SAP HANA
to conform to the legal requirements of data protection in the different scenarios in which SAP HANA is used.

SAP HANA smart data integration and SAP HANA smart data quality are applications based on SAP HANA, and
they rely on SAP HANA as the platform for security and data protection. For information about how SAP HANA
provides and enables data protection, see the SAP HANA Security Guide.

Related Information

Data Protection and Privacy in SAP HANA

Installation and Configuration Guide


522 PUBLIC Security
8 SQL and System Views Reference for
Smart Data Integration and Smart Data
Quality

This section contains information about SQL syntax and system views that can be used in SAP HANA smart
data integration and SAP HANA smart data quality.

For complete information about all SQL statements and system views for SAP HANA and other SAP HANA
contexts, see the SAP HANA SQL and System Views Reference.

For information about the capabilities available for your license and installation scenario,refer to the Feature
Scope Description (FSD) for your specific SAP HANA version on the SAP HANA Platform page.

SQL Statements [page 523]


SAP HANA smart data integration and SAP HANA smart data quality support many SQL statements to
allow you to do such tasks as create agents and adapters, administer your system, and so on.

System Views [page 561]


System views allow you to query for various information about the system state using SQL commands.
The results appear as tables.

Related Information

SAP HANA SQL and System Views Reference

8.1 SQL Statements

SAP HANA smart data integration and SAP HANA smart data quality support many SQL statements to allow
you to do such tasks as create agents and adapters, administer your system, and so on.

ALTER ADAPTER Statement [Smart Data Integration] [page 525]


The ALTER ADAPTER statement alters an adapter. Refer to CREATE ADAPTER for a description of the
AT LOCATION clause.

ALTER AGENT Statement [Smart Data Integration] [page 527]


The ALTER AGENT statement changes an agent's host name and/or port and SSL property if it uses
the TCP protocol. It can also assign an agent to an agent group.

ALTER REMOTE SOURCE Statement [Smart Data Integration] [page 528]


The ALTER REMOTE SOURCE statement modifies the configuration of an external data source
connected to the SAP HANA database.

ALTER REMOTE SUBSCRIPTION Statement [Smart Data Integration] [page 532]

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 523
The ALTER REMOTE SUBSCRIPTION statement allows the QUEUE command to initiate real-time data
processing, and the DISTRIBUTE command applies the changes.

CANCEL TASK Statement [Smart Data Integration] [page 533]


Cancels a task that was started with START TASK.

CREATE ADAPTER Statement [Smart Data Integration] [page 535]


The CREATE ADAPTER statement creates an adapter that is deployed at the specified location.

CREATE AGENT Statement [Smart Data Integration] [page 537]


The CREATE AGENT statement registers connection properties of an agent that is installed on another
host.

CREATE AGENT GROUP Statement [Smart Data Integration] [page 539]


The CREATE AGENT GROUP statement creates an agent clustering group to which individual agents
can be assigned.

CREATE AUDIT POLICY Statement [Smart Data Integration] [page 540]


The CREATE AUDIT POLICY statement creates a new audit policy, which can then be enabled and
cause the specified audit actions to occur.

CREATE REMOTE SOURCE Statement [Smart Data Integration] [page 542]


The CREATE REMOTE SOURCE statement defines an external data source connected to SAP HANA
database.

CREATE REMOTE SUBSCRIPTION Statement [Smart Data Integration] [page 543]


The CREATE REMOTE SUBSCRIPTION statement creates a remote subscription in SAP HANA to
capture changes specified on the entire virtual table or part of a virtual table using a subquery.

CREATE VIRTUAL PROCEDURE Statement [Smart Data Integration] [page 548]


Creates a virtual procedure using the specified programming language that allows execution of the
procedure body at the specified remote source.

DROP ADAPTER Statement [Smart Data Integration] [page 550]


The DROP ADAPTER statement removes an adapter from all locations.

DROP AGENT Statement [Smart Data Integration] [page 551]


The DROP AGENT statement removes an agent.

DROP AGENT GROUP Statement [Smart Data Integration] [page 552]


The DROP AGENT GROUP statement removes an agent clustering group.

DROP REMOTE SUBSCRIPTION Statement [Smart Data Integration] [page 553]


The DROP REMOTE SUBSCRIPTION statement drops an existing remote subscription.

GRANT Statement [Smart Data Integration] [page 554]


GRANT is used to grant privileges and structured privileges to users and roles. GRANT is also used to
grant roles to users and other roles.

PROCESS REMOTE SUBSCRIPTION EXCEPTION Statement [Smart Data Integration] [page 556]
The PROCESS REMOTE SUBSCRIPTION EXCEPTION statement allows the user to indicate how an
exception should be processed.

SESSION_CONTEXT Function [Smart Data Integration] [page 557]


Returns the value of session_variable assigned to the current user.

START TASK Statement [Smart Data Integration] [page 558]


Starts a task.

Installation and Configuration Guide


524 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Related Information

SQL Reference for Additional SAP HANA Contexts (SAP HANA SQL and System Views Reference)

8.1.1 ALTER ADAPTER Statement [Smart Data Integration]

The ALTER ADAPTER statement alters an adapter. Refer to CREATE ADAPTER for a description of the AT
LOCATION clause.

Syntax

ALTER ADAPTER <adapter_name> [PROPERTIES <properties>]


| {ADD | REMOVE} LOCATION {DPSERVER | AGENT <agent_name>}
| REFRESH AT LOCATION {DPSERVER | AGENT <agent_name>}

Syntax Elements

<adapter_name>

The name of the adapter to be altered.

<adapter_name> ::= <identifier>

<agent_name>

The agent name if the adapter is set up on the agent.

<agent_name> ::= <identifier>

<properties>

The optional properties of the adapter, such as display_name. If display_name is not


specified, then adapter_name appears in the user interface.

<properties> ::= <string_literal>

Description

The ALTER ADAPTER statement alters an adapter. Refer to CREATE ADAPTER for a description of the AT
LOCATION clause.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 525
Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

System privilege: ADAPTER ADMIN

Examples

Add or remove an Create two agents and an adapter at the first agent:
existing adapter at agent
or Data Provisioning CREATE AGENT TEST_AGENT_1 PROTOCOL 'TCP' HOST 'test_host1'
Server PORT 5050;
CREATE AGENT TEST_AGENT_2 PROTOCOL 'HTTP';
CREATE ADAPTER TEST_ADAPTER AT LOCATION AGENT TEST_AGENT_1;

Add an existing adapter TEST_ADAPTER to agent TEST_AGENT_2:

ALTER ADAPTER TEST_ADAPTER ADD LOCATION AGENT TEST_AGENT_2;

Remove an existing adapter TEST_ADAPTER from agent TEST_AGENT_2:

ALTER ADAPTER TEST_ADAPTER REMOVE LOCATION AGENT


TEST_AGENT_2;

Add an existing adapter TEST_ADAPTER at the Data Provisioning Server:

ALTER ADAPTER TEST_ADAPTER ADD LOCATION DPSERVER;

Remove an existing adapter TEST_ADAPTER at Data Provisioning Server:

ALTER ADAPTER TEST_ADAPTER REMOVE LOCATION DPSERVER;

Refresh configuration Read configuration and query optimization capabilities of an adapter from the
and query optimization adapter setup at the agent or Data Provisioning Server:
capabilities of an adapter
ALTER ADAPTER TEST_ADAPTER REFRESH AT LOCATION DPSERVER;
ALTER ADAPTER TEST_ADAPTER REFRESH AT LOCATION AGENT
TEST_AGENT_2;

Update display name Change display name for an adapter to 'My Custom Adapter':
property of an adapter
ALTER ADAPTER TEST_ADAPTER PROPERTIES 'display_name=My
Custom Adapter';

Installation and Configuration Guide


526 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
8.1.2 ALTER AGENT Statement [Smart Data Integration]

The ALTER AGENT statement changes an agent's host name and/or port and SSL property if it uses the TCP
protocol. It can also assign an agent to an agent group.

Syntax

ALTER AGENT <agent_name>


HOST <agent_hostname> [ PORT <agent_port_number> ] [ { ENABLE | DISABLE } SSL ]
| PORT <agent_port_number> [ {ENABLE | DISABLE} SSL ]
| [ {ENABLE | DISABLE} SSL ]
| { SET | UNSET } AGENT GROUP <agent_group_name>

Syntax Elements

<agent_name>

The name of the agent to be altered.

<agent_name> ::= <identifier>

<agent_hostname>

The name of the agent host.

<agent_hostname> ::= <string_literal>

<agent_port_number>

Specifies whether the agent's TCP listener on the specified port uses SSL.

<agent_port_number> ::= <integer_literal> {ENABLE | DISABLE}


SSL

<agent_group_name>

The name of the agent clustering group to which the agent should be attached.

<agent_group_name> ::= <identifier>

Description

The ALTER AGENT statement changes an agent's host name and/or port if it uses the TCP protocol. It can also
assign an agent to an agent group.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 527
Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::AlterAgent

System privilege: AGENT ADMIN

Examples

● Alter TEST_AGENT's hostname test_host and port to 5051, if it uses 'TCP' protocol

ALTER AGENT TEST_AGENT HOST 'test_host' PORT 5051;

● Alter TEST_AGENT's hostname test_host, if it uses 'TCP' protocol

ALTER AGENT TEST_AGENT HOST 'test_host';

● Alter TEST_AGENT's port to 5051, if it uses 'TCP' protocol

ALTER AGENT TEST_AGENT PORT 5051;

● Assign TEST_AGENT to agent group TEST_GROUP

ALTER AGENT TEST_AGENT SET AGENT GROUP TEST_GROUP;

● Remove TEST_AGENT from agent group TEST_GROUP

ALTER AGENT TEST_AGENT UNSET AGENT GROUP TEST_GROUP;

8.1.3 ALTER REMOTE SOURCE Statement [Smart Data


Integration]

The ALTER REMOTE SOURCE statement modifies the configuration of an external data source connected to
the SAP HANA database.

The ALTER REMOTE SOURCE SQL statement is available for use in other areas of SAP HANA, not only SAP
HANA smart data integration. Refer to the ALTER REMOTE SOURCE topic for complete information. This
information is specific to smart data integration functionality.

Syntax

ALTER REMOTE SOURCE <remote_source_name> <adapter_clause> [<credential_clause>]


| { SUSPEND | RESUME } { CAPTURE | DISTRIBUTION }
| { CLEAR OBJECTS | REFRESH OBJECTS | CANCEL REFRESH OBJECTS }
| START LATENCY MONITORING <latency_ticket_name> [ INTERVAL
<interval_in_seconds> ]

Installation and Configuration Guide


528 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
| STOP LATENCY MONITORING <latency_ticket_name>
| CLEAR LATENCY HISTORY [ <latency_ticket_name> ]

Syntax Elements

Syntax elements specific to smart data integration are described as follows. For information about syntax
elements that aren’t specific to smart data integration, refer to the ALTER REMOTE SOURCE topic.

<adapter_clause>

Adapter configuration.

<adapter_clause> ::= [ADAPTER <adapter_name>


[AT LOCATION { DPSERVER | AGENT <agent_name> | AGENT GROUP
<agent_group_name>}] <configuration_clause>]

<agent_name> ::= <identifier>


<agent_group_name> ::= <identifier>

<configuration_clause> ::= CONFIGURATION


'<configuration_xml_string>'

The <configuration_xml_string> is the XML-formatted configuration string for


the remote source.

Refer to CREATE ADAPTER for a description of the AT LOCATION clause.


{ SUSPEND | RESUME } { CAPTURE | DISTRIBUTION }

ALTER REMOTE SOURCE SUSPEND Suspends the adapter and agent from
CAPTURE reading any more changes from source
system. This is helpful when the source
system or SAP HANA is preparing for
planned maintenance or an upgrade.

ALTER REMOTE SOURCE Resumes the suspended adapter to read


<remote_source_name> RESUME changed data from source system.
CAPTURE

ALTER REMOTE SOURCE Suspends the application of real-time


<remote_source_name> SUSPEND changes in SAP HANA tables but collects
DISTRIBUTION changed data from the source system.

ALTER REMOTE SOURCE Resumes applying real-time changes in SAP


<remote_source_name> RESUME HANA tables.
DISTRIBUTION

{ CLEAR OBJECTS | REFRESH OBJECTS | CANCEL REFRESH OBJECTS }

ALTER REMOTE SOURCE Clears all the data received from the adapter
<remote_source_name> CLEAR for this remote source from HANA tables.
OBJECTS

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 529
ALTER REMOTE SOURCE Starts building HANA dictionary tables that
<remote_source_name> REFRESH contain remote source objects.
OBJECTS

ALTER REMOTE SOURCE Cancels the long-running REFRESH


<remote_source_name> CANCEL background operation. This stops fetching
REFRESH OBJECTS records from the adapter but keeps the data
received so far form the remote source on
HANA tables.

ALTER REMOTE SOURCE <remote_source_name> START LATENCY MONITORING <ticket_name>

Starts the collection of latency statistics one time or at regular intervals. The user
specifies a target latency ticket in the monitoring view.
ALTER REMOTE SOURCE <remote_source_name> STOP LATENCY MONITORING <ticket_name>

Stops the collection of latency statistics into the given latency ticket.
ALTER REMOTE SOURCE <remote_source_name> CLEAR LATENCY HISTORY

Clears the latency statistics (for either one latency ticket, or for the whole remote
source, from the monitoring view.

Description

The ALTER REMOTE SOURCE statement modifies the configuration of an external data source connected to
the SAP HANA database. Only database users with the object privilege ALTER for remote sources may alter
remote sources.

 Note

You may not change a user name while a remote source is suspended.

Permissions

This statement requires the ALTER object privilege on the remote source.

Examples

ALTER REMOTE SOURCE "odata_nw" ADAPTER "ODataAdapter"


AT LOCATION DPSERVER
CONFIGURATION '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ConnectionProperties name="connection_properties">
<PropertyEntry name="URL">http://services.odata.org/Northwind/Northwind.svc/</
PropertyEntry>
<PropertyEntry name="proxyserver">proxy</PropertyEntry>

Installation and Configuration Guide


530 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
<PropertyEntry name="proxyport">8080</PropertyEntry> <PropertyEntry
name="truststore"></PropertyEntry>
<PropertyEntry name="supportformatquery"></PropertyEntry>
</ConnectionProperties>' WITH CREDENTIAL TYPE 'PASSWORD'
USING '<CredentialEntry name="password"><user></user><password></password></
CredentialEntry>';

The configuration clause must be a structured XML string that defines the settings for the remote source. For
example, the CONFIGURATION string in the following example configures a remote source for an Oracle
database.

CONFIGURATION '<?xml version="1.0" encoding="UTF-8"?>


<ConnectionProperties name="configurations">
<PropertyGroup name="generic">
<PropertyEntry name="instance_name">ora_inst</PropertyEntry>
<PropertyEntry name="admin_port">12345</PropertyEntry>
<PropertyEntry name="map_char_types_to_unicode">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="database">
<PropertyEntry name="cdb_enabled">false</PropertyEntry>
<PropertyEntry name="pds_use_tnsnames">false</PropertyEntry>
<PropertyEntry name="pds_host_name"><db_hostname></PropertyEntry>
<PropertyEntry name="pds_port_number">1521</PropertyEntry>
<PropertyEntry name="pds_database_name">ORCL</PropertyEntry>
<PropertyEntry name="cdb_service_name"></PropertyEntry>
<PropertyEntry name="pds_service_name"></PropertyEntry>
<PropertyEntry name="pds_tns_filename"></PropertyEntry>
<PropertyEntry name="pds_tns_connection"></PropertyEntry>
<PropertyEntry name="cdb_tns_connection"></PropertyEntry>
<PropertyEntry name="_pds_tns_connection_with_cdb_enabled"></
PropertyEntry>
<PropertyEntry name="pds_byte_order"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="schema_alias_replacements">
<PropertyEntry name="schema_alias"></PropertyEntry>
<PropertyEntry name="schema_alias_replacement"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="security">
<PropertyEntry name="pds_use_ssl">false</PropertyEntry>
<PropertyEntry name="pds_ssl_sc_dn"></PropertyEntry>
<PropertyEntry name="_enable_ssl_client_auth">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="jdbc_flags">
<PropertyEntry name="remarksReporting">false</PropertyEntry>
</PropertyGroup>
<PropertyGroup name="cdc">
<PropertyGroup name="databaseconf">
<PropertyEntry name="pdb_timezone_file"><timezone_file></
PropertyEntry>
<PropertyEntry name="pdb_archive_path"></PropertyEntry>
<PropertyEntry name="pdb_supplemental_logging_level">table</
PropertyEntry>
</PropertyGroup>
<PropertyGroup name="parallelscan">
<PropertyEntry name="lr_parallel_scan">false</PropertyEntry>
<PropertyEntry name="lr_parallel_scanner_count"></PropertyEntry>
<PropertyEntry name="lr_parallel_scan_queue_size"></
PropertyEntry>
<PropertyEntry name="lr_parallel_scan_range"></PropertyEntry>
</PropertyGroup>
<PropertyGroup name="logreader">
<PropertyEntry name="skip_lr_errors">false</PropertyEntry>
<PropertyEntry name="lr_max_op_queue_size">1000</PropertyEntry>
<PropertyEntry name="lr_max_scan_queue_size">1000</PropertyEntry>
<PropertyEntry name="lr_max_session_cache_size">1000</
PropertyEntry>
<PropertyEntry name="scan_fetch_size">10</PropertyEntry>

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 531
<PropertyEntry name="pdb_dflt_column_repl">true</PropertyEntry>
<PropertyEntry name="pdb_ignore_unsupported_anydata">false</
PropertyEntry>
<PropertyEntry name="pds_sql_connection_pool_size">15</
PropertyEntry>
<PropertyEntry name="pds_retry_count">5</PropertyEntry>
<PropertyEntry name="pds_retry_timeout">10</PropertyEntry>
</PropertyGroup>
</PropertyGroup>
</ConnectionProperties>'

Related Information

ALTER REMOTE SOURCE Statement (Access Control) (SAP HANA SQL and System Views Reference)

8.1.4 ALTER REMOTE SUBSCRIPTION Statement [Smart


Data Integration]

The ALTER REMOTE SUBSCRIPTION statement allows the QUEUE command to initiate real-time data
processing, and the DISTRIBUTE command applies the changes.

Syntax

ALTER REMOTE SUBSCRIPTION [<schema_name>.]<subscription_name>


{ QUEUE | DISTRIBUTE | RESET }

Syntax Elements

<subscription_name>

The name of the remote subscription.

<subscription_name> ::= <identifier>

Description

The ALTER REMOTE SUBSCRIPTION statement allows the QUEUE command to initiate real-time data
processing, and the DISTRIBUTE command applies the changes. Typically, the initial load of data is preceded
by QUEUE command. The DISTRIBUTE command is used when initial load completes. The RESET command
can be used to reset the real-time process to start from the initial load again.

Installation and Configuration Guide


532 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Permissions

This statement requires the ALTER object privilege on the remote source.

Example

Capture changes from a virtual table to an SAP HANA table.

CREATE AGENT TEST_AGENT PROTOCOL 'TCP' HOST 'test_host1' PORT 5050;


CREATE ADAPTER 'DB2ECCAdapter' AT LOCATION AGENT TEST_AGENT;
CREATE REMOTE SOURCE MYECC ADAPTER 'DB2ECCAdapter' CONFIGURATION
'<configuration_xml>' AT LOCATION AGENT TEST_AGENT;
CREATE VIRTUAL TABLE MARA_VT AT MYECC."<NULL>"."<NULL>".MARA;
CREATE COLUMN TABLE TGT_MARA LIKE MARA_VT;
CREATE REMOTE SUBSCRIPTION TEST_SUB ON MARA_VT TARGET TABLE TGT_MARA;
ALTER REMOTE SUBSCRIPTION TEST_SUB QUEUE;

Perform initial load of data using INSERT-SELECT or a TASK.

INSERT INTO TGT_MARA SELECT * FROM MARA_VT;


ALTER REMOTE SUBSCRIPTION TEST_SUB DISTRIBUTE;

Now insert or update a material record in ECC system and see it updated to TGT_MARA table in SAP HANA.
Reset the real-time process and restart the load.

ALTER REMOTE SUBSCRIPTION TEST_SUB RESET;


ALTER REMOTE SUBSCRIPTION TEST_SUB QUEUE;

Perform initial load of data using INSERT-SELECT or a TASK.

INSERT INTO TGT_MARA SELECT * FROM MARA_VT;


ALTER REMOTE SUBSCRIPTION TEST_SUB DISTRIBUTE;

8.1.5 CANCEL TASK Statement [Smart Data Integration]

Cancels a task that was started with START TASK.

Syntax

CANCEL TASK <task_execution_id> [WAIT <wait_time_in_seconds>]

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 533
Syntax Elements

<task_execution_id> ::= <unsigned_integer>

Specifies the task execution ID to cancel. See the START TASK topic for more information about
TASK_EXECUTION_ID.

<wait_time_in_seconds> ::= <identifier>

Number of seconds to wait for the task to cancel before returning from the command.

Description

Cancels a task that was started with START TASK.

The default behavior is for the CANCEL TASK command to return after sending the cancel request. Optionally,
a WAIT value can be specified where the command will wait for the task to actually cancel before returning. If
the command has waited the specified amount of time, then the CANCEL TASK will error out with the error
code 526 (request to cancel task was sent but task did not cancel before timeout was reached).

 Note

If the WAIT value is 0, the command returns immediately after sending the cancel request, as it would if no
WAIT value were entered.

Permissions

The user that called START TASK can implicitly CANCEL; otherwise, the CATALOG READ and SESSION ADMIN
roles are required.

Examples

Assuming that a TASK performTranslation was already started using START TASK and has a task execution ID
of 255, it would be cancelled using the following commands. The behavior is the same for the following two
cases:

CANCEL TASK 255;

CANCEL TASK 255 WAIT 0;

Installation and Configuration Guide


534 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Assuming that a TASK performTranslation was already started using START TASK and has a task execution id
of 256 and the user wants to wait up to 5 seconds for the command to cancel, it would be cancelled using the
following command:

CANCEL TASK 256 WAIT 5;

If the task was able to cancel within 5 seconds, the CANCEL TASK will return as a success. If it didn't cancel
within 5 seconds, then the return will be the error code 526.

SQL Script

You can call CANCEL TASK within the SQL Script CREATE PROCEDURE. Refer to the SAP HANA SQL Script
Reference for complete details about CREATE PROCEDURE.

CREATE PROCEDURE "CANCEL_TASK"."CANCEL_MY_TASK"(in exec_id INT)


LANGUAGE SQLSCRIPT AS
BEGIN
CANCEL TASK :exec_id;
END;

CANCEL TASK is not supported in:

● Table UDF
● Scalar UDF
● Trigger
● Read-only procedures

Related Information

START TASK Statement [Smart Data Integration] [page 558]

8.1.6 CREATE ADAPTER Statement [Smart Data Integration]

The CREATE ADAPTER statement creates an adapter that is deployed at the specified location.

Syntax

CREATE ADAPTER <adapter_name> [PROPERTIES <properties>] AT LOCATION


{DPSERVER | AGENT <agent_name>}

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 535
Syntax Elements

<adapter_name>

The name of the adapter to be created.

<adapter_name> ::= <identifier>

<agent_name>
The agent name if the adapter is set up on the agent.

<agent_name> ::= <identifier>

<properties>

The optional properties of the adapter, such as display_name. When display_name is


not specified, then adapter_name displays in the user interface.

<properties> ::= <string_literal>

AT LOCATION DPSERVER

The adapter runs inside the Data Provisioning Server process in SAP HANA.
AT LOCATION
Specify an agent that is set up outside of SAP HANA for the adapter to run inside.

AT LOCATION AGENT <agent_name>

Description

The CREATE ADAPTER statement creates an adapter that is deployed at the specified location. The adapter
must be set up on the location prior to running this statement. When the statement is executed, the Data
Provisioning Server contacts the adapter to retrieve its configuration details such as connection properties and
query optimization capabilities.

Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::AddLocationToAdapter

System privilege: ADAPTER ADMIN

Installation and Configuration Guide


536 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Examples

Create an adapter at the Data Create an adapter TEST_ADAPTER running in the Data Provisioning Server.
Provisioning Server
CREATE ADAPTER TEST_ADAPTER AT LOCATION DPSERVER;

Create an adapter at a specified Create an agent with name TEST_AGENT.


agent
CREATE AGENT TEST_AGENT PROTOCOL 'TCP' HOST
'test_host' PORT 5050;

Create an adapter TEST_ADAPTER on agent TEST_AGENT.

CREATE ADAPTER TEST_ADAPTER AT LOCATION AGENT


TEST_AGENT;

8.1.7 CREATE AGENT Statement [Smart Data Integration]

The CREATE AGENT statement registers connection properties of an agent that is installed on another host.

Syntax

CREATE AGENT <agent_name> PROTOCOL { 'HTTP' | 'TCP' HOST <agent_hostname> PORT


<agent_port_number> [{ENABLE | DISABLE} SSL]} [AGENT GROUP <agent_group_name>]

Syntax Elements

<agent_name>

The name of the agent to be created and its protocol.

<agent_name> ::= <identifier>

PROTOCOL
The protocol for the agent.

HTTP Agent uses HTTP protocol for communication with DP server. Use this
protocol when the SAP HANA database is on the cloud.

PROTOCOL 'HTTP'

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 537
TCP Agent uses TCP protocol and listens on the specified port to receive
requests from DP server. Use this protocol when the SAP HANA
database can connect to agent's TCP port.

PROTOCOL 'TCP' HOST <agent_hostname> PORT


<agent_port_number>

<agent_hostname> ::= <string_literal>


<agent_port_number> ::= <integer_literal>

DP server connects to the agent listening on the specified hostname


and port. Use this protocol when the SAP HANA database is on-
premise.

{ENABLE | Specifies if agent's TCP listener on the specified port uses SSL.
DISABLE}
SSL

<agent_group_name>

The name of the agent clustering group to which the agent should belong.

<agent_group_name> ::= <identifier>

Description

The CREATE AGENT statement registers connection properties of an agent that is installed on another host.
The DP server and agent use these connection properties when establishing communication channel.

Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::CreateAgent

System privilege: ADAPTER ADMIN

Examples

Create an agent with TCP Create an agent TEST_AGENT running on test_host and port 5050.
protocol
CREATE AGENT TEST_AGENT PROTOCOL 'TCP' HOST
'test_host' PORT 5050;

Installation and Configuration Guide


538 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Create an agent with HTTP Create an agent TEST_AGENT that uses HTTP.
protocol
CREATE AGENT TEST_AGENT PROTOCOL 'HTTP';

Create an agent with HTTP Create an agent TEST_AGENT that uses HTTP and belongs to agent
protocol in an agent group clustering group TEST_GROUP.

CREATE AGENT TEST_AGENT PROTOCOL 'HTTP' AGENT GROUP


TEST_GROUP;

8.1.8 CREATE AGENT GROUP Statement [Smart Data


Integration]

The CREATE AGENT GROUP statement creates an agent clustering group to which individual agents can be
assigned.

Syntax

CREATE AGENT GROUP <agent_group_name>

Syntax Elements

<agent_group_name>

The name of the agent group to create.

<agent_group_name> ::= <identifier>

Description

The CREATE AGENT GROUP statement creates an agent clustering group to which individual agents can be
assigned. An agent group can be used instead of a single agent to provide fail-over capabilities.

Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::CreateAgent

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 539
System privilege: ADAPTER ADMIN

Examples

Create an agent group named TEST_GROUP.

CREATE AGENT GROUP TEST_GROUP;

Related Information

ALTER AGENT Statement [Smart Data Integration] [page 527]


CREATE AGENT Statement [Smart Data Integration] [page 537]

8.1.9 CREATE AUDIT POLICY Statement [Smart Data


Integration]

The CREATE AUDIT POLICY statement creates a new audit policy, which can then be enabled and cause the
specified audit actions to occur.

The CREATE AUDIT POLICY SQL statement is available for use in other areas of SAP HANA, not only SAP
HANA smart data integration. Refer to the CREATE AUDIT POLICY topic for complete information. The
information below is specific to smart data integration functionality.

Syntax

Refer to the SAP HANA SQL and System Views Reference for complete information about CREATE AUDIT
POLICY syntax.

Syntax Elements

Syntax elements specific to smart data integration are described below. For information about syntax elements
that are not specific to smart data integration, refer to the SAP HANA SQL and System Views Reference.

<audit_action_name> ::= CREATE AGENT


| ALTER AGENT
| DROP AGENT
| CREATE AGENT GROUP
| DROP AGENT GROUP
| CREATE ADAPTER
| ALTER ADAPTER

Installation and Configuration Guide


540 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
| DROP ADAPTER
| CREATE REMOTE SUBSCRIPTION
| ALTER REMOTE SUBSCRIPTION
| DROP REMOTE SUBSCRIPTION
| PROCESS REMOTE SUBSCRIPTION EXCEPTION

Audit Action Name Group Number Audit Operation

CREATE AGENT 17 Registering a Data Provisioning Agent

ALTER AGENT 17 Altering a Data Provisioning Agent's


registration

DROP AGENT 17 Dropping a Data Provisioning Agent


registration

CREATE ADAPTER 17 Registering a Data Provisioning Adapter

ALTER ADAPTER 17 Altering the registration of a Data Provi­


sioning Adapter

DROP ADAPTER 17 Dropping the registration of a Data Pro­


visioning Adapter

CREATE REMOTE SUBSCRIPTION 17 Creating a subscription to a remote


source

ALTER REMOTE SUBSCRIPTION 17 Altering a subscription to a remote


source

DROP REMOTE SUBSCRIPTION 17 Dropping a subscription to a remote


source

PROCESS REMOTE SUBSCRIPTION 17 Processing exceptions raised by a sub­


EXCEPTION scribed remote source

Description

The CREATE AUDIT POLICY statement creates a new audit policy. This audit policy can then be enabled and
cause the auditing of the specified audit actions to occur.

Permissions

Only database users with the CATALOG READ or INIFILE ADMIN system privilege can view information in the
M_INIFILE_CONTENTS view. For other database users, this view is empty. Users with the AUDIT ADMIN
privilege can see audit-relevant parameters.

Related Information

CREATE AUDIT POLICY Statement (Access Control) (SAP HANA SQL and System Views Reference)

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 541
8.1.10 CREATE REMOTE SOURCE Statement [Smart Data
Integration]

The CREATE REMOTE SOURCE statement defines an external data source connected to SAP HANA database.

The CREATE REMOTE SOURCE SQL statement is available for use in other areas of SAP HANA, not only SAP
HANA smart data integration. Refer to the CREATE REMOTE SOURCE topic for complete information. The
information below is specific to smart data integration functionality.

Syntax

Refer to the SAP HANA SQL and System Views Reference for complete information about CREATE REMOTE
SOURCE syntax.

Syntax Elements

Syntax elements specific to smart data integration are described below. For information about syntax elements
that are not specific to smart data integration, refer to the SAP HANA SQL and System Views Reference.
<adapter_clause>
Configures the adapter.

<adapter_clause> ::= ADAPTER <adapter_name>


[AT LOCATION {DPSERVER | AGENT <agent_name> | AGENT GROUP
<agent_group_name>} ]
CONFIGURATION <connection_info_string>

<agent_name> ::= <identifier>


<agent_group_name> ::= <identifier>

Refer to CREATE ADAPTER for description of AT LOCATION.

Description

The CREATE REMOTE SOURCE statement defines an external data source connected to SAP HANA database.
Only database users having the system privilege CREATE SOURCE or DATA ADMIN are allowed to add a new
remote source.

Permissions

This statement requires the CREATE SOURCE system privilege.

Installation and Configuration Guide


542 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Related Information

CREATE REMOTE SOURCE Statement (Access Control) (SAP HANA SQL and System Views Reference)

8.1.11 CREATE REMOTE SUBSCRIPTION Statement [Smart


Data Integration]

The CREATE REMOTE SUBSCRIPTION statement creates a remote subscription in SAP HANA to capture
changes specified on the entire virtual table or part of a virtual table using a subquery.

Syntax

CREATE REMOTE SUBSCRIPTION [<schema_name>.]<subscription_name>


{
{ON [<schema_name>.]<virtual_table_name> } |
{AS (<subquery>)}
}
[ WITH [ RESTRICTED ] SCHEMA CHANGES ]
{ TARGET TABLE <table_spec> <load_behavior> } |
{ TARGET TASK <task_spec> } |
{ PROCEDURE <proc_spec> }

Syntax Elements

<subscription_name>

The name of the remote subscription.

<subscription_name> ::= <identifier>

ON [<schema_name>.]<virtual_table_name>
See "Remote subscription for TARGET TASK or TARGET TABLE using ON Clause"
below.
AS (<subquery>)
See "Remote subscription for TARGET TASK or TARGET TABLE using AS Clause"
below.
[WITH [RESTRICTED] SCHEMA CHANGES]
Include this clause to propagate source schema changes to the SAP HANA virtual table
and remote subscription target table.

WITH SCHEMA CHANGES corresponds to the replication task options Initial + realtime
with structure or Realtime only with structure and the flowgraph options Real-time and
with Schema Change.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 543
With the optional RESTRICTED clause, WITH RESTRICTED SCHEMA CHANGES
propagates source schema changes only to the SAP HANA virtual table, and not the
remote subscription target table.
<table_spec>
The table definition.

<table_spec> ::= [<schema_name>].<table_name>

<load_behavior>

[ CHANGE TYPE COLUMN <column_name> CHANGE TIME COLUMN


<column_name> CHANGE SEQUENCE COLUMN <column_name> { INSERT |
UPSERT } ]

CHANGE { TYPE | TIME | SEQUENCE } COLUMN <column_name>

For a target table that logs the loading history, these parameters specify the target
column names that will show the change type and corresponding timestamp for each
operation. The CHANGE TYPE COLUMN <column_name> displays I, U, or D for INSERT,
UPSERT, or DELETE. In the case when multiple operations of the same type occur on
the same source row with the same timestamp (because the operations are in the same
transaction), use the CHANGE SEQUENCE COLUMN <column_name>, which adds an
incremental digit to distinguish the operations.

The load behavior options are:

UPSERT: INSERT and UPDATE apply as is, DELETE converts to UPDATE

INSERT: INSERT applies as is, UPDATE and DELETE convert to INSERT

The following example is for UPSERT for a remote subscription called


user.subscription on a source table called SQLServer_dbo.table. The target
table user.table includes a column called CHANGE_TYPE (with a data type of
VARCHAR or NVARCHAR) and a column CHANGE_TIME (with a data type of
TIMESTAMP).

CREATE REMOTE SUBSCRIPTION user.subscription


ON "user"."SQLServer_dbo.table"
TARGET TABLE user.table
CHANGE TYPE COLUMN "CHANGE_TYPE"
CHANGE TIME COLUMN "CHANGE_TIME"
UPSERT;

The following example for INSERT is for the same remote subscription and includes the
CHANGE_TIME column.

CREATE REMOTE SUBSCRIPTION user.subscription


ON "user"."SQLServer_dbo.table"
TARGET TABLE user.table
CHANGE TYPE COLUMN "CHANGE_TYPE"
CHANGE TIME COLUMN "CHANGE_TIME"
CHANGE SEQUENCE COLUMN "CHANGE_SEQUENCE"
INSERT;

<task_spec>

Installation and Configuration Guide


544 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
The task definition.

<task_spec>::= TARGET TASK[ <schema_name>].<task_name>


[(<var_list>)]
[PROCEDURE PARAMETERS{<param_list>)]

<var_list> specifies one or more start task variables.

<var_list> ::= <start_task_var>[{, <start_task_var>}...]

<start_task_var> specifies the name and value for a start task variable.

<start_task_var> ::= <var_name> => <var_value>

<var_name> is the name of variable that was defined within the task plan.

Variable values provided in this section will be used at runtime (for example, when
executing the task using START TASK).

<var_name> ::= <identifier>

<var_value> is the value that should be used in place of the variable name specified
when executing the task.

<var_value> ::= <string_literal>

<param_list> specifies one or more start task parameters.

<param_list> ::= <start_task_param> [{, <start_task_param>}...]

<start_task_param> ::= <identifier>

If the task uses table types for input and/or output, then the task expects actual table,
virtual table, or view names at runtime. These actual tables, virtual tables, or view
names are specified as task parameters. Depending on the type of remote subscription
being created, the task parameters may or may not need actual table, virtual table, or
view names for specific parameters (see below for more details).
<proc_spec>

{ PROCEDURE [<schema_name>.]<proc_name>[(<param_list>)] }

Description

The CREATE REMOTE SUBSCRIPTION statement creates a remote subscription in SAP HANA to capture
changes specified on the entire virtual table or part of a virtual table using a subquery. The changed data can
be applied to an SAP HANA target table or passed to a TASK or PROCEDURE if the changes require
transformation. The owner of the remote subscription must have the following privileges:

● SELECT privilege on tables specified in the ON or AS <subquery> clauses


● INSERT, UPDATE, DELETE privileges on the target table

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 545
● EXECUTE privilege on the stored procedure
● START TASK privilege on the task

 Note

If you create a remote subscription using the CREATE REMOTE SUBSCRIPTION SQL statement, use
technical user for the Credentials Mode parameter when creating a remote source.

Permissions

This statement requires the CREATE REMOTE SUBSCRIPTION object privilege on the remote source.

Remote subscription for TARGET TASK or TARGET TABLE using ON Clause

CREATE REMOTE SUBSCRIPTION [<schema_name>.]<subscription_name>


ON [<schema_name>.]<virtual_table_name>
TARGET TASK [<schema_name>].<task_name>[(<var_list>)] [PROCEDURE
PARAMETERS(<param_list>)]

<param_list> must contain one of the parameters as [<schema_name>.]<virtual_table_name>. This


parameter must be the same schema and virtual table name as specified in the ON clause. Only one parameter
in <param_list> can be a virtual table.

Each parameter in <param_list> is used in comparing its columns with columns for the corresponding table
type defined in the task plan. Hence, the order of parameters in <param_list> must match the order of table
types defined in the task plan for input and output sources.

The task plan table type corresponding to the procedure parameter


[<schema_name>.]<virtual_table_name> must have the same columns (excluding _OP_CODE and
_COMMIT_TIMESTAMP). This table type must have _OP_CODE as the last but one column and
_COMMIT_TIMESTAMP as the last column.

Remote subscription for TARGET TASK or TARGET TABLE using AS Clause

CREATE REMOTE SUBSCRIPTION [<schema_name>.]<subscription_name>


AS <subquery>
TARGET TASK [<schema_name>].<task_name>[(<var_list>)] [PROCEDURE
PARAMETERS(<param_list>)]

The AS (<subquery>) part of the syntax lets you define the SQL and the columns to use for the subscription.
The subquery should be a simple SELECT <column_list> from <virtual_table> and should not contain a
WHERE clause. The <column_list> should match the target table schema in column order and name.

<param_list> must contain one of the parameters as table type and this table type (schema and name) must
be the same as the one defined in the task plan. This table type must also have the same columns as being

Installation and Configuration Guide


546 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
output by the subquery (excluding _OP_CODE and _COMMIT_TIMESTAMP). This table type must have
_OP_CODE as the last but one column and _COMMIT_TIMESTAMP as the last column. Only one parameter in
<param_list> can be a table type.

Each parameter in <param_list> is used in comparing its columns with columns for the corresponding table
type defined in the task plan. Hence the order of parameters in <param_list> must match the order of table
types defined in task plan for input and output sources.

Example

Create a remote subscription on a virtual table and apply changes using a real-time task.

CREATE SCHEMA "IM_SERVICES";


DROP REMOTE SOURCE "OracleAdapter" CASCADE;
CREATE REMOTE SOURCE "OracleAdapter" ADAPTER "OracleAdapter" AT LOCATION
dpserver CONFIGURATION '' WITH CREDENTIAL TYPE 'PASSWORD' USING '';
DROP TABLE "SYSTEM"."VT_EMPLOYEE_PK_TABLE";
CREATE VIRTUAL TABLE "SYSTEM"."VT_EMPLOYEE_PK_TABLE" AT
"OracleAdapter"."<NULL>"."<NULL>"."employee_pk_table";
DROP TYPE "IM_SERVICES"."TT_PARAM_IN";
DROP TYPE "IM_SERVICES"."TT_PARAM_OUT";
CREATE TYPE "IM_SERVICES"."TT_PARAM_IN" AS TABLE ("empno" integer, "deptid"
integer, "empname" VARCHAR(200), "salary" decimal(28,7), "bonus" double,
"_OP_CODE" VARCHAR(1),"_COMMIT_TIMESTAMP" SECONDDATE);
CREATE TYPE "IM_SERVICES"."TT_PARAM_OUT" AS TABLE ("empno" integer, "deptid"
integer, "empname" VARCHAR(200), "salary" decimal(28,7), "bonus" double);
DROP TABLE "IM_SERVICES"."T_OUT";
CREATE COLUMN TABLE "IM_SERVICES"."T_OUT" LIKE "IM_SERVICES"."TT_PARAM_OUT" ;
DROP TASK "IM_SERVICES"."TSKM_RT_VAR";
DROP REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR";
CREATE REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR"
AS (SELECT "empno","deptid","empname","salary","bonus" FROM
"SYSTEM"."VT_EMPLOYEE_PK_TABLE")
TARGET TASK "IM_SERVICES"."TSKM_RT_VAR" ("expr_var01_in1" => '100',
"expr_var02_in2" => 'upper(''walkerIN'')')
PROCEDURE PARAMETERS ( "IM_SERVICES"."TT_PARAM_IN", "IM_SERVICES"."T_OUT");
DROP REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR";
CREATE REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR"
ON "SYSTEM"."VT_EMPLOYEE_PK_TABLE"
TARGET TASK "IM_SERVICES"."TSKM_RT_VAR" ("expr_var01_in1" => '100',
"expr_var02_in2" => 'upper(''walkerIN'')')
PROCEDURE PARAMETERS ( "SYSTEM"."VT_EMPLOYEE_PK_TABLE", "IM_SERVICES"."T_OUT");
SELECT * FROM "SYS"."REMOTE_SUBSCRIPTIONS_";
TRUNCATE TABLE "IM_SERVICES"."T_OUT";
ALTER REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR" QUEUE;
ALTER REMOTE SUBSCRIPTION "IM_SERVICES"."RSUB_VAR" DISTRIBUTE;

Related Information

SQL Notation Conventions (SAP HANA SQL and System Views Reference)
Data Types (SAP HANA SQL and System Views Reference)

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 547
8.1.12 CREATE VIRTUAL PROCEDURE Statement [Smart
Data Integration]

Creates a virtual procedure using the specified programming language that allows execution of the procedure
body at the specified remote source.

The CREATE VIRTUAL PROCEDURE SQL statement is available for use in other areas of SAP HANA, not only
SAP HANA smart data integration. Refer to the CREATE VIRTUAL PROCEDURE Statement (Procedural) topic
for complete information. The information below is specific to smart data integration functionality.

Syntax

CONFIGURATION <configuration_json_string>

Syntax Elements

<configuration_json_string>

A JSON string that includes required source procedure parameters.

Description

The CREATE VIRTUAL PROCEDURE statement creates a new virtual procedure from a remote source
procedure. When creating a virtual procedure using the SQL Console:

1. Return the metadata of the source procedure [number, types, and configuration (JSON) string] by invoking
the built-in SAP HANA procedure:

"PUBLIC"."GET_REMOTE_SOURCE_FUNCTION_DEFINITION"
('<remote_source_name>','<remote_object_unique_name>',?,?,?);

2. Edit the CONFIGURATION JSON string to include the appropriate parameter values.

Permissions

This statement requires the CREATE VIRTUAL PROCEDURE object privilege on the remote source.

Installation and Configuration Guide


548 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Example

If you use the SQL Console to create a virtual procedure, the following example illustrates an ABAP adapter.

CREATE VIRTUAL PROCEDURE BAPI_BANK_GETLIST (


IN BANK_CTRY NVARCHAR(6) ,
IN MAX_ROWS INT,
OUT RETURN_TYPE NVARCHAR (2),
OUT RETURN_ID NVARCHAR (40),
OUT RETURN_NUMBER VARCHAR (6) ,
OUT RETURN_MESSAGE NVARCHAR (440) ,
OUT RETURN_LOG_NO NVARCHAR (40),
OUT RETURN_LOG_MSG_NO VARCHAR (12),
OUT RETURN_MESSAGE_V1 NVARCHAR (100) ,
OUT RETURN_MESSAGE_V2 NVARCHAR (100),
OUT RETURN_MESSAGE_V3 NVARCHAR (100) ,
OUT RETURN_MESSAGE_V4 NVARCHAR (100),
OUT RETURN_PARAMETER NVARCHAR (64),
OUT RETURN_ROW INTEGER,
OUT RETURN_FIELD NVARCHAR (60),
OUT RETURN_SYSTEM NVARCHAR (20),
IN BANK_LIST_IN TABLE (
BANK_CTRY NVARCHAR (6),
BANK_KEY NVARCHAR (30),
BANK_NAME NVARCHAR (120) ,
CITY NVARCHAR (70)
),
OUT BANK_LIST TABLE (
BANK_CTRY NVARCHAR (6) ,
BANK_KEY NVARCHAR (30) ,
BANK_NAME NVARCHAR (120) ,
CITY NVARCHAR (70)
)
) CONFIGURATION '
{
"__DP_UNIQUE_NAME__": "BAPI_BANK_GETLIST",
"__DP_VIRTUAL_PROCEDURE__": true
}' AT "QA1";

Then call the procedure as follows:

CALL bapi_bank_getlist('DE', 1000, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,


bank_list, ?);

[where "bank_list" is a table of type

TABLE (
BANK_CTRY NVARCHAR (6),
BANK_KEY NVARCHAR (30),
BANK_NAME NVARCHAR (120) ,
CITY NVARCHAR (70)
)

For more information about using the SQL Console, see the SAP HANA Administration Guide.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 549
8.1.13 DROP ADAPTER Statement [Smart Data Integration]

The DROP ADAPTER statement removes an adapter from all locations.

Syntax

DROP ADAPTER <adapter_name> [<drop_option>]

Syntax Elements

<adapter_name>

The name of the adapter to be dropped.

<adapter_name> ::= <identifier>

<drop_option>

When <drop_option> is not specified, a restrict drop will be performed.

<drop_option> ::= CASCADE | RESTRICT

CASCADE drops the adapter and dependent objects.

Description

The DROP ADAPTER statement removes an adapter from all locations.

Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::RemoveLocationFromAdapter

System privilege: ADAPTER ADMIN

Installation and Configuration Guide


550 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Example

Create two agents and an adapter at both the agents.

CREATE AGENT TEST_AGENT_1 PROTOCOL 'TCP' HOST 'test_host1' PORT 5050;


CREATE AGENT TEST_AGENT_2 PROTOCOL 'HTTP';
CREATE ADAPTER TEST_ADAPTER AT LOCATION AGENT TEST_AGENT_1;
ALTER ADAPTER TEST_ADAPTER ADD LOCATION AGENT TEST_AGENT_2;
--Drop adapter TEST_ADAPTER.
DROP ADAPTER TEST_ADAPTER;

8.1.14 DROP AGENT Statement [Smart Data Integration]

The DROP AGENT statement removes an agent.

Syntax

DROP AGENT <agent_name> [<drop_option>]

Syntax Elements

<agent_name>

The name of the agent to be dropped.

<agent_name> ::= <identifier>

<drop_option>

When <drop_option> is not specified, a restrict drop is performed.

<drop_option> ::= CASCADE | RESTRICT

CASCADE drops the agent and its dependent objects.

RESTRICT drops the agent only if it does not have any dependent objects.

Description

The DROP AGENT statement removes an agent.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 551
Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::DropAgent

System privilege: AGENT ADMIN

Example

Create an agent TEST_AGENT and adapter CUSTOM_ADAPTER on the agent. Make sure that the custom
adapter is setup on the agent.

CREATE AGENT TEST_AGENT PROTOCOL 'TCP' HOST 'test_host' PORT 5050;


CREATE ADAPTER CUSTOM_ADAPTER AT LOCATION AGENT TEST_AGENT;

Drop the agent called TEST_AGENT.

DROP AGENT TEST_AGENT;

8.1.15 DROP AGENT GROUP Statement [Smart Data


Integration]

The DROP AGENT GROUP statement removes an agent clustering group.

Syntax

DROP AGENT GROUP <agent_group_name>

Syntax Elements

<agent_group_name>

The name of the agent group to be dropped.

<agent_group_name> ::= <identifier>

Installation and Configuration Guide


552 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Description

The DROP AGENT GROUP statement removes an agent clustering group. All dependent objects must be
removed before an agent clustering group can be dropped.

Permissions

Role: sap.hana.im.dp.monitor.roles::Operations

Application privilege: sap.hana.im.dp.monitor::DropAgent

System privilege: AGENT ADMIN

Example

Create an agent group TEST_GROUP.

CREATE AGENT GROUP TEST_GROUP;

Drop the agent called TEST_GROUP.

DROP AGENT GROUP TEST_GROUP;

8.1.16 DROP REMOTE SUBSCRIPTION Statement [Smart


Data Integration]

The DROP REMOTE SUBSCRIPTION statement drops an existing remote subscription.

Syntax

DROP REMOTE SUBSCRIPTION [<schema_name>.]<subscription_name>

Syntax Elements

<subscription_name>

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 553
The name of the remote subscription.

<subscription_name> ::= <identifier>

Description

The DROP REMOTE SUBSCRIPTION statement drops an existing remote subscription. If the remote
subscription is actively receiving changes from source table, then a RESET command is automatically called
before dropping it.

Permissions

This statement requires the DROP object privilege on the remote source.

Example

Drop the remote subscription TEST_SUB.

DROP REMOTE SUBSCRIPTION TEST_SUB;

8.1.17 GRANT Statement [Smart Data Integration]

GRANT is used to grant privileges and structured privileges to users and roles. GRANT is also used to grant
roles to users and other roles.

The GRANT SQL statement is available for use in other areas of SAP HANA, not only SAP HANA smart data
integration. Refer to the GRANT topic for complete information. The information below is specific to smart data
integration functionality.

Syntax

Refer to the GRANT topic for complete information about GRANT syntax.

Installation and Configuration Guide


554 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Syntax Elements

Syntax elements specific to smart data integration are described below. For information about syntax elements
that are not specific to smart data integration, refer to the GRANT topic.
<system_privilege>

System privileges are used to restrict administrative tasks.

<system_privilege> ::= ADAPTER ADMIN | AGENT ADMIN

The table below describes the supported system privileges.

System Privilege Privilege Purpose

ADAPTER ADMIN Controls the execution of the following adapter-related com­


mands: CREATE ADAPTER, DROP ADAPTER and ALTER
ADAPTER. Also allows access to ADAPTERS and ADAPTER_LO­
CATIONS system views.

AGENT ADMIN Controls the execution of the following agent-related com­


mands: CREATE AGENT, DROP AGENT and ALTER AGENT. Also
allows access to AGENTS and ADAPTER_LOCATIONS system
views.

<source_privilege>

Source privileges are used to restrict the access and modifications of a source entry.

<source_privilege> ::= CREATE REMOTE SUBSCRIPTION | PROCESS


REMOTE SUBSCRIPTION EXCEPTION

Source Privilege Privilege Purpose

CREATE REMOTE SUBSCRIP­ This privilege allows the creation of remote subscriptions exe­
TION cuted on this source entry. Remote subscriptions are created in
a schema and point to a virtual table or SQL on tables to cap­
ture change data.

PROCESS REMOTE SUB­ This privilege allows processing exceptions on this source entry.
SCRIPTION EXCEPTION Exceptions that are relevant for all remote subscriptions are
created for a remote source entry.

<object_privilege>

Object privileges are used to restrict the access and modifications on database objects.
Database objects are tables, views, sequences, procedures, and so on.

<object_privilege> ::= AGENT MESSAGING | PROCESS REMOTE


SUBSCRIPTION EXCEPTION

The table below describes the supported object privileges.

Object Privilege Privilege Purpose Command Types

AGENT MESSAGING Authorizes the user with which the agent com­ DDL
municates with the data provisioning server us­
ing HTTP protocol.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 555
Object Privilege Privilege Purpose Command Types

PROCESS REMOTE Authorizes processing exceptions of a remote DDL


SUBSCRIPTION EX­ subscription.
CEPTION

Not all object privileges are applicable to all kinds of database objects. To learn which
object types allow which privilege to be used, see the table below.

Remote
Schem Function / Subscrip­
Privilege a Table View Sequence Procedure tion Agent

AGENT MESSAGING -- -- -- -- -- -- YES

PROCESS REMOTE -- -- -- -- -- YES --


SUBSCRIPTION EX­
CEPTION

Related Information

GRANT Statement (Access Control) (SAP HANA SQL and System Views Reference)

8.1.18 PROCESS REMOTE SUBSCRIPTION EXCEPTION


Statement [Smart Data Integration]

The PROCESS REMOTE SUBSCRIPTION EXCEPTION statement allows the user to indicate how an exception
should be processed.

Syntax

PROCESS REMOTE SUBSCRIPTION EXCEPTION <exception_id> { RETRY | IGNORE }

Syntax Elements

<exception_id>

The exception ID for remote subscription or remote source.

<exception_id> ::= <integer_literal>

RETRY Indicates to retry the current failed operation. If the failure is due to opening a
connection to a remote source, then the connection is established. If the failure

Installation and Configuration Guide


556 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
happens when applying changed data to a target table, then the RETRY operation
retries the transaction again on the target table.

IGNORE Indicates to ignore the current failure. If the failure happens when applying
changed data to a target table, then the IGNORE operation skips the current
transaction and proceeds with the next transaction. The exception is cleared.

Description

The PROCESS REMOTE SUBSCRIPTION EXCEPTION statement allows the user to indicate how an exception
should be processed.

Permissions

This statement requires the PROCESS REMOTE SUBSCRIPTION EXCEPTION object privilege on the remote
source.

Example

Ignore exception 101.

PROCESS REMOTE SUBSCRIPTION EXCEPTION 101 IGNORE;

8.1.19 SESSION_CONTEXT Function [Smart Data


Integration]

Returns the value of session_variable assigned to the current user.

SESSION_CONTEXT is available for use in other areas of SAP HANA, not only SAP HANA smart data
integration. Refer to the SESSION_CONTEXT topic for complete information. The information below is specific
to smart data integration functionality.

Syntax

SESSION_CONTEXT(<session_variable>)

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 557
Description

A predefined session variables that is set by the server and is read-only (cannot be SET or UNSET) is
‘TASK_EXECUTION_ID’.

Related Information

SESSION_CONTEXT Function (Miscellaneous) (SAP HANA SQL and System Views Reference)

8.1.20 START TASK Statement [Smart Data Integration]

Starts a task.

Syntax

START TASK <task_name> [ASYNC] [(<var_list>)] [PROCEDURE


PARAMETERS(<param_list>)]

Syntax Elements

<task_name>

The identifier of the task to be called, with optional schema name.

<task_name> ::= [<schema_name>.]<identifier>


<schema_name> ::= <identifier>

<var_list>

Specifies one or more start task variables. Variables passed to a task are scalar
constants. Scalar parameters are assumed to be NOT NULL.

<var_list> ::= <start_task_var>[{, <start_task_var>}...]

<start_task_var> Specifies the name and value for a start task variable. A task
can contain variables that allow for dynamic replacement of
task plan parameters. This section is where, at run time during

Installation and Configuration Guide


558 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
START TASK, the values that should be used for those variables
can be provided.

<start_task_var> ::= <var_name> =>


<var_value>

<var_name> Name of variable that was defined.

<var_name> ::= <identifier>

<var_value> Value that should be used in place of the variable name


specified when executing the task.

<var_value> ::= <string_literal>

<param_list>

Specifies one or more start task parameters.

<param_list> ::= <start_task_param>[{, <start_task_param>}...]

<start_task_param> ::= <identifier>

Task parameters. If the task uses table types for input and/or output, then those need
to be specified within this section. For more information about these data types, see
BNF Lowest Terms Representations and Data Types in the Notation topic.

Parameters are implicitly defined as either IN or OUT, as inferred from the task plan.
Arguments for IN parameters could be anything that satisfies the schema of the input
table type (for example, a table variable internal to the procedure, or a temporary
table). The actual value passed for tabular OUT parameters can be, for example, '?', a
physical table name, or a table variable defined inside the procedure.

Description

Starts a task.

START TASK when executed by the client the syntax behaves in a way consistent with the SQL standard
semantics, e.g. Java clients can call a procedure using a JDBC CallableStatement. Scalar output variables are a
scalar value that can be retrieved from the callable statement directly.

 Note

Unquoted identifiers are implicitly treated as uppercase. Quoting identifiers will respect capitalization and
allow for using white spaces which are normally not allowed in SQL identifiers.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 559
Permissions

This statement requires the EXECUTE privilege on the schema in which the task was created.

Examples

The TASK performTranslation was already created, and the task plan has two table type input parameters and a
single table type output parameter. You call the performTranslation task passing in the table types to use for
execution.

START TASK performTranslation PROCEDURE PARAMETERS (in1, in2, out1);

SQL Script

You can call START TASK within the SQL Script CREATE PROCEDURE. Refer to the SAP HANA SQL Script
Reference for complete details about CREATE PROCEDURE.

<proc_sql> now includes <start_task>:

<proc_sql> ::= <subquery>


| <select_into_stmt>
| <insert_stmt>
| <delete_stmt>
| <update_stmt>
| <replace_stmt>
| <call_stmt>
| <create_table>
| <drop_table>
| <start_task>

START TASK is not supported in:

● Table UDF
● Scalar UDF
● Trigger
● Read-only procedures

TASK_EXECUTION_ID session variable

The TASK_EXECUTION_ID session variable provides a unique task execution ID. Knowing the proper task
execution ID is critical for various pieces of task functionality including querying for side-effect information and
task processing status, and canceling a task.

TASK_EXECUTION_ID is a read-only session variable. Only the internal start task code updates the value.

The value of TASK_EXECUTION_ID will be set during the START TASK command execution. In the case of
asynchronous execution (START TASK ASYNC), the value is updated before the command returns so it is

Installation and Configuration Guide


560 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
available before the actual task has finished asynchronously running. If the execution of START TASK was
successful, then the value is updated to the unique execution ID for that START TASK execution. If the
execution of START TASK was unsuccessful, then the TASK_EXECUTION_ID variable will be set back to the
state as if no START TASK was run.

The users can obtain the value of TASK_EXECUTION_ID by using either of the following:

● The already existing SESSION_CONTEXT() function. If this function is used and if no tasks have been run
or a task was run and it was unsuccessful, then a NULL value will be returned.
● The M_SESSION_CONTEXT monitoring view. This would need to be queried using a KEY value of
“TASK_EXECUTION_ID”. If no row exists with that key, then that means that the session variable hasn’t
been set (no tasks run or last task execution was unsuccessful).

 Note

Session variables are string values. The user needs to cast appropriately based on how they want to use the
value.

Table 55: Examples


Action SQL

Obtain the last task execution ID


SELECT SESSION_CONTEXT(‘TASK_EXECUTION_ID’) FROM dummy;

See monitoring information for


the last task that was executed
SELECT * FROM M_TASKS WHERE TASK_EXECUTION_ID = CAST
(SESSION_CONTEXT(‘TASK_EXECUTION_ID’) AS BIGINT);
(with type casting)

Cancel the last task that was exe­


cuted (with type casting)
CANCEL TASK CAST(SESSION_CONTEXT(‘TASK_EXECUTION_ID’)
AS BIGINT);

Related Information

SQL Notation Conventions (SAP HANA SQL and System Views Reference)

8.2 System Views

System views allow you to query for various information about the system state using SQL commands. The
results appear as tables.

System views are located in the SYS schema. In a system with tenant databases, every database has a SYS
schema with system views that contain information about that database only. In addition, the system database
has a further schema, SYS_DATABASES, which contains views for monitoring the system as a whole. The views
in the SYS_DATABASES schema provide aggregated information from a subset of the views available in the SYS
schema of all tenant databases in the system. These union views have the additional column DATABASE_NAME
to allow you to identify to which database the information refers. To be able to view information in these views,
you need the system privilege CATALOG READ or DATABASE ADMIN.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 561
SAP HANA system views are separated into two categories: metadata views and runtime views. Metadata
views provide metadata about objects in the database, including options or settings that were set using a DDL
statement. Runtime views provide actual HANA runtime data, including statistics and status information
related to the execution of DML statements. Runtime views start with M_ for monitoring.

ADAPTER_CAPABILITIES System View [Smart Data Integration] [page 564]


Specifies the SQL capabilities of the adapters stored in the system.

ADAPTER_LOCATIONS System View [Smart Data Integration] [page 565]


Specifies the location of adapters.

ADAPTERS System View [Smart Data Integration] [page 565]


Stores adapters available in the SAP HANA system.

AGENT_CONFIGURATION System View [Smart Data Integration] [page 566]


Agent configuration

AGENT_GROUPS System View [Smart Data Integration] [page 566]


Lists active data provisioning agent groups in the system.

AGENTS System View [Smart Data Integration] [page 566]


Lists active data provisioning agents in the system.

M_AGENTS System View [Smart Data Integration] [page 567]


Provides the status of all agents registered in the SAP HANA database.

M_REMOTE_SOURCES System View [Smart Data Integration] [page 568]


Stores dictionary status information, remote source owner information, and the status of data
collection.

M_REMOTE_SUBSCRIPTION_COMPONENTS System View [Smart Data Integration] [page 568]


Provides the status of a remote subscription for each internal component.

M_REMOTE_SUBSCRIPTION_STATISTICS System View [Smart Data Integration] [page 569]


Provides details of current processing details of a remote subscription (e.g. number of messages or
transactions received, applied since the start of the SAP HANA database).

M_REMOTE_SUBSCRIPTIONS System View [Smart Data Integration] [page 570]


Provides the status and run-time information of a remote subscription.

M_SESSION_CONTEXT System View [Smart Data Integration] [page 571]


Session variables for each connection

REMOTE_SOURCE_OBJECT_COLUMNS System View [Smart Data Integration] [page 572]


If the adapter can provide column-level information for each table in the remote system, once this
dictionary is built you can search for relationships between tables. This table is useful for analyzing
relationships between tables in the remote source.

REMOTE_SOURCE_ OBJECT_DESCRIPTIONS System View [Smart Data Integration] [page 572]


Stores description of browsable node in different languages.

REMOTE_SOURCE_OBJECTS System View [Smart Data Integration] [page 573]


Stores browsable nodes as well as importable objects (virtual tables). This view is built from remote
source metadata dictionaries.

REMOTE_SOURCES System View [Smart Data Integration] [page 573]


Remote sources

REMOTE_SUBSCRIPTION_EXCEPTIONS System View [Smart Data Integration] [page 574]

Installation and Configuration Guide


562 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Provides details about an exception that occurred during the execution of a remote subscription. The
exceptions can be processed using the PROCESS REMOTE SUBSCRIPTION EXCEPTION SQL
statement.

REMOTE_SUBSCRIPTIONS System View [Smart Data Integration] [page 575]


Lists all the remote subscriptions created for a remote source.

TASK_CLIENT_MAPPING System View [Smart Data Integration] [page 575]


Provides the client mapping when a task is created by the ABAP API.

TASK_COLUMN_DEFINITIONS System View [Smart Data Integration] [page 576]


Defines the columns present in a particular table.

TASK_EXECUTIONS System View [Smart Data Integration] [page 576]


Task-level run-time statistics generated when START TASK is run.

TASK_LOCALIZATION System View [Smart Data Integration] [page 577]


Contains localized values for the task framework tables.

TASK_OPERATIONS System View [Smart Data Integration] [page 578]


Contains all operations that exist for a given task, as well as details about those operations.

TASK_OPERATIONS_EXECUTIONS System View [Smart Data Integration] [page 578]


Operations-level task statistics generated when START TASK is run.

TASK_PARAMETERS System View [Smart Data Integration] [page 579]


Details about the task parameters view

TASK_TABLE_DEFINITIONS System View [Smart Data Integration] [page 580]


Contains all of the tables used by the various side-effect producing operation.

TASK_TABLE_RELATIONSHIPS System View [Smart Data Integration] [page 581]


Defines the relationships, if any, between tables within an operation.

TASKS System View [Smart Data Integration] [page 581]


Details about tasks.

VIRTUAL_COLUMN_PROPERTIES System View [Smart Data Integration] [page 582]


Lists the properties of the columns in a virtual table sent by the adapter via CREATE VIRTUAL TABLE
SQL statement.

VIRTUAL_TABLE_PROPERTIES System View [Smart Data Integration] [page 583]


Lists the properties of a virtual table sent by the adapter via the CREATE VIRTUAL TABLE SQL
statement.

BEST_RECORD_GROUP_MASTER_STATISTICS System View [Smart Data Quality] [page 583]


Contains a summary of Best Record group master statistics.

BEST_RECORD_RESULTS System View [Smart Data Quality] [page 584]


Contains governance information for every column in every record that is updated in the best record
process.

BEST_RECORD_STRATEGIES System View [Smart Data Quality] [page 585]


Contains information on which strategies are used in each strategy group and in which order.

CLEANSE_ADDRESS_RECORD_INFO System View [Smart Data Quality] [page 586]


Describes how well an address was assigned as well as the type of address.

CLEANSE_CHANGE_INFO System View [Smart Data Quality] [page 587]


Describes the changes made during the cleansing process.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 563
CLEANSE_COMPONENT_INFO System View [Smart Data Quality] [page 588]
Identifies the location of parsed data elements in the input and output.

CLEANSE_INFO_CODES System View [Smart Data Quality] [page 589]


Contains one row per info code generated by the cleansing process.

CLEANSE_STATISTICS System View [Smart Data Quality] [page 590]


Contains a summary of Cleanse statistics.

GEOCODE_INFO_CODES System View [Smart Data Quality] [page 591]


Contains one row per info code generated by the geocode transformation process.

GEOCODE_STATISTICS System View [Smart Data Quality] [page 592]


Contains a summary of Geocode statistics.

MATCH_GROUP_INFO System View [Smart Data Quality] [page 592]


Contains one row for each match group.

MATCH_RECORD_INFO System View [Smart Data Quality] [page 593]


Contains one row for each matching record per level.

MATCH_SOURCE_STATISTICS System View [Smart Data Quality] [page 594]


Contains counts of matches within and between data sources.

MATCH_STATISTICS System View [Smart Data Quality] [page 594]


Contains statistics regarding the run of the transformation operation.

MATCH_TRACING System View [Smart Data Quality] [page 595]


Contains one row for each match decision made during the matching process.

Related Information

System Views Reference for Additional SAP HANA Contexts (SAP HANA SQL and System Views Reference)

8.2.1 ADAPTER_CAPABILITIES System View [Smart Data


Integration]

Specifies the SQL capabilities of the adapters stored in the system.

Structure

Column Data type Description

ADAPTER_NAME NVARCHAR(64) Adapter name

SOURCE_VERSION NVARCHAR(64) Source versions supported by the adapter

Installation and Configuration Guide


564 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
8.2.2 ADAPTER_LOCATIONS System View [Smart Data
Integration]

Specifies the location of adapters.

Structure

Column Data type Description

ADAPTER_NAME NVARCHAR(64) Adapter name

LOCATION VARCHAR(11) Location of the adapter: 'indexserver', 'dpserver', 'agent'

AGENT_NAME NVARCHAR(256) Agent name

8.2.3 ADAPTERS System View [Smart Data Integration]

Stores adapters available in the SAP HANA system.

Structure

Column Data type Description

ADAPTER_NAME NVARCHAR(64) Adapter name

PROPERTIES NVARCHAR(1000) Optional properties of the adapter such as display_name


and description

CONFIGURATION NCLOB UI properties that must be displayed when configuring re­


mote data source

IS_SYSTEM_ADAPTER VARCHAR(5) Specifies whether the adapter is a system adapter:


'TRUE'/'FALSE'

IS_ESS_DEFINITION_SUP­ VARCHAR(5) Specifies if the procedure GET_REMOTE_SOURCE_TA­


PORTED BLE_ESS_DEFINITIONS is enabled for remote sources cre­
ated using this adapter: 'TRUE'/'FALSE'

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 565
8.2.4 AGENT_CONFIGURATION System View [Smart Data
Integration]

Agent configuration

Structure

Column name Data type Description

AGENT_NAME NVARCHAR(256) Agent name

KEY VARCHAR(128) Agent property key

VALUE NCLOB Agent property value

8.2.5 AGENT_GROUPS System View [Smart Data


Integration]

Lists active data provisioning agent groups in the system.

Structure

Column Data type Description

AGENT_GROUP_NAME NVARCHAR(256) Name of the agent group.

8.2.6 AGENTS System View [Smart Data Integration]

Lists active data provisioning agents in the system.

Installation and Configuration Guide


566 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

AGENT_NAME NVARCHAR(256) Agent name

PROTOCOL VARCHAR(4) Protocol for communication with SAP HANA database:


'TCP', 'HTTP'

AGENT_HOST NVARCHAR (64) Agent host specified when using TCP

AGENT_PORT INTEGER Agent port specified when using TCP

IS_SSL_ENABLED VARCHAR(5) Specifies whether the agent listening on TCP port uses SSL

AGENT_GROUP_NAME NVARCHAR(256) Agent clustering group to which the agent belongs.

8.2.7 M_AGENTS System View [Smart Data Integration]

Provides the status of all agents registered in the SAP HANA database.

Structure

Column Data type Description

AGENT_NAME NVARCHAR(256) Agent name

FREE_PHYSICAL_MEMORY BIGINT Free physical memory on the host

FREE_SWAP_SPACE BIGINT Free swap memory on the host

LAST_CONNECT_TIME TIMESTAMP The last time the session cookie was used for suc­
cessful re-connection

SYS_TIMESTAMP TIMESTAMP Host timestamp in local time zone

USED_PHYSICAL_MEMORY BIGINT Used physical memory on the host

USED_SWAP_SPACE BIGINT Used swap memory on the host

UTC_TIMESTAMP TIMESTAMP Host timestamp in UTC

AGENT_VERSION VARCHAR(32) Agent version

AGENT_STATUS VARCHAR(16) Agent status

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 567
8.2.8 M_REMOTE_SOURCES System View [Smart Data
Integration]

Stores dictionary status information, remote source owner information, and the status of data collection.

 Note

This system view is for keeping track of the status of metadata dictionaries for remote sources. If there is
no dictionary for a given remote source, it will not appear in the view.

For basic remote source information you can select from REMOTE_SOURCES. It includes the following.

● REMOTE_SOURCE_NAME
● ADAPTER_NAME
● CONNECTION_INFO
● AGENT_GROUP_NAME

Structure

Column Data type Description

USER_NAME NVARCHAR(256) User name

REMOTE_SOURCE_NAME NVARCHAR(256) Remote source name

LAST_REFRESH_TIME TIMESTAMP The successful completion timestamp of the refresh


operation

REFRESH_START_TIME TIMESTAMP The timestamp of when the refresh operation was


executed

REFRESH_STATUS VARCHAR(32) Refresh operation status:

● STARTED
● COMPLETED
● RUNNING (GET OBJECTS)
● RUNNING (GET OBJECT DETAILS)
● FAILED
● CANCELLED
● CLEARED

REFRESH_ERROR_MESSAGE NVARCHAR(2000) Exception message that occurred during refresh op­


eration

8.2.9 M_REMOTE_SUBSCRIPTION_COMPONENTS System


View [Smart Data Integration]

Provides the status of a remote subscription for each internal component.

Installation and Configuration Guide


568 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Remote subscription schema name

SUBSCRIPTION_NAME NVARCHAR(256) Remote subscription name

COMPONENT VARCHAR(10) ● DPSERVER


● ADAPTER
● RECEIVER
● APPLIER

STATUS VARCHAR Component status

MESSAGE VARCHAR Additional information

8.2.10 M_REMOTE_SUBSCRIPTION_STATISTICS System


View [Smart Data Integration]

Provides details of current processing details of a remote subscription (e.g. number of messages or
transactions received, applied since the start of the SAP HANA database).

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Remote subscription schema name

SUBSCRIPTION_NAME NVARCHAR(256) Remote subscription name

RECEIVED_MESSAGE_COUNT BIGINT Total message/transaction count received by the cur­


rent connection

RECEIVED_MESSAGE_SIZE BIGINT Total size of messages/transactions received by the cur­


rent connection

APPLIED_MESSAGE_COUNT BIGINT Total number of messages/transactions applied

APPLIED_MESSAGE_SIZE BIGINT Total size of messages/records applied

REJECTED_MESSAGE_COUNT BIGINT Total number of messages/records rejected

LAST_MESSAGE_RECEIVED TIMESTAMP Time at which the last message/transaction is received

LAST_MESSAGE_APPLIED TIMESTAMP Time at which the last message/transaction is applied

RECEIVER_LATENCY BIGINT Receiver latency in microseconds

APPLIER_LATENCY BIGINT Applier latency in microseconds

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 569
8.2.11 M_REMOTE_SUBSCRIPTIONS System View [Smart
Data Integration]

Provides the status and run-time information of a remote subscription.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Remote subscription schema name

SUBSCRIPTION_NAME NVARCHAR(256) Remote subscription name

STATE VARCHAR(256) State of event

OPTIMIZED_QUERY_STRING NCLOB This is generated and saved so that if there


are multiple subscriptions interested in
same query result, and the same inter­
nal_distribution_id, both the subscriptions
can use the same result.

OPTIMIZED_QUERY_HASH VARCHAR(128) Hash is used to query the match for opti­


mized query string

INTERNAL_DISTRIBUTION_ID BIGINT Generated integer to identify if multiple tar­


get tables are interested in the changes
from same source SQL or virtual table

OPTIMIZED_QUERY_RESULTSET_TYPE TINYINT 0 - REGULAR

1 - CLUSTER

2 - POOL

REMOTE_SUBSCRIPTION NVARCHAR(256) An optional subscription name registered


by the adapter in the remote source system

VOLUME_ID INTEGER Persistence Volume ID

BEGIN_MARKER VARCHAR(64) Generated begin marker in the format


B<remote_source_oid>_<remote_
subscription_oid>_<YYYYMMDDHH
24MMSSFF7> when QUEUE command is
called.

END_MARKER VARCHAR(64) Generated end marker in the format


E<remote_source_oid>_<remote_
subscription_oid>_<YYYYMMDDHH
24MMSSFF7> when DISTRIBUTE com­
mand is called.

BEGIN_MARKER_TIME TIMESTAMP Timestamp when QUEUE request is re­


ceived.

END_MARKER_TIME TIMESTAMP Timestamp when DISTRIBUTE command is


called.

Installation and Configuration Guide


570 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

LAST_PROCESSED_TRANSACTION_ID VARBINARY(128) Transaction ID of the last processed trans­


action.

LAST_PROCESSED_TRANSACTION_TIME TIMESTAMP Time when the last transaction was applied.

LAST_PROCESSED_BEGIN_SEQUENCE_ID VARBINARY(68) Last processed transaction's begin record


sequence ID

LAST_PROCESSED_COMMIT_SEQUENCE_ID VARBINARY(68) Last processed transaction's commit re­


cord sequence ID

LAST_RECEIVED_SEQUENCE_ID VARBINARY(68) Last received sequence ID

LAST_RECEIVED_CUSTOM_ID NVARCHAR(64) Last received custom ID. Custom IDs may


be used by adapters with every changed-
data row of a transaction.

LAST_PROCESSED_CUSTOM_ID NVARCHAR(64) Last processed custom ID. Custom IDs may


be used by adapters with every changed-
data row of a transaction.

8.2.12 M_SESSION_CONTEXT System View [Smart Data


Integration]

Session variables for each connection

 Note

The M_SESSION_CONTEXT view is available for use in other areas of SAP HANA, not only SAP HANA
smart data integration. Refer to the M_SESSION_CONTEXT topic for complete information. The
information below is specific to smart data integration functionality.

This view shows session variables of all open connections.

Each variable is categorized in SECTION column to USER (user defined variable using SET command or client
API call) or SYSTEM (predefined variable or system property).

Table 56: Predefined variables


Set by
Variable Name (M_SES­ Value Con­ Client or Shown in M_SESSION_CON­ Server
SION_CONTEXT.KEY) straint Server TEXT Usage Description

TASK_EXECUTION_ID bigint server yes START Shows unique


TASK task execution
ID

Related Information

M_SESSION_CONTEXT System View (SAP HANA SQL and System Views Reference)

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 571
8.2.13 REMOTE_SOURCE_OBJECT_COLUMNS System View
[Smart Data Integration]

If the adapter can provide column-level information for each table in the remote system, once this dictionary is
built you can search for relationships between tables. This table is useful for analyzing relationships between
tables in the remote source.

Structure

Column Data type Description

USER_NAME NVARCHAR(256) For secondary credentials, need to know the owner


name

REMOTE_SOURCE_NAME NVARCHAR(256) To uniquely identify a remote source

OBJECT_NAME NVARCHAR(5000) Unique name to identify remote source object

COLUMN_NAME NVARCHAR(256) Column name

DATA_TYPE_NAME VARCHAR(16) SAP HANA data type

REMOTE_DATA_TYPE_NAME VARCHAR(32) Remote source data type

REMOTE_CONTENT_TYPE NVARCHAR(256) Examples include address, unit of measure, user-de­


fined types, ZIP code, and so on

LENGTH INTEGER Length/precision of the column

SCALE INTEGER Scale of the column

IS_NULLABLE VARCHAR(5) Various column properties

IS_AUTOINCREMENT

8.2.14 REMOTE_SOURCE_ OBJECT_DESCRIPTIONS System


View [Smart Data Integration]

Stores description of browsable node in different languages.

Structure

Column Data type Description

USER_NAME NVARCHAR(256) User name

Installation and Configuration Guide


572 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

REMOTE_SOURCE_NAME NVARCHAR(256) Remote source name

OBJECT_NAME NVARCHAR(5000) Unique name to identify remote source object

LANGUAGE_CODE VARCHAR(2) Language code

DESCRIPTION NVARCHAR(5000) Description of this object

8.2.15 REMOTE_SOURCE_OBJECTS System View [Smart


Data Integration]

Stores browsable nodes as well as importable objects (virtual tables). This view is built from remote source
metadata dictionaries.

Structure

Column Data type Description

USER_NAME NVARCHAR(256) User name

REMOTE_SOURCE_NAME NVARCHAR(256) Remote source name

OBJECT_NAME NVARCHAR(5000) Unique name to identify remote source object

DISPLAY_NAME NVARCHAR(256) Display name for this object

IS_IMPORTABLE VARCHAR(5) If the object is importable as a virtual table:


'TRUE'/'FALSE'

IS_EXPANDABLE VARCHAR(5) If the object can be expanded or browsed to get inner


objects: 'TRUE/'FALSE'

PARENT_OBJECT_NAME NVARCHAR(5000) The parent object name for this object

DEFINITION_TYPE VARCHAR(32) Object definition type

DEFINITION NCLOB Object definition

8.2.16 REMOTE_SOURCES System View [Smart Data


Integration]

Remote sources

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 573
Structure

Column name Data type Description

REMOTE_SOURCE_NAME NVARCHAR(256) Remote source name

ADAPTER_NAME NVARCHAR(256) Adapter name

CONNECTION_INFO NVARCHAR(256) Connection information

AGENT_GROUP_NAME NVARCHAR(256) Name of the agent group name

Related Information

REMOTE_SOURCES System View (SAP HANA SQL and System Views Reference)

8.2.17 REMOTE_SUBSCRIPTION_EXCEPTIONS System View


[Smart Data Integration]

Provides details about an exception that occurred during the execution of a remote subscription. The
exceptions can be processed using the PROCESS REMOTE SUBSCRIPTION EXCEPTION SQL statement.

Structure

Column Data type Description

EXCEPTION_OID BIGINT Exception ID

OBJECT_TYPE VARCHAR(19) 'REMOTE SOURCE', 'REMOTE SUBSCRIPTION'

OBJECT_SCHEMA_NAME NVARCHAR(256) Schema name of remote source or remote subscription based


on OBJECT_TYPE

OBJECT_NAME NVARCHAR(256) Object name of remote source or remote subscription based on


OBJECT_TYPE

EXCEPTION_TIME TIMESTAMP Time at which the exception was raised

ERROR_NUMBER INTEGER Error number

ERROR_MESSAGE NVARCHAR(2000) Error message

COMPONENT VARCHAR(8) Component that raised the exception

Installation and Configuration Guide


574 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
8.2.18 REMOTE_SUBSCRIPTIONS System View [Smart Data
Integration]

Lists all the remote subscriptions created for a remote source.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Remote subscription schema name

SUBSCRIPTION_NAME NVARCHAR(256) Remote subscription name

OWNER_NAME NVARCHAR(256) Owner name

REMOTE_SOURCE_NAME NVARCHAR(256) Remote source name

IS_VALID VARCHAR(5) Specifies whether the remote subscription is valid or


not. This becomes FALSE when its source or target
objects are changed or dropped.

SUBSCRIPTION_TYPE VARCHAR(13) Remote subscription type

VIRTUAL_TABLE_SCHEMA_NAME NVARCHAR(256) Virtual table schema name

VIRTUAL_TABLE_NAME NVARCHAR(256) Virtual table name

SUBSCRIPTION_QUERY_STRING NCLOB Select statement specified in the subscription when


subscription type is SQL

TARGET_OBJECT_TYPE VARCHAR(9) Remote subscription target object type: 'TABLE',


'PROCEDURE', 'TASK'

TARGET_OBJECT_SCHEMA_NAME NVARCHAR(256) Target object schema name

TARGET_OBJECT_NAME NVARCHAR(256) Target object name

TARGET_OTHER_PARAM_STRING NVARCHAR(4000) Constant parameter string to pass at execution when


target object type is PROCEDURE or TASK

TASK_PROCEDURE_PARAMETERS NVARCHAR(5000) A comma-separated list of task parameters.

8.2.19 TASK_CLIENT_MAPPING System View [Smart Data


Integration]

Provides the client mapping when a task is created by the ABAP API.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 575
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

CLIENT NVARCHAR(128) Name of the client that created the task with the ABAP API

8.2.20 TASK_COLUMN_DEFINITIONS System View [Smart


Data Integration]

Defines the columns present in a particular table.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

COLUMN_NAME NVARCHAR(128) Name of the column used in the task plan within a table

MAPPED_NAME NVARCHAR(128) Mapped name of the column used in a task plan within a ta­
ble

8.2.21 TASK_EXECUTIONS System View [Smart Data


Integration]

Task-level run-time statistics generated when START TASK is run.

TASK_EXECUTIONS shows one record per task plan execution.

Data in this view is updated while the task is in progress. For example, STATUS, PROCESSED_RECORDS, and
TOTAL_PROGRESS_PERCENT are continuously updated until the task is complete.

Users may view information only for tasks that they ran themselves or were granted permissions to view.

Installation and Configuration Guide


576 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

HOST VARCHAR(64) Host name

PORT INTEGER Internal port

SCHEMA_NAME NVARCHAR(256) Schema name used in the task

TASK_NAME NVARCHAR(256) Name of the task

CONNECTION_ID INTEGER Connection identifier

TRANSACTION_ID INTEGER Transaction identifier used for the task execution

TASK_EXECUTION_ID BIGINT Task execution unique identifier

PARENT_TASK_EXECUTION_ID BIGINT Parent task identifier

IS_ASYNC VARCHAR(5) TRUE if the task is asynchronous, else FALSE

PARAMETERS NVARCHAR(5000) Input parameters for the task

PROCEDURE_PARAMETERS NVARCHAR(5000) Displays the input <param-list> values that were speci­
fied in the START TASK SQL command

START_TIME TIMESTAMP Start time of the task

END_TIME TIMESTAMP End time of the task

DURATION BIGINT Execution time of the task (microseconds)

STATUS VARCHAR(16) Status of the task: STARTING, RUNNING, FAILED, COM­


PLETED, CANCELLING, or CANCELLED

CURRENT_OPERATION NVARCHAR(128) Current operation of the task

PROCESSED_RECORDS BIGINT Total number of records processed

TOTAL_PROGRESS_PERCENT BIGINT Total task progress (percent)

USER_NAME NVARCHAR(256) User name

APPLICATION_USER_NAME NVARCHAR(256) Application user name

HAS SIDE EFFECTS VARCHAR(5) 'TRUE' if the task produces side effect data, else 'FALSE'

8.2.22 TASK_LOCALIZATION System View [Smart Data


Integration]

Contains localized values for the task framework tables.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 577
Structure

Column Data type Description

LOC_TYPE_ID INTEGER Identifier of the type of the entity being localized

LOC_ID NVARCHAR(64) Identifier of the entity being localized

LANGUAGE NVARCHAR(1) One-character code of the localized language

DESCRIPTION NVARCHAR(1024) Localized description

8.2.23 TASK_OPERATIONS System View [Smart Data


Integration]

Contains all operations that exist for a given task, as well as details about those operations.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

COMMENTS NVARCHAR(512) Comments made on the operation

HAS_SIDE_EFFECTS TINYINT Specifies whether the operation has side-effect data

OPERATION_TYPE NVARCHAR(128) Type of operation in the task plan

8.2.24 TASK_OPERATIONS_EXECUTIONS System View


[Smart Data Integration]

Operations-level task statistics generated when START TASK is run.

TASK_OPERATIONS_EXECUTIONS shows one record per operation.

Data in this view is updated while the task is in progress. For example, STATUS, PROCESSED_RECORDS, and
OPERATIONS_PROGRESS_PERCENT are continuously updated until the task is complete.

Installation and Configuration Guide


578 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Users may view information only for tasks that they ran themselves or were granted permissions to view.

Structure

Column Data type Description

HOST VARCHAR(64) Host name

PORT INTEGER Internal port

TASK_EXECUTION_ID BIGINT Task identifier

CONNECTION_ID INTEGER Connection identifier

TRANSACTION_ID INTEGER Transaction identifier used for the task execution

CURRENT_OPERATION NVARCHAR Name of operation

OPERATION_TYPE NVARCHAR(128) Type of operation

OPERATION_NAME NVARCHAR(128) Internal name of operation

START_TIME TIMESTAMP Start time of the task

END_TIME TIMESTAMP End time of the task

DURATION BIGINT Execution time of the task (microseconds)

STATUS VARCHAR(16) Status of the task:

● STARTING
● RUNNING
● FAILED
● COMPLETED
● CANCELLING
● CANCELLED

PROCESSED_RECORDS BIGINT Total number of records processed

OPERATION_PROGRESS_PERCENT DOUBLE Operation progress (percent)

HAS_SIDE_EFFECTS VARCHAR(5) 'TRUE' if the task produces side effect data, else 'FAL­
SE'

8.2.25 TASK_PARAMETERS System View [Smart Data


Integration]

Details about the task parameters view

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 579
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Schema in which the task was created

TASK_NAME NVARCHAR(256) Name of task

PARAMETER_NAME NVARCHAR(256) Name of parameter

POSITION INTEGER Position of parameter

TABLE_TYPE_SCHEMA NVARCHAR(256) Schema in which the TableType was created

TABLE_TYPE_NAME NVARCHAR(256) Name of TableType

PARAMETER_TYPE VARCHAR(7) Parameter type: IN or OUT

8.2.26 TASK_TABLE_DEFINITIONS System View [Smart Data


Integration]

Contains all of the tables used by the various side-effect producing operation.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_ID INTEGER Unique identifier for the table

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for an operation

SIDE_EFFECT_SCHEMA NVARCHAR(128) Schema where the generated side-effect table is located

SIDE_EFFECT_NAME NVARCHAR(128) Name of the generated side-effect table

IS_PRIMARY_TABLE TINYINT Specifies whether this table is the primary table in a relation­
ship

OPERATION_TABLE_TYPE NVARCHAR(20) Type of operation that the table is used within

Installation and Configuration Guide


580 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
8.2.27 TASK_TABLE_RELATIONSHIPS System View [Smart
Data Integration]

Defines the relationships, if any, between tables within an operation.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for an operation

RELATED_TABLE_NAME NVARCHAR(128) Name of the table to which the table specified in TA­
BLE_NAME is related

FROM_ATTRIBUTE NVARCHAR(128) Name of the column in the TABLE_NAME table that relates
to the TO_ATTRIBUTE

TO_ATTRIBUTE NVARCHAR(128) Name of the column in the RELATED_TABLE_NAME table


that relates to the FROM_ATTRIBUTE

8.2.28 TASKS System View [Smart Data Integration]

Details about tasks.

Structure

Column Data type Description

TASK_OID BIGINT Unique identifier for a task

TASK_NAME NVARCHAR(256) Name of task

SCHEMA_NAME NVARCHAR(256) Schema the task was created in

OWNER_NAME NVARCHAR(256) Owner of the task

CREATE_TIME TIMESTAMP Creation time

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 581
Column Data type Description

MEMORY_SIZE BIGINT Memory size of loaded task

TASK_TYPE NVARCHAR(64) Type of task ('PLAN' or 'PROCEDURE'), based on how


the task was created

PLAN_VERSION NVARCHAR(32) Version of the task plan

PLAN NCLOB Task plan used to define the task, or task plan gener­
ated to call the procedure

COMMENTS NVARCHAR(256) Description of the task, from the task plan

HAS_TABLE_TYPE_INPUT VARCHAR(5) 'TRUE' if the task is modeled with a table type as in­
put, meaning data would need to be passed at execu­
tion time

HAS SDQ VARCHAR(5) 'TRUE' if the task contains SDQ (smart data quality)
functionality

IS_REALTIME_TASK VARCHAR(5) 'TRUE' if the task is a realtime task, else 'FALSE'

IS_VALID VARCHAR(5) 'TRUE' if the task is in a valid state; 'FALSE if it has


been invalidated by a dependency

IS_READ_ONLY VARCHAR(5) 'TRUE' if the task is read only (has only table type out­
puts), 'FALSE' if it writes to non-table-type outputs

PROCEDURE_SCHEMA NVARCHAR(256) If the task was created with a procedure instead of a


plan, this attribute will contain the schema name of
the stored procedure

PROCEDURE_NAME NVARCHAR(256) If the task was created with a procedure instead of a


plan, this attribute will contain the name of the name
of the stored procedure

INPUT_PARAMETER_COUNT SMALLINT Number of input (tableType) parameters

OUTPUT_PARAMETER SMALLINT Number of output (tableType) parameters

SQL_SECURITY VARCHAR(7) Security model for the task, either 'DEFINER' or 'IN­
VOKER'

8.2.29 VIRTUAL_COLUMN_PROPERTIES System View [Smart


Data Integration]

Lists the properties of the columns in a virtual table sent by the adapter via CREATE VIRTUAL TABLE SQL
statement.

Installation and Configuration Guide


582 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Schema name of virtual table

TABLE_NAME NVARCHAR(256) Virtual table name

COLUMN_NAME NVARCHAR(256) Virtual table column name

PROPERTY NVARCHAR(256) Property name

VALUE NVARCHAR(512) Property value

8.2.30 VIRTUAL_TABLE_PROPERTIES System View [Smart


Data Integration]

Lists the properties of a virtual table sent by the adapter via the CREATE VIRTUAL TABLE SQL statement.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Schema name of virtual table

TABLE_NAME NVARCHAR(256) Virtual table name

PROPERTY NVARCHAR(256) Property name

VALUE NCLOB Property value. For example:

● Large XSD of size 1M

8.2.31 BEST_RECORD_GROUP_MASTER_STATISTICS System


View [Smart Data Quality]

Contains a summary of Best Record group master statistics.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 583
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

NUM_RECORDS BIGINT Total number of records processed

NUM_GROUP_MASTERS BIGINT Number of group master records processed

NUM_DUPLICATES BIGINT Number of duplicate records processed

NUM_SURVIVORS BIGINT Number of surviving records processed

NUM_NON_MATCH_RE­ BIGINT Number of non-matching records processed


CORDS

8.2.32 BEST_RECORD_RESULTS System View [Smart Data


Quality]

Contains governance information for every column in every record that is updated in the best record process.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

DST_TABLE_NAME NVARCHAR(128) Name of the destination table for the operation

Installation and Configuration Guide


584 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

DST_ROW_ID BIGINT Unique identifier for the destination row

DST_COLUMN_NAME NVARCHAR(128) Name of the destination column in the destination table

DST_ROW_TYPE NVARCHAR(1) Identifies how the record was updated or if it was newly cre­
ated

SRC_TABLE_NAME NVARCHAR(128) Name of the source table for the operation

SRC_ROW_ID BIGINT Unique identifier for the source row

SRC_COLUMN_NAME NVARCHAR(128) Name of the source column in the source table

STRATEGY_GROUP_ID INTEGER Identification number that identifies the best record strategy
group

STRATEGY_ID INTEGER Identification number that identifies each strategy listed in


the strategy group

BEST_RECORD_RULE NVARCHAR(256) Name of the rule that updates one or more columns as it is
defined in the best record configuration

ACTION_NAME NVARCHAR(256) Name of the action that updates a column as it is defined in


the best record configuration

UPDATE_NUM INTEGER Number of times the column was updated in the best record
process

OPERATION_TYPE NVARCHAR(1) Identifies how the record was updated in the best record
process

8.2.33 BEST_RECORD_STRATEGIES System View [Smart


Data Quality]

Contains information on which strategies are used in each strategy group and in which order.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 585
Column Data type Description

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

STRATEGY_GROUP_NAME NVARCHAR(256) Name of the strategy group as defined in the best record
configuration

STRATEGY_ID INTEGER Identification number that identifies each strategy listed in


the strategy group

STRATEGY_ORDER INTEGER) Order of the strategy as defined in the list of strategies

STRATEGY_NAME NVARCHAR(256) Name of the strategy as defined in the best record configu-
ration

8.2.34 CLEANSE_ADDRESS_RECORD_INFO System View


[Smart Data Quality]

Describes how well an address was assigned as well as the type of address.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

Installation and Configuration Guide


586 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

ENTITY_INSTANCE INTEGER Identifier to differentiate between multiple entities proc­


essed in a row

ENTITY_INSTANCE_OCCUR­ INTEGER Unique identifier to identify the occurrence of an entity


RENCE

DATA_SOURCE NVARCHAR(256) Source where the data was produced

ISO_COUNTRY_2CHAR NVARCHAR(4) Two-character country code

ASSIGNMENT_TYPE NVARCHAR(4) Code that represents the type of an address

ASSIGNMENT_INFORMA­ NVARCHAR(4) Code that specifies the validity of an address


TION

ASSIGNMENT_LEVEL NVARCHAR(4) Code that represents the level to which the address matched
data in the address reference data

8.2.35 CLEANSE_CHANGE_INFO System View [Smart Data


Quality]

Describes the changes made during the cleansing process.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

ENTITY_ID NVARCHAR(12) Identifier describing the type of record that was processed

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 587
Column Data type Description

ENTITY_INSTANCE INTEGER Identifier to differentiate between multiple entities proc­


essed in a row

ENTITY_INSTANCE_OCCUR­ INTEGER Unique identifier to identify the occurrence of an entity


RENCE

COMPONENT_ID NVARCHAR(12) Identification number that refers to data components

COMPONENT_ELEMENT_ID NVARCHAR(12) Identification number that refers to more granular elements


within a component

DATA_SOURCE NVARCHAR(256) Source where the data was produced

CHANGE_SIGNIFICANCE_ID NVARCHAR(12) Identification number that refers to the significance of the


change

8.2.36 CLEANSE_COMPONENT_INFO System View [Smart


Data Quality]

Identifies the location of parsed data elements in the input and output.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

ENTITY_ID NVARCHAR(12) Identifier describing a data attribute such as a person name,


organization name, address and so on.

ENTITY_INSTANCE INTEGER Identifier to differentiate between multiple entities proc­


essed in a row

ENTITY_INSTANCE_OCCUR­ INTEGER Unique identifier to identify the occurrence of an entity


RENCE

Installation and Configuration Guide


588 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

DATA_SOURCE NVARCHAR(256) Source where the data originated

COMPONENT_ID NVARCHAR(12) Identification number that refers to data components

COMPONENT_ELEMENT_ID NVARCHAR(12) Identification number that refers to more granular elements


within a component

TABLE_NAME NVARCHAR(128) Name of the input table where the component element was
found

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

COLUMN_NAME NVARCHAR(128) Name of the column in the input table where the component
element was found

COLUMN_START_POSITION INTEGER Starting character of the component element in the input


column

COLUMN_DATA_LENGTH INTEGER Number of characters of the component element in the in­


put column

OUTPUT_TABLE_NAME NVARCHAR(128) Name of the output table where the component element was
written

OUTPUT_COLUMN_NAME NVARCHAR(128) Name of the column in the output table where the compo­
nent element was written

OUTPUT_COL­ INTEGER Starting character of the component element in the output


UMN_START_POSITION column

OUTPUT_COL­ INTEGER Number of characters of the component element in the out­


UMN_DATA_LENGTH put column

8.2.37 CLEANSE_INFO_CODES System View [Smart Data


Quality]

Contains one row per info code generated by the cleansing process.

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 589
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

ENTITY_ID NVARCHAR(12) Identifier describing the type of record that was processed

ENTITY_INSTANCE INTEGER Identifier to differentiate between multiple entities proc­


essed in a row

ENTITY_INSTANCE_OCCUR­ INTEGER Unique identifier to identify the occurrence of an entity


RENCE

DATA_SOURCE NVARCHAR(256) Source where the data was produced

INFO_CODE NVARCHAR(10) Information code that gives information about the process­
ing of the record

8.2.38 CLEANSE_STATISTICS System View [Smart Data


Quality]

Contains a summary of Cleanse statistics.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

Installation and Configuration Guide


590 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Column Data type Description

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

ENTITY_ID NVARCHAR(12) Identifier describing the type of record that was processed

ENTITY_INSTANCE INTEGER Identifier to differentiate between multiple entities proc­


essed in a row

NUM_RECORDS BIGINT Total number of records processed for the entity instance

NUM_VALIDS BIGINT Number of valid records processed for the entity instance

NUM_SUSPECTS BIGINT Number of suspect records processed for the entity instance

NUM_BLANKS BIGINT Number of blank records processed for the entity instance

NUM_HIGH_SIGNIFI­ BIGINT Number of records with high significance changes for the en­
CANT_CHANGES tity instance

8.2.39 GEOCODE_INFO_CODES System View [Smart Data


Quality]

Contains one row per info code generated by the geocode transformation process.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 591
Column Data type Description

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

DATA_SOURCE NVARCHAR(256) Source where the data was produced

INFO_CODE NVARCHAR(10) Information code generated by the geocode transformation


operation

8.2.40 GEOCODE_STATISTICS System View [Smart Data


Quality]

Contains a summary of Geocode statistics.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

NUM_RECORDS BIGINT Total number of records processed

NUM_ASSIGNED BIGINT Number of assigned records processed

NUM_UNASSIGNED BIGINT Number of unassigned records processed

8.2.41 MATCH_GROUP_INFO System View [Smart Data


Quality]

Contains one row for each match group.

Installation and Configuration Guide


592 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

GROUP_ID INTEGER Group identification number

GROUP_COUNT INTEGER Number of records in the match group

SOURCE_COUNT INTEGER Number of sources represented in the match group

REVIEW_GROUP NVARCHAR(1) Indicates whether the group is flagged for review

CONFLICT_GROUP NVARCHAR(1) Indicates whether the group is flagged for conflict

8.2.42 MATCH_RECORD_INFO System View [Smart Data


Quality]

Contains one row for each matching record per level.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 593
Column Data type Description

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

GROUP_ID INTEGER Group identification number

8.2.43 MATCH_SOURCE_STATISTICS System View [Smart


Data Quality]

Contains counts of matches within and between data sources.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

SOURCE_NAME NVARCHAR(256) Data source name

RELATED_SOURCE_NAME NVARCHAR(256) Related data source name

NUM_MATCH_DECISIONS INTEGER Number of comparisons resulting in a match decision be­


tween records in each SOURCE_ID/RELATED_SOURCE_ID
pair

8.2.44 MATCH_STATISTICS System View [Smart Data


Quality]

Contains statistics regarding the run of the transformation operation.

Installation and Configuration Guide


594 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

NUM_RECORDS BIGINT Total number of records processed by the transformation


operation

NUM_MATCH_RECORDS BIGINT Number of records that reside in match groups

NUM_NON_MATCH_RE­ BIGINT Number of non-matching records that do not reside in


CORDS match groups

NUM_MATCH_GROUPS BIGINT Number of match groups identified

NUM_REVIEW_GROUPS BIGINT Number of match groups flagged for review

NUM_NON_RE­ BIGINT Number of match groups not flagged for review


VIEW_GROUPS

NUM_CONFLICT_GROUPS BIGINT Number of match groups flaggged with conflicts

NUM_COMPARISONS_PER­ BIGINT Number of comparisons performed by the transformation


FORMED operation

NUM_MATCH_DECISIONS BIGINT Number of comparisons resulting in a match decision

8.2.45 MATCH_TRACING System View [Smart Data Quality]

Contains one row for each match decision made during the matching process.

Structure

Column Data type Description

SCHEMA_NAME NVARCHAR(256) Name of the schema where the task is located

Installation and Configuration Guide


SQL and System Views Reference for Smart Data Integration and Smart Data Quality PUBLIC 595
Column Data type Description

TASK_NAME NVARCHAR(256) Name of the task

TASK_EXECUTION_ID BIGINT Unique identifier for a particular run of a task plan created
when START TASK is called

OPERATION_NAME NVARCHAR(128) Name of the operation in the task plan

TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for the operation

ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

RELATED_TABLE_NAME NVARCHAR(128) Name of the table defined in the task plan for an operation

RELATED_ROW_ID BIGINT Unique identifier of the row processed for this execution of
the task plan

POLICY_NAME NVARCHAR(256) Name of the match policy that processed the related rows

RULE_NAME NVARCHAR(256) Name of the match rule that processed the related rows

SCORE INTEGER Similarity score of the related rows

Installation and Configuration Guide


596 PUBLIC SQL and System Views Reference for Smart Data Integration and Smart Data Quality
Important Disclaimers and Legal Information

Hyperlinks
Some links are classified by an icon and/or a mouseover text. These links provide additional information.
About the icons:

● Links with the icon : You are entering a Web site that is not hosted by SAP. By using such links, you agree (unless expressly stated otherwise in your
agreements with SAP) to this:

● The content of the linked-to site is not SAP documentation. You may not infer any product claims against SAP based on this information.
● SAP does not agree or disagree with the content on the linked-to site, nor does SAP warrant the availability and correctness. SAP shall not be liable for any
damages caused by the use of such content unless damages have been caused by SAP's gross negligence or willful misconduct.

● Links with the icon : You are leaving the documentation for that particular SAP product or service and are entering a SAP-hosted Web site. By using such
links, you agree that (unless expressly stated otherwise in your agreements with SAP) you may not infer any product claims against SAP based on this
information.

Beta and Other Experimental Features


Experimental features are not part of the officially delivered scope that SAP guarantees for future releases. This means that experimental features may be changed by
SAP at any time for any reason without notice. Experimental features are not for productive use. You may not demonstrate, test, examine, evaluate or otherwise use
the experimental features in a live operating environment or with data that has not been sufficiently backed up.
The purpose of experimental features is to get feedback early on, allowing customers and partners to influence the future product accordingly. By providing your
feedback (e.g. in the SAP Community), you accept that intellectual property rights of the contributions or derivative works shall remain the exclusive property of SAP.

Example Code
Any software coding and/or code snippets are examples. They are not for productive use. The example code is only intended to better explain and visualize the syntax
and phrasing rules. SAP does not warrant the correctness and completeness of the example code. SAP shall not be liable for errors or damages caused by the use of
example code unless damages have been caused by SAP's gross negligence or willful misconduct.

Gender-Related Language
We try not to use gender-specific word forms and formulations. As appropriate for context and readability, SAP may use masculine word forms to refer to all genders.

Videos Hosted on External Platforms


Some videos may point to third-party video hosting platforms. SAP cannot guarantee the future availability of videos stored on these platforms. Furthermore, any
advertisements or other content hosted on these platforms (for example, suggested videos or by navigating to other videos hosted on the same site), are not within
the control or responsibility of SAP.

Installation and Configuration Guide


Important Disclaimers and Legal Information PUBLIC 597
www.sap.com/contactsap

© 2020 SAP SE or an SAP affiliate company. All rights reserved.

No part of this publication may be reproduced or transmitted in any form


or for any purpose without the express permission of SAP SE or an SAP
affiliate company. The information contained herein may be changed
without prior notice.

Some software products marketed by SAP SE and its distributors


contain proprietary software components of other software vendors.
National product specifications may vary.

These materials are provided by SAP SE or an SAP affiliate company for


informational purposes only, without representation or warranty of any
kind, and SAP or its affiliated companies shall not be liable for errors or
omissions with respect to the materials. The only warranties for SAP or
SAP affiliate company products and services are those that are set forth
in the express warranty statements accompanying such products and
services, if any. Nothing herein should be construed as constituting an
additional warranty.

SAP and other SAP products and services mentioned herein as well as
their respective logos are trademarks or registered trademarks of SAP
SE (or an SAP affiliate company) in Germany and other countries. All
other product and service names mentioned are the trademarks of their
respective companies.

Please see https://www.sap.com/about/legal/trademark.html for


additional trademark information and notices.

THE BEST RUN

You might also like