How to Use Mixed Strategies in SAP BW/4HANA Modelling: A Practical Guide (Part 1)

How to Use Mixed Strategies in SAP BW/4HANA Modelling: A Practical Guide

SAP BW/4HANA is a modern data warehouse solution that leverages the power and flexibility of the SAP HANA platform. It offers various features and functionalities for data modelling, integration, transformation, quality, security, governance, and reporting. However, SAP BW/4HANA is not the only option for data modelling in the SAP landscape. You can also use SAP HANA native tools, such as SAP HANA Studio or SAP Web IDE, to create data models directly on the SAP HANA database. These models can be based on tables or views from any schema in the SAP HANA database, including the SAP BW/4HANA-managed schema.

But what if you want to combine the best of both worlds? What if you want to access and integrate data from both SAP BW/4HANA and SAP HANA native models? This is where mixed strategies come in handy. Mixed strategies are the combination of different data modelling approaches that are available in the SAP system. They allow you to access and merge data from SAP BW/4HANA and SAP HANA native models, using virtual or replication methods. In this blog post, we will explore some use cases of mixed strategies in SAP BW/4HANA modelling, and show you how to implement them step by step.

Use Case 1: Accessing SAP HANA Native Data from SAP BW/4HANA

One of the most common use cases of mixed strategies is to access data from any schema in the SAP HANA database from SAP BW/4HANA. This can be useful when you have external data sources, such as ERP systems, IoT devices, social media, etc., that are stored in SAP HANA tables or views, and you want to integrate them with your SAP BW/4HANA data models. For example, you may want to:

  • Enrich your SAP BW/4HANA data with additional attributes or measures from SAP HANA native models
  • Perform cross-system reporting and analytics on data from both SAP BW/4HANA and SAP HANA native models
  • Enable self-service data exploration and visualization on data from both SAP BW/4HANA and SAP HANA native models

There are two main ways to access data from any schema in the SAP HANA database from SAP BW/4HANA: virtual access and replication.

Virtual Access

Virtual access means that you can access the data from the source system without physically copying or storing it in SAP BW/4HANA. This has the advantage of saving storage space and reducing data redundancy. However, it also has some drawbacks, such as:

  • The performance may depend on the network bandwidth and the source system availability
  • The data quality and security may not be consistent with the SAP BW/4HANA standards
  • The data may not be available for further processing or transformation in SAP BW/4HANA

There are two main options for virtual access: CompositeProvider and Open ODS View.

CompositeProvider

A CompositeProvider is a flexible way to combine data from multiple SAP BW/4HANA InfoProviders and SAP HANA views by using unions and joins. You can use a CompositeProvider to create a reporting view on top of your data sources, without persisting any data in SAP BW/4HANA. A CompositeProvider is especially recommended when the SAP HANA view displays a complete star schema, with facts and dimensions.

To create a CompositeProvider with virtual access to a SAP HANA view, follow these steps:

  • In the SAP BW Modeling Tools (Eclipse), right-click on your InfoArea and select New > CompositeProvider.
  • Enter a technical name and a description for your CompositeProvider.
  • In the Scenario tab, drag and drop your source InfoProviders and/or views from the Data Source Browser to the canvas.
  • Connect your sources by using unions or joins as needed.
  • Define the output fields by selecting or deselecting the fields from each source.
  • Save and activate your CompositeProvider.

Open ODS View

An Open ODS View is another way to define a reporting view on external data sources, such as database tables or views from any schema in the SAP HANA database. An Open ODS View allows you to model your data at the field level, without creating any InfoObjects or persisting any data in SAP BW/4HANA. An Open ODS View can be complemented by InfoObjects and gradually extended to have a higher level of integration. An Open ODS View is especially recommended when the external data source displays a pure fact view or a pure dimension view.

To create an Open ODS View with virtual access to a database table or view, follow these steps:

  • In the SAP BW Modeling Tools (Eclipse), right-click on your InfoArea and select New > Open ODS View.
  • Enter a technical name and a description for your Open ODS View.
  • In the Source System tab, select Database Table or View as the source type.
  • In the Source Object tab, select the schema and the table or view from the SAP HANA database.
  • In the Fields tab, select or deselect the fields from the source object.
  • Optionally, assign InfoObjects to the fields or define key figures and units.
  • Save and activate your Open ODS View.

Replication

Replication means that you can copy or store the data from the source system in SAP BW/4HANA. This has the advantage of improving the performance and availability of the data, as well as ensuring the data quality and security according to the SAP BW/4HANA standards. However, it also has some drawbacks, such as:

  • The storage space and data redundancy may increase
  • The data may not be up to date with the source system
  • The data may require additional processing or transformation in SAP BW/4HANA

There are two main options for replication: SAP HANA Source System and Smart Data Integration.

SAP HANA Source System

A SAP HANA Source System is a way to connect your SAP BW/4HANA system to any schema in the SAP HANA database, and replicate data from SAP HANA tables or views to SAP BW/4HANA InfoProviders. You can use a SAP HANA Source System to create a data flow that extracts, transforms, and loads (ETL) data from SAP HANA to SAP BW/4HANA. A SAP HANA Source System is especially recommended when you want to have full control over the ETL process and apply complex business logic or transformations to your data.

To create a data flow with a SAP HANA Source System, follow these steps:

  • In the SAP BW Modeling Tools (Eclipse), right-click on your InfoArea and select New > Data Flow.
  • Enter a technical name and a description for your data flow.
  • In the Data Source tab, select SAP HANA as the source system type.
  • In the Schema tab, select the schema from the SAP HANA database.
  • In the Object Name tab, select the table or view from the SAP HANA database.
  • In the Target tab, select an existing or create a new InfoProvider as the target object.
  • Save and activate your data flow.
  • Optionally, edit your data flow by adding transformations, filters, routines, etc.

Smart Data Integration

Smart Data Integration (SDI) is a feature of SAP HANA that allows you to connect to various data sources, such as databases, files, web services, etc., and replicate data to SAP HANA tables or views. You can use SDI to create a virtual or physical replication scenario that transfers data from any source system to any schema in the SAP HANA database. You can then use this schema as a source system for your SAP BW/4HANA modelling. SDI is especially recommended when you want to have a fast and flexible replication scenario that supports real-time or batch modes, delta or full loads, and various transformations.

To create a replication scenario with SDI, follow these steps:

  • In the SAP Web IDE for SAP HANA (Web Browser), open the Database Explorer and connect to your SAP HANA database.
  • Right-click on your target schema and select New > Table.
  • Enter a technical name and a description for your target table.
  • Define the columns and data types for your target table.
  • Save and deploy your target table.
  • Right-click on your target schema and select New > Flowgraph.
  • Enter a technical name and a description for your flowgraph.
  • Drag and drop your source object from the Catalog Browser to the canvas.
  • Drag and drop your target table from the Catalog Browser to the canvas.
  • Connect your source object and your target table by using an operator, such as Projection, Join, Union, etc.
  • Define the mapping and transformation rules for your operator.
  • Save and deploy your flowgraph.
  • Optionally, edit your flowgraph by adding filters, calculations, aggregations, etc.

For Part 2, click on the below link: