You are on page 1of 51

DATA Provisioning is a process of creating, preparing, and enabling a network to provide

data to its user. Data needs to be loaded to SAP HANA before data reaches to the user
via a front-end tool.

All these processes are referred as ETL (Extract, Transform, and Load), and detail is as
below-

Extract – This is first and sometimes most difficult part of ETL, in which data are
extracted from the different source system.
Transform – In the Transformation Part, series of rules or functions is defined for the
data extracted from the source system, for loading data into the target system.
Load – The Load phase loads the data in the target system.
In this tutorial, you will learn-

Overview of Replication Technology


SAP HANA supports two type of Provisioning tool  –

1. SAP HANA Built-In Provisioning Tool


1. Flat File
2. Smart Data Streaming
3. Smart Data Access (SDA)
4. Enterprise Information Management(EIM)
5. Remote data
2. External tool supported by SAP HANA
1. SAP Landscape Transformation
2. SAP Business Objects Data Services
3. SAP Direct Extractor Connection
4. Sybase Replication Server

At present, there are main methods of data provisioning for S AP HANA, these are  –

Methods of Data Description


Provisioning

SLT SLT ("SAP Landscape Transformation Replication Server") runn ing on the SAP
Platform. SLT is an ideal solution for Real-Time and Schedule time replication f 
SAP source system.
SAP DATA Services SAP DATA Services is a platform for designing of ETL processes with a graphica

DXC DXC stand for Direct Extractor Connect is a batch driven ETL tool.

Flat File Upload This option used to Upload data (.csv, .xls, .xlsx) to SAP HANA.

SAP HANA SLT Road Map is as below  – DATA Provisioning through SLT require RFC/DB
connection to SAP/Non-SAP Source System and a DB connection for SAP HANA
database. On SAP SLT server we define Mapping and Transformation. Below is a
roadmap for data provisioning through SLT.

SLT (SAP Landscape Transformation Replication Server)


SLT is the SAP first ETL tool that allows you to load and replicate data in real-time or
schedule data from the source system and Non-Source System into SAP HANA Database.

SAP SLT server uses a trigger-based replication approach to pass data from source
system to target system.

SLT server can be installed on the separate system or on SAP ECC System.

Benefit of SLT system is as below-

 Allows real-time or schedule time data replication.


 During replicating data in real-time, we can migrate data in SAP HANA Format.
 SLT handles Cluster and Pool tables.
 This support automatically non-Unicode and Unicode conversion during
load/replication. (Unicode is a character encoding system similar to ASCII. Non-
Unicode is encoding system covers more character than ASCII).
 This is fully integrated with SAP HANA Studio.
 SLT have table setting and transformation capabilities.
 SLT have monitoring capabilities with SAP HANA Solution Manager.
Architecture Overview of SAP SLT server with SAP / Non-SAP System is as below-

SAP SLT Connection Architecture overview


overview between SAP System
and SAP HANA
SAP SLT Replication Server transforms all metadata table definitions from the ABAP
source system to SAP HANA.

For SAP source, the SLT connection has the following features -

 When a table is replicated, SAP SLT Replication server create logging tables in the
source system.
 Read engine is created in the SAP Source System.
 The connection between SAP SLT and SAP Source is established as RFC connection.
 The connection between SAP SLT and SAP HANA is established as a DB connection.
A database user with the same authorization as user "SYSTEM" can create a connection
between SAP SLT and SAP HANA Database.

SAP SLT Connection between SAP System and SAP HANA DATABASE

SAP SLT Server automatically create DB connection for SAP HANA database (when we
create a new configuration via transaction LTR). There is no need to create it manually.
Configure SAP SLT Server for SAP Source System
First we need to configure SAP SLT replication server for connection between SAP
Source and SAP HANA database. T-code, LTR is used for creating a connection between
SAP Source and SAP SLT.

Step 1) Login to SAP SLT server, and Call transaction  "LTR" from SAP SLT replication
server.

A Web-dynpro pop-up screen will appear for login to SAP SLT server.

1. Enter Client / User id / password


2. Click on logon tab
A pop-up screen for Configuration will appear as below-

Click on "New" Button for the new configuration.

Step 2) In this step,

1. Enter Configuration name and description.


