Using the Scenario Generator to Generate Data Subscriptions

Objective

After completing this lesson, you will be able to use the scenario generator to generate data subscriptions.

Scenario Generator

We have explained how to manually define a data subscription for an SAP BW object. However it's also possible to use the Scenario Generator to generate multiple data subscriptions, making sure that dependency and semantic relations between SAP BW objects are kept.

Understanding the Scenario Generator

The Scenario Generator is designed to simplify the replication of complex SAP BW models.

Instead of manually creating individual data subscriptions for every SAP BW object, the Scenario Generator allows you to reconstruct an entire SAP BW model, such as a DataStore object (advanced) or a CompositeProvider, as local tables (file) in SAP Datasphere in one comprehensive operation.

A scenario acts as a blueprint, containing a list of references between data subscriptions required to represent a specific model and all its dependencies. By using the Scenario Generator, you ensure that the system extracts not only the top-level object, but also all associated SAP BW objects and underlying semantics, maintaining the integrity of your data architecture within SAP Business Data Cloud.

Using the Scenario Generator

The figure shows a screenshot of the perspective BW Data Product Generator in the BW Modeling Tools in Eclipse.

The Scenario Generator is used within the BW Modeling Tools in Eclipse. A separate perspective BW Data Product Generator is available which includes the views Scenario Generator (Data Subscriptions) and Data Subscriptions.

Note

As a prerequisite for using the Scenario Generator and the Data Subscriptions views, you need to install the BW Modeling Tools in the latest version or upgrade your existing installation to the latest version BWMT 1.27. To use the BW Data Product Generator perspective, you need to at least upgrade the BW Modeling Tools to the patch version BWMT 1.27.1.

Replicating SAP BW models using the Scenario Generator follows a structured workflow:

  1. Select SAP BW objects
  2. Build the scenario tree
  3. Generate and activate data subscriptions
  4. Run data subscriptions

Select SAP BW Objects

The figure shows a screenshot of the Scenario Generator: the context menu to add an SAP BW object.

As a first step, you use the Scenario Core Objects tab to define the SAP BW object(s) that serve as the foundation for your replication scenario.

The figure shows a screenshot of the Scenario Generator: the settings of the objects to be collected.

While defining core objects, you must configure several mandatory and optional settings that govern how the data subscriptions will be generated. A critical requirement is the selection of a Target Name. This defines the specific SAP Datasphere tenant or space where the extracted data will be stored. To ensure consistency and successful generation, all data subscriptions within a single scenario must share the same target.

In addition to the target, you can refine the scope of the scenario using the following configurations:

  • Collection Grouping: Determines the depth of the dependency search. You can choose to collect Only Necessary Objects (recommended) or include the entire data flow before and after the selected objects.
  • Association Levels: Defines how many levels deep the system should scan the dependency tree. The default is set to 4 levels.
  • Process Chain Variant: An optional setting that allows you to automate the extraction later by assigning the data subscriptions to a specific process chain.
  • Perform Target Check: Checks connection for selected target in advance. This allows to avoid or resolve connection errors due to faulty target configuration before even trying to generate new data subscriptions for the scenario.
  • Consider Transport Configuration: When enabled, this allows you to assign data subscriptions to a transportable package instead of the local $TMP package, enabling movement between development and production systems.
  • Use existing data subscriptions: Includes existing data subscriptions in the scenario tree so that they won't be duplicated. If you select this option, the scenario tree in Collected Objects will also show the existing data subscriptions for the objects.
  • Hide non relevant objects: Hides objects from the scenario tree for which you can't create any data subscriptions, such as 0CALDAY. This allows to build a cleaner scenario tree.

Build the Scenario Tree

The figure shows a screenshot of the Scenario Generator: The button 'Collect' is highlighted.

As the next step, choose Collect to collect all top-level objects and dependent objects of the selected SAP BW objects and create the scenario tree.

The figure shows a screenshot of the Scenario Generator: the result (collected objects) of the collection.

Once the collection process is complete, you can view the results in Collected Objects on the Object Relations tab. The scenario tree displays the following details for each identified object:

  • Object Name: The technical name of the SAP BW object or dependent component.
  • Data Subscription: A green check mark indicates if a subscription already exists for that object (provided Use existing data subscriptions was selected).
  • Target Name: Name of the SAP Datasphere tenant for the existing data subscription.
  • Process Chain Variant: If you have selected Use existing data subscriptions, it shows the process chain variant of the data subscription, if it already exists.
  • Association Type: Describes the specific relationship between the parent object and the dependent object.
Review the tree carefully to ensure all required semantics and InfoObjects are included before proceeding to the generation step.

Generate and Activate Data Subscriptions

The figure shows a screenshot of the Scenario Generator: the preview of selected data subscriptions are listed. It also shows the context menu to edit a single subscription.

On the Selection to Generate Data Subscriptions section on the Object Relations tab, you can preview all data subscriptions that the system is prepared to create. The list provides essential details for each entry:

  • Data Subscription: Displays the auto-generated technical name and the source object.
  • Status: Shows the status of the to-be-created data subscriptions.
  • Selections: Shows if you have defined filter selections for the data subscription.
  • Projection: Shows which fields are included or excluded for the data subscription.
  • BW Object: Shows the name of the source object (SAP BW InfoProvider) for the data subscription, as well as the object type.
  • Target: Shows the name of the target you have selected for the data subscription.
  • Package: Shows the assigned transport package. By default, objects are assigned to the local $TMP package.

It's optional to edit data subscriptions in the data subscriptions list. You can change the following settings:

  • Description
  • Package
  • Extraction Mode
  • Process Chain Variant
  • Target Name
  • Selections
  • Projection
The figure shows a screenshot of the Scenario Generator: the preview of selected data subscriptions are listed. It highlights the Mode and the Generate button.

The next step is the mass generation of data subscriptions by converting the blueprint defined in your scenario tree.

You first have to select a Mode to determine how the system handles the activation of the new data subscriptions:

  • Activate in Background: This is the recommended mode. It processes the activation without consuming immediate interface resources, allowing you to continue working while the system handles the task.
  • Activate Directly: The system attempts to activate all data subscriptions immediately. This can be resource-intensive and may cause the interface to hang during large operations.
  • No Activation: The data subscriptions are created but remain in an inactive state. You must activate them manually later using the Data Subscriptions app in the SAP BW/4HANA Cockpit or using transaction code RSDPS in SAP GUI before they can be run.

After selecting the mode, choose Generate. The system mass-creates the data subscriptions.

The figure shows a screenshot of the Scenario Generator: the generated data subscriptions.

The outcome is displayed on the Messages tab. Here, you can see the status of the creation of the data subscriptions. If activation has been selected in Mode, it will also show the status of the activation of the generated data subscriptions.

The figure shows a screenshot of the data subscriptions list.

The Data Subscriptions view shows the data subscriptions list. You can select Read scenario references in the preferences of the view to retrieve information about the associated scenarios of the data subscriptions (if they have been created via the Scenario Generator). The setting also offers options to Show Scenario Subscriptions Only and Delete Scenario.

In the following exercise, you use the scenario generator to generate data subscriptions for SAP BW Data.

Run Data Subscriptions

After you have generated and activated the data subscriptions, the next step is to run these subscriptions, either via a scheduled process chain or manually. Like the other data subscriptions, which are created manually and not with the Scenario Generator, you have to use the Data Subscriptions app in the SAP BW/4HANA Cockpit or transaction code RSDPS in the SAP GUI to run them.