Optimizing custom ABAP code is not an easy process unless you have the right tools that will guide you in the optimization phase. Performance Analysts/ ABAP Consultants/ ABAP Developers who have performed performance optimization understand the challenges involved in optimizing the custom code.
Optimization complexity increases exponentially in a big ERP system landscape. A big landscape involves hundreds of business processes that execute several thousands of SQL statements each day.
Getting started is the trickiest part. Some of the questions worth considering before you plan the optimization task are:
SQL Monitor is the only tool that answers all these questions. SQL Monitor View interprets SQL Monitor data and provides transaction statistics on the fly. With SQL Monitor View, performance optimization is no more a time consuming task. It automates the process of analyzing data, increases your productivity, and improves the efficiency of your business process. To know about SQL Monitor, see the SQL Monitor blog listed in the “Related Information” section.
SQL Monitor view is available in ABAP in Eclipse development environment with ABAP Development Tools in SAP NetWeaver 7.5 SP0.
Customers and partners experience that some of their business processes continue to have performance issues even after migrating to SAP HANA.
A detailed research and analysis of multiple business processes has indicated that almost all the performance issues relate to improper SQL statements used in the ABAP custom code. For better performance, it is mandatory to adhere strictly to the Open SQL golden rules. For example, one such rule is to avoid nested select statements.
SQL Monitor view provides a simple solution. It identifies top business processes with performance issues and allows you to navigate to the SQL statements that cause such issues. It finds potential performance hot spots that need optimization in a matter of seconds and displays SQL Monitor Markers (visual indicators) to show case the severity of SQL statements.
SQL Monitor view uses SQL Monitor data to search and display results. The search feature uses the Aggregation By criteria to aggregate data based on any of the following options:
To sort data, the search feature uses specific database parameters in Order By such as:
To analyze business processes with performance issues, enable SQL Monitor trace in your production system for a couple of weeks. If you are running a quarterly report or a transaction at a specific interval then enable SQL Monitor trace during this interval. Import the trace logs from the production system in the form of a snapshot to a development system with SQL Monitor view implementation.
Note
You can also perform analysis on your production system. However, to avoid loading of the production system we recommend that you use a development system after obtaining the trace logs.
Step 1: Configuring Data Source
The SQL Monitor view appears.
TIP: You can also use Quick Access (CTRL + 3) in the ADT toolbar to display the SQL Monitor view.
In the Quick Access field, type SQLM. In the Views section, choose SQL Monitor.
The list displays all the projects available in the Project Explorer view.
Step 2: Analyzing Business Processes
The default option is Request.
Note: If you want to identify and optimize business processes that take most
of the execution time then choose the Request option. If you want to identify
and optimize SQL statements that take most of the execution time
then choose the Source Code Position option.
The default option is Total Number of DB Execution.
The default number is 10.
The SQL Monitor view lists the top records based on the search criteria that you have defined.
Note: If you have not configured a data source for the ABAP project that you selected
then a message to configure a data source appears.
Based on the search criteria that you have set, two patterns of analysis is possible.
These patterns are as follows:
then the SQL Monitor view displays the top request types sorted according to
the most number of database executions or according to execution time or
according to the most number of database records retrieved. Select a request type to see
the SQL profile of the request type in the right side table.
then the SQL Monitor view displays the top SQL statements sorted according to
the most number of database executions or according to execution time or
according to the most number of database records retrieved. Select an SQL statement to see
the business processes that use the SQL statement in the right side table.
in the Request Entry Point column.
Press CTRL key and click the entry to open the corresponding editor.
from the Object Name column.
Press CTRL key and click the entry to open the corresponding editor.
TIP: You can also press F3 after choosing an entry to open the corresponding editor.
Note: The SQL Monitor markers appear next to the SQL statements that exceed the threshold.
The SQL Monitor Marker tool provides visual indicators () to indicate the
severity level of the SQL statement.
over the visual indicator that appears in the editor.
Note :
The result set table also contains options
to “Filter Columns” () and search any text ( ) in the result set.
As Performance Analysts or ABAP Consultants or ABAP Developers you can use these options
to filter the result set based on your business requirements.
Step 3: Setting Performance Threshold
You set performance threshold to detect if the performance of a business process falls
outside a specified range and might cause problems. If a business process deviates from
the set threshold, SQL Monitor view displays visual indicators next to SQL statements in the business process.
Note
This option displays the default threshold values. You can also enter customized threshold values.
I presume that my blog will assist Performance Analysts or ABAP Consultants or ABAP Developers to unleash the potential of SQL Monitor view and efficiently identify business processes/SQL statements that require optimization.
Related Information
http://scn.sap.com/community/abap/hana/blog/2013/11/16/sql-monitor-unleashed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
4 | |
3 | |
3 | |
3 | |
2 | |
2 | |
2 | |
2 | |
1 | |
1 |