How to Upload Data from Flat Files to HANA


You use this procedure to upload data from flat files, available in a client file system to SAP HANA
database. If the table schema corresponding to the file to be uploaded already exists in the SAP HANA
database, the new data records are appended to the existing table. If the required table for loading the
data does not exist in the SAP HANA database, create a table structure based on the flat file. The
application suggests the column names and data types for the new tables and allows you to edit them.
The new table always has a 1:1 mapping between the file and table columns. The application does not
allow you to overwrite any columns or change the data type of existing data. The supported file types
are .csv, .xls, and .xlsx.


Procedure (HANA Studio)
1. In the File menu, choose Import.
2. In the Select an import source section, expand the SAP HANA content node.
3. Select Import Flat File, and choose Next.
4. In the Target System section, select the target system where you want to import the data using the
flat file, and choose Next.
5. On the Flat File Upload screen, browse for the file containing the data you want to upload.
6. If you have selected a CSV file, select a delimiter.
Note:
A delimiter is used to determine columns and pick the correct data from them. In a csv file, the
accepted delimiters are ',', ';' and ':'.
7. If you have selected an .xls or .xlsx file, select a worksheet.
8. If you want to load the data into a new table, select the New option and perform the following
substeps:
a. Choose Next.
b. On the Manage Table Definition and Data Mapping screen, map the source and target columns.
Note:
• Only 1:1 column mapping is supported. You can also edit the table definition by changing the
data types, renaming columns, adding or deleting the columns, and so on.
• You can choose to map the source and target columns using the Auto Map option. If you
choose the one to one option then first column of the source is mapped with the first column
at the target. If you choose the option Map by name, the source and target columns with same
name are mapped.
9. If you want to append the data to an existing table, select the Existing option and perform the
following substeps:
a. Choose Next.
b. On the Manage Table Definition and Data Mapping screen, map the source and target columns.
10. Choose Finish.


Tags: How to Upload Data from Flat Files to HANA, How to Upload Data from Flat Files to SAP HANA,
HANA How to Guides , Uploading Data from Flat Files from client  to HANA, load csv file into hana studio table,
Share this article :

Post a Comment

 
Copyright © 2011. SAP HANA TUTORIALS FREE - S/4 HANA - All Rights Reserved