Show TOC

Creating Database Statistics for Virtual TablesLocate this document in the navigation structure

Using the database statistics for virtual tables you can optimize the query performance for InfoProviders, which use SAP HANA Smart Data Access (SDA). In the process chain maintenance screen, you will find a process type that enables you to select or create a variant of the program RSSDA_CREATE_TABLE_STAT.

Virtual SAP HANA tables can be used with SAP HANA Smart Data Access. SAP HANA Smart Data Access can be used in SAP BW in various cases including:

  • Accessing the remote data of a source database, which is configured as a remote source in SAP HANA, from Open ODS views.

  • Query access to data in Sybase IQ as a near-line storage solution.

  • DataSources of the DB Connect source system with connection type HANA Smart Data Access and DataSources of the SAP HANA source system.

SAP HANA should have access to database statistics for the virtual table, in order to create a suitable query execution plan. The number of records in the source table is the minimum that should be known to SAP HANA. Using the process type you can integrate the creation of database statistics for a virtual table into process chains.


The creation of database statistics for virtual tables is supported for the following InfoProviders:

  • Open ODS views, which use SAP HANA Smart Data Access to access data.

  • DataStore objects (advanced), InfoCubes and DataStore objects (classic) - for which a data archiving process is defined for a SAP IQ near-line storage - and which use SAP HANA Smart Data Access (SDA) to access data in SAP IQ near-line storage for reporting.

You have maintenance authorization for the relevant InfoProvider .

  1. You are in the Administration area in Data Warehousing Workbench. Choose Process Chains. The Process Chain Maintenance Planning View screen appears.

  2. In the left-hand screen area of the required display component, navigate to the process chain where you want to integrate the creation of database statistics for an InfoProvider. Double-click the process chain to select it and change to edit mode. The system displays the process chain plan view on the right side of the screen.

    If you cannot find a suitable process chain, create a new one.

  3. In the process category Other, choose the application process type Create database statistics for virtual tables.

  4. Insert the application process type into the process chain by dragging it. The dialog box for inserting a process variant appears.
  5. Select a process variant or create a new process variant. The process variant is a program variant of program RSSDA_CREATE_TABLE_STAT. When you create a new process variant, this screen appears: ABAP:Variant Initial Screen. Here you can perform the following actions:
    1. Specify the technical name for the variant and choose Create.

    2. Either select an InfoProvider, which fulfills the above prerequisites, or specify a source system and a DataSource (DB Connect connection type HANA Smart Data Access or a SAP HANA DataSource).

    3. Select the statistics type.

      You can find information on the SAP HANA statistics types for virtual tables in section Creating Statistics on Virtual Tables in the SAP HANA Administration Guide.

    4. Enter a field name if you only want statistics to be created for one field. If you do not enter a field, statistics are created for all the fields in the virtual table.


      The creation of database statistics can produce a high workload for the source system, especially if large tables are involved. In order to avoid this, we recommend that you create simple statistics for a single field, which ideally has a low cardinality.

    5. Configure the variant attributes, save the variant and go back to the dialog box for adding a process variant.

  6. Select the process variant that you have just created and choose Next to add the process variant to the process chain.

  7. Link the process to the required processes. Once you have configured the statistics creation (for example, for an InfoProvider with data archiving via NLS and SDA access), link the process variant in the chain to the data archiving process.

  8. Save and activate your process chain.