2. Select SAP System as the source system.
3. Enter RFC connection for SAP System.
4. Enter Username / Password / Host Name and Instance number.
5. Enter Job options detail  –

 No. of data Transfer Jobs.


 No. Of calculation jobs.

6. Select Replication option as Real Time.


7. Once all the settings are maintained click on 'OK' to create a new schema in SLT.
A Configuration Name "SLTECC" will be added and active.

After configuration SAP SLT server successfully, SAP SLT Server automatically create DB
connection for SAP HANA database (when we create a new configuration via transaction
LTR). There is no need to create it manually.

In next step, we import data to SAP HANA from SAP Source.

Import SAP Source Data to SAP HANA through SLT


Once we have successfully configured SAP SLT server, a SCHEMA as configuration name
above in SAP SLT is created in SAP HANA Database.

This Schema contains following objects-

1. 1 Schema - SLTECC.
2. 1 User – SLTECC.
3. 1 Privileges
4. 8 Tables  –

 DD02L (SAP Tables Name )


 DD02T (SAP Table Texts)
 RS_LOG_FILES
 RS_MESSAGE
 RS_ORDER
 RS_ORDER_TEXT
 RS_SCHEMA_MAP
 RS_STATUS.

5. 4 Role -

 SLTECC_DATA_PROV
 SLTECC_DATA_POWER_USER
 SLTECC_DATA_USER_ADMIN
 SLTECC_DATA_SELECT

6. 2 Procedures

 RS_GRANT_ACCESS
 RS_REVOKE_ACCESS
All configuration is completed, now we load a table from SAP ECC (ERP Central
Component).

Step 1) To load tables from SAP ECC to SAP HANA database, follow below steps-

1. Go to Data provisioning from Quick View.


2. Select SAP HANA System.
3. Click on Finish Button.
Step 2) A screen for SLT Based Table Data Provisioning will be displayed. There are 5
options for data provisioning as below-

Provision Option Detail

Load (Full Load) This is a one-time event, which starts an initial load of data from source system.

Replicate It start initial load (if not done earlier), and also consider delta change. Database
trigger and related logging table will be created for each table.
(Full Load +
Delta Load)

Stop Replication It stops the current replication process for a table. It removes database trigger and
logging table completely.

Suspend It pause a running replication process of a table. The database trigger will not be
deleted from the source system, and recording of changes will continue. Related
Information is stored in the related logging table in the source system.

Resume Resume restarts the replication for a suspended table. After resume, the suspended
replication process will resume.

We use the first option from the table "Load option"  for initial load of the table (LFBK)
data from source to SAP HANA table.
Step-by-step is as below-

1. Source and Target system details are selected according to SAP SLT configuration.
2. Click on Load Button and select the table (LFBK) which we need to load/replicate in
SAP Hana.
3. Table (LFBK) will be added to Data Load Management Section with Action "Load" and
Status "Scheduled."

After data load, Status will be changed to "Executed". The table will be created in
"SLTECC" schema with data.

Step 3) Check Data in the table (LFBK) by Data Preview from Schema "SLTECC" as below
-.

1. Login in SAP HANA Database through SAP HANA Studio and select SAP HANA System
Sys tem
HDB (HANAUSER).
2. Select Table (LFBK) under Table node.
3. Right click on Table (LFBK) and click on Open data preview option.
4. Loaded Data through SLT process will be displayed in Data preview screen.

Now we have successfully loaded data in table "LFBK". We will use this table future in
Modelling.

SAP SLT Connection between non-SAP System and SAP HANA


SAP SLT Replication Server transforms all metadata table definitions from the non-ABAP
source system to SAP HANA.

For Non-SAP source, the SLT connection has following features -

 When a table is replicated, SAP SLT Replication server create logging tables in the
source system.
 Read engine is created in the SAP SLT Replication server.
 The connection between SAP SLT and SAP Source / SAP HANA is established as a DB
connection.
SAP SLT Connection between Non - SAP SLT Connection and SAP HANA
System/DATABASE

SAP SLT can only do simplest transformations, so for complex transformations, we


need another ETL tool such as SAP Data services.

SAP DS (SAP DATA Services)


SAP Data services is an ETL tool which gives a single enterprises level solution for data
integration, Transformation, Data quality, Data profiling and text data processing from
the heterogeneous source into a target database or data warehouse.

We can create applications (job) in which data mapping and transformation can be done
by using the Designer. (Latest version of SAP BODS is 4.2).

