##### Child pages
• Calculation Scenario Fundamentals
Go to start of banner

# Calculation Scenario Fundamentals

#### Introduction

BWonHANA extensivly uses calculation scenarios for various purposes. Those scenarios are represented as graphs and executed by the calculation engine. In many cases, calculation scenarios are generated implicitly, for example when activating models in HANA studio. BW often makes use of a particular DDL statement (CREATE CALCULATION SCENARIO...) in order to generate them. Upon execution of such a model (scenario) many optimizations are then done inside the calculation engine, eg push down of filters or determining the degree of parallelism.

Starting with HANA SP9, HANA Studio offers the possibility to visualize the graph that represents the calculation scenario.

#### Example

Lets take a very simple BW multiprovider as an example. As explained here, a multiprovider combines data from the part providers using a UNION. The example multiprovider just consists of 2 infocubes: On HANA side, the creation of the multiprovider results into the creation of a column view and a calculation scenario:   The column view references the calculation scenario and hence allows for normal access via SQL statements - which is not possible for a calculation scenario.

HANA SP9 has intoduced a new function called 'Visualize View' on those column (calculation) views: By doing this, the graph representing the calculation scenario is displayed: On the bottom of the graph are 2 OLAP nodes. The purpose of those nodes is to provide OLAP Views as a datasources. In this case, they are used as inputs to the multiprovider node: The multiprovider node is a BW specific operation that basically realizes the UNION mentioned before.

#### Relevant SQL statements

The following SQL statements can be used in order to get an overview about the involved objects (column views, calculation scenarios):

`select view_name, view_type, is_column_view, is_valid from  viewswhere view_name = '0BW:BIA:ZMBMUTST'`

The view is of type CALC since it references a calcuation scenario and is currently valid - otherwise acessing the view would result in errors. Since the view type is CALC, it is possible to select against M_CE_CALCVIEW_DEPENDENCIES in order to get the referenced calculation scenario:

get referenced calculation scenario
`select view_name, scenario_name from m_ce_calcview_dependencies where view_name = '0BW:BIA:ZMBMUTST';` Further information on the scenario can then be retrieved via M_CE_CALCSCENARIOS:

get details on calculation scenario
`select * from  m_ce_calcscenarios where scenario_name = 'SAPKIT:0BW:BIA:ZMBMUTST'` #### Important SAP Notes

2131752 - Export a temporary calculation scenario of a BW-query for further analysis

• No labels