Data flows play a crucial role in managing the extraction, transformation, and loading (ETL) of data.Data flows are purpose-built for robust data handling — enabling both complex transformations and the permanent persistence of structured data into target tables.This makes them a powerful tool for building scalable, maintainable, and performance-optimized data pipelines within SAP Datasphere.
In this blog post, we’ll focus on how to integrate Open SQL Schema Tables within Data Flows - a powerful option for handling specific enterprise integration scenarios.
Why Use Open SQL Schema Tables Instead of Datasphere Local Tables?
While this blog is centered on how to use Open SQL Schema Tables, it's useful to understand a few real-world use cases where they offer clear advantages over Datasphere Local Tables:
1. Restricted Access Due to Enterprise Security Protocols
In some organizations, strict security and infrastructure policies restrict direct access to core systems. For instance:
In such cases, Open SQL Schema Tables act as a bridge: data extracted from third-party systems via MuleSoft APIs can be loaded into Open SQL Schema Tables, which can then be used as a source or target in SAP Datasphere. Datasphere Local Tables cannot be directly exposed to external systems, making Open SQL Tables essential here.
2. Sharing Forecast Data with External Systems
Imagine you're working on a forecasting project that involves:
You have two options:
These are just a couple of scenarios—there are many others where Open SQL Schema Tables are the more viable solution.
How to Use Open SQL Schema Tables in a Data Flow
Here is a step-by-step guide to integrating Open SQL Schema Tables within your SAP Datasphere Data Flows:
Step 1: Create a Database User
Step 2: Create and Populate the SQL Table
Step 3: Create the Data Flow
Step 1: Creating a database user
Please follow the steps mentioned here - Creating a Database User
Step 2: Creating a table and inserting records in it.
Go to Space Management - Select the right space - Click on edit - Go to Database Access - Select the Database User and then Click on "Open Database Explorer"
It will open another tab, please login in database explorer with your S user. Once you login to Database Explorer , we need to add hana database.
You can find the host details in Space Management - Database Access
Create and Insert Script :
CREATE COLUMN TABLE EMP_ID
(EMP_ID INT PRIMARY KEY,
EMP_NAME NVARCHAR(1000),
EMP_COUNTRY NVARCHAR(500)
);
--------
INSERT INTO EMP_ID VALUES (100,'Paul John','United State');
INSERT INTO EMP_ID VALUES (101,'Mike Hussey','Canada');
INSERT INTO EMP_ID VALUES (102,'William Jack','United Kingdom');
--------
SELECT * FROM EMP_ID;
Step 3: Creating a Dataflow with SQL schema table as a source and Datasphere local table as a target.
To build a data flow that reads from an SQL schema table and writes to a Datasphere local table, follow these steps:
4.)Choose a target table for your data flow. You have three options:
Note:
If you choose to create a new target table within the data flow, you will be required to Create and Deploy the table before executing the data flow.
5.)Map the source columns to their corresponding target columns to define the data transformation logic.
Choose the appropriate load mode based on your use case:
Once the column mappings and load mode are configured, deploy the Data Flow.
6.)Then run the dataflow and do the data preview.
Once the data flow is run, it can be scheduled or monitored from Data Integration Monitor Tab.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 54 | |
| 33 | |
| 23 | |
| 21 | |
| 19 | |
| 16 | |
| 15 | |
| 15 | |
| 14 | |
| 10 |