Features of Data Services


 It provides high-performance parallel transformations.
 It has comprehensive administrative tools and reporting tool.
 It supports multi-users.
 SAP BODS is very flexible with web-service based
ba sed application.
 It allows scripting language with rich sets of functions.
 Data Services can integrate with SAP LT Replication Server (SLT) , with the
Trigger-based technology. SLT adds delta-capabilities to every SAP or non-SAP source
table

Which allows for using data capturing for change and transferring the delta data of

the Source table.

 Data validation with dashboards and process auditing.


 Administration tool with scheduling capabilities and monitoring/dashboards.
 Debugging and built-in profiling and viewing data.
 SAP BODS support Broad source and target.
o Any Applications (e.g. SAP).
o Any Databases with bulk loading and changes data capture
o Files: fixed width, comma delimited, COBOL, XML, Excel.

Component of Data Services


SAP DATA services have below component  –

1. Designer- It is a development tool by which we can create, test, and execute a job
that populates a data warehouse.

It allows the developer to create objects and configure them by selecting an icon in a
source-to-target flow diagram.

It can be used to create an application by specifying workflows and data flows.

To Open Data Service Designer go to Start Menu -> All Programs -> SAP Data
Services (4.2 here) -> Data Service Designer.
2. Job Server- It is an application that launches the data services processing engine and
serves as an interface to the engine and Data Services Suite.
3. Engine- Data Service engine executes individual jobs which are defined in the
application.
4. Repository- Repository is a database that stores designer predefine objects and user
defined objects (source and target metadata, transformation rules).

Repository are of two types  –

 Local Repository (Used by Designer and Job Server).


 Central Repository ( Used for object sharing and version control)

5. Access Server- Access server passes messages between web applications, data
services job server and engines.
6. Administrator- Web Administrator provides browser-based administration of data
services resources detail is as below  –

 Configuring, starting and stopping real-time services.


 Scheduling, monitoring and executing batch jobs.
 Configuring Job Server, Access Server, and Repository usage.
 Managing users.
 Publishing batch jobs and real-time services via Web services
 Configuring and managing adapters.

Data Services Architecture –


Data Services architecture have the following component-

 Central Repository - it is used for repositories configurations to jobs servers, security


management, version control and object sharing
 Designer – Used for Create Project, Job, workflow, data flow and run.
 Local repository (here you could create change and start jobs, Workflow, dataflow).
 Job server & engine  – It manage the jobs.
 Access Server  – It is used to execute the real-time
real -time jobs created by developers in the
repositories.
In below image, Data Services and there component relationship is shown.
SAP BODS Architecture

Designer Window Detail: First we look into the first component of SAP data service-
Designer

Detail of each section of data service designer is as below-

1. Tool Bar (Used for Open, Save, Back, Validate, Execute, etc.).
2. Project Area (Contains the current project, which includes Job, Workflow, and
Dataflow. In Data Services, all entities are objects.
3. Work Space (The Application Window area in which we define, display, and modify
objects).
4. Local Object Library (It contains local repository objects, such as transforms, job,
workflow, dataflow, etc.).
5. Tool Palette (Buttons on tool palette enable you to add new objects to the
workspace).

Object Hierarchy

The below diagram shows hierarchical relationships for the key object types within Data
Services.
>
Note:

Workflows and Conditional* are optional

Objects used in SAP Data services detail is as below -

Objects Description

Project A project is a highest-level object in the Designer window. Projects provideyou with a wa
other objects you create in Data Services.Only one project is open at a time (where "ope
in the projectarea").

Job A "job" is the smallest unit of work that you can schedule independently forexecution.

Scripts A subset of lines in a procedure.

Workflow A "work flow" is the incorporation of several data flows into a coherentflow of work for a
Workflow is optional. Workflow is a procedure.

 Call data flows


 Call another work flow
 Define the order of steps to be executed in your job
 Pass parameters to and from data flows.
 Specify how to handle errors that occur during execution.
 Define conditions for executing sections of the project.

Dataflow A "data flow" is the process by which source data is transformed intotarget data. A data
object. It is always called from a work flow or a job.

 Identify the source data that you want to read.


 Define the transformations that you want to perform on the data.
 Identify the target table to which you want to load data.

Datastore Logical channel that connects Data Services


Services to source and Datastore target databases.

 Must be specified for each source and target database.


 Are used to import metadata for source and target databases into therepository
 Are used by Data Services to read data from source tables and load datato target tabl

Target Table or file in which Data Services loads data from the source.

Data Services example by load data from SAP Source Table


Everything in Data services is an object. We need to separate data store for each source
and target database.

Steps for loading data from SAP source table - SAP BODS have many steps, in which we
need to create a data store for source and target and map to them.

 Create Data Store between Source and BODS


 Import the metadata (Structures) to BODS.
 Configure Import Server
 Import the metadata to HANA system.
 Create Data Store between BODS to HANA.
 Create Project.
 Create Job (Batch/Real time)
 Create Work Flow
 Create Data Flow
 Add Object in Dataflow
 Execute the job
 Check the Data Preview in HANA
Step 1) Create Data Store between SAP Source and BODS

1. To Load data from SAP Source to SAP HANA through SAP BODS, we need a data
Store. So we create a Data store first as shown below  –

Project -> New - > Data Store


2. A pop-up for Create new data store will appear, enter detail as below -
1. Enter data store name "ds_ecc".
2. Select Data store type name as "SAP Applications".
3. Enter database server name
4. User name and password.
5. Click on "Apply" button.
6. Click on "OK" button.
3. Data Store will be created and view the created datastore as below-

1. Go to Local Object Library


2. Select DataStore tab.
3. Data store "ds_ecc" will be displayed.

Step 2) Import Metadata (Structure) to BODS Server.

