Connecting to SAP HANA Database

SAP HANA is a database management system used for storing and retrieving data through specified applications. Centerprise let’s you use SAP HANA as one of your database source or destination. A database source or a database destination object can be used to connect to SAP HANA database. Other objects can also be used, such as lookups, SQL script task in a workflow, database write strategies and in any other object where connecting to a database is supported in Centerprise.

To learn more about SAP HANA and its installation, click here.

In this article we will see how SAP HANA can be configured as a database in Centerprise. To connect SAP HANA database, we’ll be using the Database Table Source connection and see how it can be configured.

Using SAP HANA in the Database Table Source

1. To configure the Database Table Source object, right-click on its header and select Properties from the context menu.

A screenshot of a cell phone  Description automatically generated

As soon as you’ve selected the Properties option from the context menu, a dialog box will open.

A screenshot of a cell phone  Description automatically generated

This is where you can configure the properties for the Database Table Source object.

2. The first step is to specify the Database Connection for the source object.

  • You will find a drop-down list next to the Data Provider.

    This is where you select the SAP HANA database as your data provider to connect to.

A screenshot of a social media post  Description automatically generated

  • Put in the required credentials for your SAP HANA data provider account.

A screenshot of a cell phone  Description automatically generated

  • Test Connection to make sure that your database connection is successful and click Next.

img

3. Next, you will see a Pick Source Table and Reading Options screen. On this screen, you will select the table from your SAP HANA database, and configure the table from the given options.

A screenshot of a cell phone  Description automatically generated

  • From the Pick Table box, choose the table that you want to read the data from.

img

Note: We will be using the Orders table in this case.

img

  • Once you pick a table, an icon will show up beside the Pick Table box.

img

  • View Data: You can view data in a separate window in Centerprise.

img

  • View Schema: You can view the schema of your database table from here.

img

  • View in Data Source Browser: You can see the selected table in the Data Source Browser in Centerprise.

img

Table Partition Options

This feature substantially improves the performance of large data movement jobs. Partitioning is done by selecting a field and defining value ranges for each partition. At runtime, Centerprise generates and runs multiple queries against the source table and processes the result set in parallel.

img

  • Check on the Partition Table for Reading if you want your table to be read in partitions.
  • You can specify the Number of Partitions.
  • Pick Key for the Partition box will let you choose the key field for partitioning the table.
  • If you have specific key values based on which you want to partition the table, you can use the option ***Specify Key Values (Separated by comma)***.

Favor Centerprise Layout

It is useful in the cases where your source database table layout has changed over time, but the layout built in Centerprise is static. And you want to continue to use your dataflows even with the updated source database table layout. You check this box and Centerprise will favor its own layout over the database layout.

img

Dynamic Layout

It is used when your dataset is not static and may require changes (either addition or deletion of columns/fields) during run time.

img

Incremental Reads Options

There are two read strategies that are supported in Centerprise for Incremental Reads Option.

  • Select Full Load if you want to read the entire table.

img

  • Select Incremental Load Based on Audit Fields to perform an incremental read. Centerprise will start reading the records from the last read.

img

  • Checking on Perform full load on next run, will override the incremental load function from the next run onwards and will perform a full load on it.
  • Use Audit Field to compare when the last read was performed on the dataset.
  • Specify the path to the file in the File Path, that will store incremental transfer information.

4. The next screen will show you a Layout Builder. On this screen, you can modify the layout of your database table.

img

Note: By default, Centerprise reads the source layout. Modifying the layout (adding or deleting fields) from the layout builder screen in Centerprise will not make any changes to the actual database table. The layout is only specific to Centerprise.

5. After you’re done customizing the Layout Builder, click Next. You will be taken to a new screen - Where Clause. Here, you can provide a WHERE clause, which will filter the records from your database table.

Note: If the wizard is left blank Centerprise will use the default values of the database table.

A screenshot of a social media post  Description automatically generated

6. Once you’ve configured the database table source object, click Next.

A screenshot of a social media post  Description automatically generated

7. A new screen - Config Parameters will open. Here, you can define parameters for the Database Table Source object.

Parameters can provide easier deployment of flows by eliminating hardcoded values and provide an easier way of changing multiple configurations with a simple value change.

A screenshot of a cell phone  Description automatically generated

Note: Parameters can be changed in the Config Parameters wizard page. Parameters left blank will use their default values assigned on the properties page. Defined parameters will work at runtime.

8. Click OK.

A screenshot of a social media post  Description automatically generated

img

You have successfully configured SAP HANA as your database provider for your Database Table Source object. The fields from the source object can now be mapped to other objects in a dataflow.