Resources - Blog

SAP BW Advanced Modelling part 2 Composite Provider

  • WRITTEN BY : SHIVA ALURI
  • ON : 4 Sep, 2017
  • IN : BW/4 HANA



e DataFlow Object

Right-click on Data Flow Object

When creating the Dataflow object a transport request opens up.

Afterwards add a new or existing Datasource by drag and drop to the Details:

Double click on the entered Datasource leads to the following properties:

Select a Source System and if you want a copy from an existing or a proposal from an ODP connection

By clicking on the „NEXT“ button the Dataflow is shown – now it is possible to add any other object to the dataflow.

In this example an ADSO was added and filled with three InfoObjects

 

Now you created a persistent ADSO.

Activate the newly created ADSO. Create a connection between the newly created ADSO and the previously created Datasource

Now you’ll see a transformation and DTP creation is possible based on the connection.

Right-click on the transformation symbol and select “Create Transformation … “

Now you are able to create a transformation – Target and Source are filled automatically:

 

Here you are able to define all settings for the transformation as well as connect to the fields from the previous ADSO

 

In addition, if infoObjects are available in the source – they are automatically connected. Don’t forget to activate!

Same for the creation of the DTP. All DTP properties can be selected. You can see/select/change all the properties already known in BW.

Same process for the composite provider – drag and drop the composite provider, assign a name and create a connection to the ADSO.

 

It is also possible to add a comment for the specific selections within the dataflow. Click the one you want to comment on – go to the properties section and add documentation.

Conclusion

As you could experience, the Dataflow object is an easy way to model your intended dataflow. You can see all the different stages on one side in one place and do not have to click yourselves through your modelled dataflow, which can be difficult and time-consuming with two different tools either the Eclipse modelling tool and the SAP GUI.

Although it is a simple way to create a complete dataflow it does not replace process chains for loading data as it is moreover a graphical view of your model. For loading the data into your model you also need to create a process chain.

Finally I’ve put together some hints which will make your work easier:

  • Create Persistent Objects of ADSO, InfoSources, HCPR directly out of DataFlow Maintenance Screen
  • You can use Templates eg. Datasource or Infosource as templates and more.
  • When you have a SourceObject like an Infosource and a Target object like an ADSO, first create the connection in between before persisting the ADSO, then all fields/InfoObjects of the source are automatically taken into account for the DataModel of the Target.
  • Execution of DTP’s is possible
  • if you want to use DTP Monitor you have to execute the DTP in the DTP Maintenance Screen, from here the InPlace GUI is being called.

Composite providers

The SAP BW Composite Provider is used to bring the data together from in-memory data targets/InfoProviders. This InfoProvider can leverage both union and join operations to combine.
 

Purpose of Composite provider:  one modeling InfoProvider (semantic layer) combining BW and HANA objects with either Join or Union.     

UNION and JOIN operations are executed in HANA and not the application server. BEx queries can be created on Composite Providers as on any other BW InfoProviders.
 

Modeling Scenario using Composite Provider:

With the new Composite provider it is possible to realize the dream of storing the same data only once at least for this scenario. The following case shows how we can model the same scenario using a composite provider and thus make use of the calculation capabilities of HANA DB.

In transaction RSLIMOBW, we create a Composite provider that uses the 3 Data store objects, Sales Transaction, Customer Master and Product Master as shown below.
 

How this works:

  • The Sales transaction DSO is taken in the Composite Provider with Binding Type “Union”. By default there should be at least one Info provider of type Union in the Composite provider.
  • The fields of Sales Transaction DSO are dragged into the Central Composite Provider.
  • The Customer Master and the Product Master DSO are added to the Composite provider with the binding type “Join”.
  • Master data fields required in the composite provider are dragged and dropped into the composite provider. (These are the fields for which look-ups were written in the original scenario).
  • The fields Customer number and Calmonth are used as Join fields and a join condition is drawn between the Sales DSO and the Customer Master.
  • Similarly Product number and Calmonth are joined from the Product DSO with the composite provider.
  • In this way, the composite provider will contain all the records present in the Sales transaction DSO with the corresponding attributes filled based on the Calendar Month.
  • The Joins and Unions are executed at the query execution time. UNION and JOIN operations are executed in HANA DB.
  • Note that SID generation option should be checked in the DSO for it to be available as a data provider for Composite provider.

Benefits of Composite Provider over MuliteProvider:

  • BW InfoProviders can be combined using JOIN operation allowing us to create new scenarios not possible or very expensive with standard techniques (Multiprovider, InfoSet)
  • Composite providers can be modeled using the DSOs in the EDW layer itself.
  • The time taken for performing look-ups to derive attributes is also saved during loading.
  • Ability to combine BW InfoProviders and HANA tables/views via UNION or JOIN
  • Faster and simpler data modeling - successor to MultiProvider and InfoSet
  • Reduce database size: virtual modeling capabilities as opposed to data flows
  • Flexibility : Further to what is shown above and as in the case with most of the real time systems, not just one DSO loads to a cube. In that case, a Multiprovider is created on top of these DSOs can also be used in the Composite provider to deliver the desired results
  • Supports usage of inventory key figures and planning scenarios.

Creation of Composite provider.

Log on to the BW Modeling Perspective with your BW credentials and attach your HANA system using the context menu on your top project level folder, choosing the option Attach HANA system, without which you will not be able to include native SAP HANA models in your Composite Provider.

Navigate to InfoArea under BW Project → Context menu → New → Composite Provider.
 

Enter the Composite Provider name and description. Click Next.
 

Then  click on the Add sign, you will be prompted if you want to select an InfoProvider or HANA view. To perform a search, enter ‘?’ and you will see a list of available objects. Select any object that you want to add to the Composite Provider.

Similarly, add an InfoProvider to your Composite Provider. Next is to add the fields from Source to Target by dragging the fields. You can use Expand all to expand all the objects added. You can also apply a filter to search a particular field.” Note that at least one field should be drop on join condition”.

Composite Provider created by using JOIN.
 

Composite Provider created by using UNION.
 

Go to the output tab and you can see the mapping of added objects.
 

Next is to check and activate BW object.
 

To preview the data in HANA Studio, use the magnifying glass icon in the upper right corner → Show Preview.
 

You can also analyze the result in the Problems log of this perspective.