We have created a data store for ECC to BODS; now we import metadata from ECC into
BODS. To import follow below steps -

1. Select Datastore "ds_ecc" and right click.


2. Select Import by Name option.
A pop-up for Import by Name will be displayed. Enter detail as below  –

1. Select Type as a table.


2. Enter Name of Table, which we want to import. Here we are importing KNA1
table.
3. Click On "Import" Button. KNA1 table will appear under table node of "ds_ecc"
data source.
Table Metadata will be imported, in datastore ds_ecc as below  –

Step 3) Configure Import Server

Till now we have imported table to data stored "ds_ecc" created for ECC to SAP BODS
Connection. To import data into SAP HANA, we need to configure Import server,

1. To do this go to Quick View-> Configure Import Server as below -


2. A pop-up for Select System will appear, Select SAP HANA (HDB here) System as
below-

3. Click on "Next" button. Another Pop-Up for data service credential will appear, enter
following details

1. SAP BODS server Address (here BODS:6400 )


2. Enter SAP BODS Repository Name ( HANAUSER Repositery Name )
3. Enter ODBC Data Source (ZTDS_DS).
4. Enter Default port for SAP BODS server(8080).
Click on "Finish" button.

Step 4) Import the metadata to HANA System

1. Till now we have Configured Import Server, now we will import metadata from SAP
BODS server.

1. Click Import option in Quick View.


2. A pop-up for Import option will be displayed. Select "Selective Import of
Metadata" option.
Click on "Next "Button.

2. A pop-up for "Selective Import of Metadata" will be display ed, in which we select
target System.

1. Select SAP HANA System (HDB here).


Click on "Next" Button.

Step 5) Create Data Store between BODS and HANA

As we know, in BODS we need to create a separate datastore for source and target. We
have already created a data store for the source, now we need to create a data store for
the target (between BODS and HANA). So, we create a new data store with
name"DS_BODS_HANA".

1. Go to Project -> New -> Datastore.

2. A screen for Create new Datastore will appear as below.


1. Enter Datastore name (DS_BODS_HANA).
2. Enter Datastore type as Database.
3. Enter Database type as SAP HANA.
4. Select Database Version.
5. Enter SAP HANA Database server name.
6. Enter Port name for SAP HANA Database.
7. Enter Username and password.
8. Tick on "Enable automatic data transfer".

Click on "Apply" and then "OK" button.

Data store "DS_BODS_HANA" will be displayed under datastore tab of Local Object
Library as

Below-
3. Now we import table in data store "DS_BODS_HANA".
1. Select data store "DS_BODS_HANA" and right click.
2. Select Import By Name.

4. A pop-up for Import by Name will appear as be below-


1. Select Type as Table.
2. Enter Name as KNA1.
3. Owner will be displayed as Hanauser.
4. Click on Import Button.
Table will be imported in "DS_BOD_HANA" datastore, to view data in table follow below
steps –

