Using the SAP HANA Statement Library


After completing this lesson, you will be able to:

  • Import the SAP HANA Statement Library and execute the SQL scripts

SAP HANA Statement Library

During the analysis of complex problems, you might want to determine special database information that is not entirely available in standard functions. Because of this, SAP provides a collection of useful SQL statements for SAP HANA database analysis. For information on how to download the SQL statements, see SAP Note 1969700 - SQL Statement Collection for SAP HANA. The database explorer statement library comes pre-installed with the SQL Statement Library. The statements are stored in the M_SYSTEM_INFORMATION_STATEMENTS system view, your personal created SQL scripts are also stored in that view.


For the mini checks attachment, see SAP Note 1969700 - SQL Statement Collection for SAP HANA.

For the mini checks documentation, see SAP Note 1999993 - How-To: Interpreting SAP HANA Mini Check Results.

After you have imported the newest version of the file, you can easily use these new SQL scripts because they are from the type USER.

Mini Checks Usage

You can use each statement separately, but you can use mini checks to execute the most important statements with one call. Use the version that best fits your system environment, so that the most comprehensive set of checks is executed. It is important to know your SAP HANA version number. The embedded statistics server assists you with monitoring the SAP HANA system, collects historical performance data, and warns you of system alerts (such as resource exhaustion). The historical data is stored in the _SYS_STATISTICS schema.

You can also delete queries and statements if they are not of use.

Start the mini check every day so that you know what is going on in your system. If you plan to move your system to a newer version, you can precheck your system with the corresponding version of your target revision.

To further analyze the results, you can download your results to a flat file and open the results in an editor tool.


The values in the Expected_Value column are updated regularly, so it is important to import the newest version of the SQL collection occasionally.

Filtering by areas that deviate from their expected values (filter by X in column C) shows you which areas to focus on. The example in the figure shows that there are issues with users and privileges. SAP Notes provide more information about the issue and how to resolve it.

Log in to track your progress & complete quizzes