Creating Calculation Views to Consume Live Output Datasets

Your users have generated predictions in a live dataset and now want to use the results in SAP Analytics Cloud live BI stories.

Context

Once your users have generated predictions in a live dataset, predictions are stored in tables in the write-back schema of your SAP HANA on premise system. So that your users can consume these predictions in SAP Analytics Cloud, you need to create at least one calculation view (or add the table containing predictions and join it with actuals in the calculation views if the view already exists).
Caution

The process described below can slightly change depending on your SAP HANA version. Make sure to consult the SAP HANA documentation reletated to your current version when you click on one of the related links. You can easily navigate to your documentation version by using the dropdown buttons in the help portal.

Tip
Collect the write-back schema name and the data source name information by displaying the live output dataset from the Files section of SAP Analytics Cloud.
Note

The data source name is currently truncated and the copy and paste function is not available. Hover on the data source name to see the full ID data source name to identify the table (this mean that in some very unlikely case, there might be several tables with same starting ID).

Procedure

  1. Open SAP HANA Studio (following steps can also be done through SAP Web IDE). For more information on SAP HANA Studio you can refer to SAP HANA Studio, and for more information on SAP Web IDE, refer to Create Graphical Calculation Views
  2. Connect to the SAP HANA on-premise system that corresponds to the remote data repository used in the Smart Predict training and application workflows.
    Caution
    Make sure your user has sufficient rights to:
    • Access the write-back schema hosting the output dataset.
    • Create SAP HANA calculation views (MODELER role) and activate them (grant SELECT on the relevant schema with grant option).
  3. Create a calculation view from the content folder in SAP HANA studio and choose:
    • Subtype: Standard
    • Type: Graphical
    • Data Category: Cube
    Note

    The above mentionned settings are the simpliest settings to create an SAP HANA view. If you have the expertise, you can change those settings according to your preferences as long as they are supported by the live data acquisition.

    For more information on calculation view, refer to Calculation Views.

  4. Clcik on Add in the Aggregation box, search for your (partial) dataset name, select it and click OK.
  5. Select all the variables that you need in the table, right click and select Add to output.
  6. Select the Semantic box and change the type of each column to either attribute or measure depending on the semantic.
    Remember
    You need at least one measure for this type of calculation view.
  7. Save and activate this view.