1. Click on table "KNA1" in data store "DS_BODS_HANA".


2. Data will be displayed IN TABULAR Format.

Step 6) Define Project: Project group and organize related objects. The Project can
contain any number of jobs, Workflow, and dataflow.

1. Go to Designer Project menu.


2. Select new option.
3. Select Project option.
A POP-UP for New Project Creation appears as below. Enter Project Name and Click on
Create Button. It will create a project folder in our case BODS_DHK.

Step 7) Define Job: A Job is a reusable object. It contains workflows and dataflow. Jobs
can be executed manually or as a schedule. To Execute BODS Process we need to define
the job.

We create a Job as JOB_Customer.

1. Select Project (BODS_DHK) created in step 1, Right click and select "New Batch Job".

2. Rename it to "JOB_Customer".
Step 8) Define Workflow:

1. Select Job "JOB_Customer" in project area,


2. Click the workflow button on the tool palette. Click on the Black Workspace area. A
workflow icon will appear in the workspace.
3. Change the name of the workflow as "WF_Customer".

Click the name of workflow, an empty view for the workflow appears in the workspace.

Step 9) Define Dataflow:

1. Click On Workflow "WF_Customer".


2. Click the Dataflow button on the tool palette. Click on the Black Workspace area. A
Dataflow icon will appear in the workspace.
3. Change the name of the Dataflow as "DF_Customer".
4. The Dataflow also appears in the project area on the left under job name.
Step 10) Add Object in Dataflow:

Inside data flow, we can provide instruction to transform source data into the desired
form for the target table.

We will see below object  –

 An object for the source.


 An object for the target table.
 An object for Query transform. (Query transform maps the columns from source to
target.)
Click on the dataflow DF_Customer . A blank workspace will appear as below -

1. Specify object from Source  – Go to Data store "ds_ecc " and Select table KNA1 and
drag and drop to data flow blank screen as below screen-
2. Specify object for Target- Select Data store "DS_BODS_HANA" from the repository
and select table KNA1.
3. Drag and drop to the workspace and select "Make Target "option. There will be two
table for source and target. Here we will define the table as source and target.
4. Query Transformation  – This is a tool used to retrieve data based on input schema
for user specific condition and for transport data from source to target.
1. Select Query Transform icon from tool Palette, and drag and drop it between
source and target object in workspace as below -
2. Link Query object to Source.
3. Link Query Object to Target table.
4. Double Click On Query Icon. By this, we map a column from input schema to
output schema.

When we click on Query icon, a next window for mapping will appear, in which we do
the following steps -

1. Source Table KNA1 is selected.


2. Select all column from the source table and right click and select a map to output.
3. Target Output selected as Query, and column will be mapped.

5. Save and Validate project.

1. Click on validate Icon.

2. A pop-up for validation success appear.


Step 11) Execute Job  – To execute Job, follow the below path-

1. Select Project Area icon to open Project, and select created Project.
2. Select Job and right click.
3. Select Execute option, to execute Job.
1. After Executing Job, a Job Log window is displayed, in which all message regarding
Job will be displayed.
2. The last message will be Job < > is completed successfully.

Step 12) – Validate / Check Data in SAP HANA Database.

3. Login to SAP HANA database through


thr ough SAP HANA Studio, and select HANAUSER
schema.
4. Select KNA1 table in Table node.
5. Right Click on table KNA1 and Select Open Data Preview.
6. Table (KNA1) Data loaded by BODS processes as above will be displayed in data
preview screen.
SAP HANA Direct Extractor Connection (DXC)
SAP HANA DXC uses existing ETL (Extract, Transform, and Load) method of SAP Business
Suite Application via a HTTPS connection. SAP HANA DXC is batch driven data replication
technique i.e. it can execute after a time interval.

In SAP Business suite application content Data Source Extractors have been available for
data modeling and data acquisition for SAP Business Warehouse.

SAP DXC use these Data Source Extractor to deliver data directly to SAP HANA.

Advantage of SAP DXC


 SAP DXC requires no additional server or application in the system landscape.
 It reduces the complexity of data Modelling in SAP HANA, as it sends the data to SAP
HANA after applying all business extractor logic in the source system.
 It speeds up SAP HANA Implementation time lines.
 It extract semantic rich data from SAP Business site and provide to SAP HANA.

Limitation of SAP DXC


 Data Source must have pre-define ETL method, if not then we need to define them.
 SAP DXC requires a Business Suite System on Net Weaver 7.0 or higher (e.g. ECC)
equal or below SP level: Release 700 SAPKW70021 (SP stack 19, from Nov 2008).
 A procedure with a key field defined must exist in Data Source .

Configure SAP DXC DATA Replication


Step 1) Enabling XS Engine and ICM Service

 Enabling XS Engine
Go to SAP HANA Studio  -> Select System -> Configuration -> xsengine.ini.

Set instance value to 1 in Default filed.

 Enabling ICM Web Dispatcher Service - It enables ICM Web Dispatcher service in
HANA system. Web dispatcher uses ICM method for data read and loading in HANA
system.
Go to SAP HANA Studio  -> Select System -> Configuration -> webdispatcher.ini
Set instance value to in default column 1.

Step 2) Setup SAP HANA Direct Extractor Connection

 Set DXC Connection in SAP HANA  – To create a DXC connection we need to import
delivery unit in SAP HANA as below -
 Import Delivery Unit.
You need to download the DXC delivery unit from SAP into SAP HANA database. You can

import the unit in the location

"/usr/sap/HDB/SYS/global/hdb/content".

Import the delivery unit using Import Dialog in SAP HANA Content Node ? Configure XS

Application server to utilize the DXC ? Change the application container value to
libxsdxc.

 Configure XS Application server to utilize the DXC.


Modify the application container value to libxsdxc (if any value existed, then append it).

Test the DXC Connection.

 Verify the DXC is working.


We can check DXC Connection by using below path in Internet Explorer  –

http://<hostname>:80<instance Number>/sap/hana/dxc/dxc.xscfunc

- Enter a user name and password to connect.


 User and Schema need to be defined in HANA Studio
 http connection in SAP BW for HANA need to define through SM59,
So create a http connection in SAP BW Using T-code SM59. Input Parameters will be

-- RFC Connection equal Name of RFC Connection

-- Target Host equal HANA Host Name

-- Service Number equal 80 <Instance Number >

Log on Security Tab Maintain the DXC user created in HANA studio which has basic
Authentication method.

 Data Sources in BW need to configure to Replicate the Structure to HANA defined


schema.
We Need to Setup the Following Parameters in BW Using Program
SAP_RSADMIN_MAINTAIN

(T-code SE38 or SA38)

Parameters List in Program  – Parameter list contains value , which pass value to call
screen.

PSA_TO_HDB: This three object values are shown as below -

 GLOBAL – This is used for replicate all data source to HANA


 SYSTEM – It Specified clients to Use DXC
 DATASOURCE –It specified Data Source, and only specified can be used.
PSA_TO_HDB_DATASOURCETABLE: In this we need to give the Table Name, which
having the List of data sources which are used for DXC.

o In the VALUE field, enter the name of the table you created.
PSA_TO_HDB_DESTINATION: In this we need to Move the Incoming data (in this we
need to Give the value which we create in SM59) ( here
XC_HANA_CONNECTION_HANAS)

PSA_TO_HDB_SCHEMA: It specifies which schema the replicated data need to assign

Data Source Replication

Install data source in ECC using RSA5. we have taken data source 0FI_AA_20

( FI-AA: Transactions and Depreciation). First we need to Replicate the Meta data Using
Specified application Component (data source version Need to 7.0 version. If we have
3.5 version data source, we need to migrate that first. Active the data Source in SAP BW.
)

Once data source loaded and activated in SAP BW, it will create the following table in
the Defined schema.

 /BIC/A<data source>00  – IMDSO Active Table


 /BIC/A<data source>40  – IMDSO Activation Queue
 /BIC/A<data source>70  – Record Mode Handling Table
 /BIC/A<data source>80  – Request and Packet ID information Table
 /BIC/A<data source>A0  – Request Timestamp Table
 RSODSO_IMOLOG - IMDSO related table. Stores information about all data sources
related to DXC.
Now data is successfully loaded into Table /BIC/A0FI_AA_2000 once it is activated. And
we can preview data from table /BIC/A0FI_AA_2000 in SAP HANA Studio.

Flat file Upload to SAP HANA


SAP HANA support uploading data from a file without ETL tools (SLT, BODS, and DXC). It
is a new feature of HANA Studio Revision 28 (SPS04).

SAP HANA Support following type of files which will be available on client system as
below –

 .CSV (Comma Separated value files)


 .XLS
 .XLSX
Prior to this option, the user needs to create control file (.CTL file). To upload data in
SAP HANA, table need to exist in SAP HANA. If table exits, records will be appended at
the end of the table, if table not present then table need to be created.

This application suggests column name and data type for the new tables.

Steps for upload data from flat file to SAP HANA is as below-

 Create the table in SAP HANA


 Create file with data in our local system
 Select the file
 Manage the mappings
 Load the data

Create the table in SAP HANA


If table are not present in SAP HANA, then we can create a table by SQL Script or by this
process by selecting "NEW" option.

We will use "NEW" option for creating a new table.

Create file with data in our local System


We are going to upload Sales Organization master data. So create a .csv file and .xls file
for it on local system.

We are going to upload SalesOrg.xlsx file into SAP HANA, so we have created a file
SalesOrg.xlsx in the local system.

SalesOrg Name Currency CoCode Address Country Ref_Sorg

1000 ABC Pvt. Ltd. USD 1000 NEW YORK USA 1000

2000 ABC Enterprises INR 2000 INDIA INDIA 2000

Select the file


Step 1) Open modeler perspective ? 'Main Menu' ? 'Help' ? 'Quick View' as shown
below.
A Quick View screen appears as below-
Select 'Import' option from Quick View. A pop-up for import option will be displayed.
A Pop-Up for import screen is displayed. Go to SAP HANA Content? 'Data from Local
File'.
Click Next.

A pop-up for File selection will be displayed, follow below steps for the select file.

1. Select SalesOrg.xls file.


2. Click on "Open" button.
A screen for file selection for import will be displayed ,in which we can select a file for
loading data from local system to SAP HANA database.

Available options can be categorized into three main areas, they are

 Source File Section


 File Details Section
 Target Table
Step 2) In this step we have to enter following detail -

1. Select File  – Selected file path will be displayed here.


2. Header Row Exits  – If SalesOrg.xls file has a header (column Name). So, we have
ticked it.
3. Import All Data  – Tick this option if you want to import all data from a file, otherwise
mention Start Line and End line for specific data load fr om file.
4. Ignore leading and trailing white space Tick this option for ignoring leading and
trailing white space in the file.
5. Target Table  – In this section two option  –
New – If the table is not present in SAP HANA, then choose this option, and provide
Exiting schema name and table name to be created.

Exiting – If the table exist in SAP HANA, then choose this option. Select Schema name
and Table. Data will be appended to end of the table.

6. Click on "Next" button

Manage the Mappings


A mapping screen will be used for performing the mapping between source and target
columns.
There are two different types of mapping available.When we click on we get two
option as below -

 One to One: By using this option, we can map column to column based on the
sequence. This option can be used if we know all the columns are in sequence.
 Map by Name: By using this option, we can map the source and target columns
based on the name. This can be used if we know that the columns names are same.
Mapping of Source to Target  – We will map here Source File column to Target Table,
and also, we can change target table definition.

1. Proposed Table structure from Source File- Table column Name is supposed from
excel file Column Name (Header).
2. Target Table Structure: Target Table store type is selected as column store by
default.
3. Click File name and drag to target field, File will be mapped. The field can be mapped
automatically by one to one or map By Name option. we can manually do the
mapping using drag and drop option If our column name could not be mapped
with the above options.
4. In the File data section of the same screen, we can also see how the data looks in the
source file for all the columns.File data section displays data of SalesOrg file.
5. Click on "Next" file.
A window for import data from the local file will appear.

Load the data


It is final screen before we start the loading process. By this screen data that already
exist in the table will display and also the information about the schema and table to
which we are going to load the data will display.

1. Detail Sections: In this section Selected Source File name, Target Table Name, and
Target Schema Name detail will be displayed.
2. Data from File: It will display data extracted from the file.
3. If displayed data in Data from file section has been verified, click 'Finish' to Start
loading the data to the table.
 After successful import option completing, we should see the entry in the job log
view with status 'Completed Successfully.'

 Once the data importing job is successful,


1. We can see the data in table of by selecting the table of respective schema and
right click on Table ? 'Data Preview' as shown below.
2. Data of table will display in Data preview screen as below-