Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Runtime Analysis FAQS

Former Member
0 Likes
1,129

1. Whats runtime analysis in detail

2. whats is sql trace in detial.

3. what is the diff between watch point and break point?

4. what is al21

please tell me these answers of this question.

7 REPLIES 7
Read only

Former Member
0 Likes
876

Runtime Analysis:

Runtime analysis shows you how long it takes to process ABAP code, from single statements to a complete transaction.



To start the runtime analysis, choose Tools -> ABAP Workbench -> Test -> Runtime analysis (or transaction SE30). On the initial screen you can choose one of four main functions.

Measurement in the current status
Measurement in a new session
Select measurement restrictions
Analyze performance data
For large applications it is recommended that you first analyze the entire application and hit list.

SQL Trace

The SQL Trace function is an on-demand log of selected SQL statements that are issued against the database through the Open SQL Engine. The SQL Trace can be switched on or off dynamically. The log format is database independent. Besides the SQL statement text, each log record contains information about the point in time when the statement was executed, its duration, its input parameters and results (where applicable) as well as context information.

Features
The SQL Trace is especially useful for:

· Development

SQL Trace can help JDO, enterprise beans, servlet and JSP developers to learn which kind of database accesses their code produces.

· Performance analysis

Typically, performance issues are caused by inefficient database accesses. In this case SQL Trace can be used to show the issued SQL statements and their duration, thus helping to identify inefficient SQL statements.

Break Point Vs Watch Point


When you set a

breakpoint

in the Debugger, it is created as a debugger breakpoint by default. A debugger breakpoint is only valid while the Debugger instance, in which it was set, is active. When the Debugger is closed, all debugger breakpoints set in it are deleted.

Watchpoints

allow you the option of monitoring the content of individual variables.

The Debugger stops as soon as the value of the monitored variable changes.

In addition, conditions can be specified. The Debugger also checks whether such a condition is fulfilled


AL21

analyze the performance of ABAP program

Regards,

Raghav

Read only

anversha_s
Active Contributor
0 Likes
876

hi,

<b>run time analysis</b>

SE30 - gives you a run time analysis and points out the issues more at design time.

ST05 - Is the most useful if you want to track time taken for execution of each of the sections.

SM50 - Will give you a work process overview, not sure at a program level how can it help you.

Some times you will have to use a combination of SE30 and ST05.

I would like to use St05 personally.

http://help.sap.com/saphelp_47x200/helpdata/en/f2/31adaa810c11d288ec0000e8200722/frameset.htm

<b>BREAKPOINT</b>

In the source code we set the Break-point there by clicking the stop button, the system will stop there when you execute the program.

<b>Watchpoint</b>

For watchpoints, we need to give some condition and when this condition is satisfied, program will stop

example : if you want to debug only

for matnr value 100 than set watch point

matnr = 100. when value reaches 100 than

program stops at that point.

more at

http://help.sap.com/saphelp_nw04/helpdata/en/c6/617cdce68c11d2b2ab080009b43351/content.htm

rgds

Anver

Read only

Former Member
0 Likes
876

1. by Analysis you can determine how many time your program/dB queries are taking to run.

to analyse only Select/inset/Db satement use ST05.

to nalyse the whole program execution, use the transaction se30.

2. SQL trace is tracing of sql statement. by tcode st05 you trace your sql queries time.

3. Breakpoint is point where your program exceution will stop/break, you can see what are the contents of your variable at runtime.

while in watchpoint on variable, you can get the statement where the value of your variable is setting/changing the contents of your variable.

breakpoint is on ABAP statemant while watchpoint is on variable content.

you can set watch point only at runtime while breakpoint you canset prior to program execution or after the execution will start.

Read only

Former Member
0 Likes
876

Hi,

This is very good link where you can have entire performance.

http://www.thespot4sap.com/Articles/SAPABAPPerformanceTuning_PerformanceAnalysisTools.asp

Thanks,

Manju Nagendra.

Read only

Former Member
0 Likes
876

Hi,

Check this thread.

Regards,

Maha

Read only

Former Member
0 Likes
876

Hi

<b>Whats runtime analysis in detail</b>

Run time analysis transaction SE30 :This transaction gives all the analysis of an ABAP program with respect to the database and the non-database processing.

In Transaction SE30, fill in the transaction name or the program name which needs to be analyzed for performance tuning.

For our case, let this be “ZABAP_PERF_TUNING”

After giving the required inputs to the program, execute it. After the final output list has been displayed, PRESS the “BACK” button.

On the original SE30 screen, now click on “ANALYZE” button.

The percentage across each of the areas ABAP/ Database/System shows the percentage of total time used for those areas and load on these areas while running the program . The lesser the database load faster the program runs.

2<b>. whats is sql trace in detial.</b>

SQL Trace transaction ST05: The trace list has many lines that are not related to the SELECT statement in the ABAP program. This is because the execution of any ABAP program requires additional administrative SQL calls. To restrict the list output, use the filter introducing the trace list.

The trace list contains different SQL statements simultaneously related to the one SELECT statement in the ABAP program. This is because the R/3 Database Interface - a sophisticated component of the R/3 Application Server - maps every Open SQL statement to one or a series of physical database calls and brings it to execution. This mapping, crucial to R/3s performance, depends on the particular call and database system. For example, the SELECT-ENDSELECT loop on a particular database table of the ABAP program would be mapped to a sequence PREPARE-OPEN-FETCH of physical calls in an Oracle environment.

The WHERE clause in the trace list's SQL statement is different from the WHERE clause in the ABAP statement. This is because in an R/3 system, a client is a self-contained unit with separate master records and its own set of table data (in commercial, organizational, and technical terms). With ABAP, every Open SQL statement automatically executes within the correct client environment. For this reason, a condition with the actual client code is added to every WHERE clause if a client field is a component of the searched table.

To see a statement's execution plan, just position the cursor on the PREPARE statement and choose Explain SQL. A detailed explanation of the execution plan depends on the database system in use.

Starting the Trace:

To analyze a trace file, do the following:

...

Choose the menu path Test &#61614; Performance Trace in the ABAP Workbench or go to Transaction ST05. The initial screen of the test tool appears. In the lower part of the screen, the status of the Performance Trace is displayed. This provides you with information as to whether any of the Performance Traces are switched on and the users for which they are enabled. It also tells you which user has switched the trace on.

Using the selection buttons provided, set which trace functions you wish to have switched on (SWL trace, enqueue trace, RFC trace, table buffer trace).

If you want to switch on the trace under your user name, choose Trace on. If you want to pass on values for one or several filter criteria, choose Trace with Filter. Typical filter criteria are: the name of the user, transaction name, process name, and program name.

Now run the program to be analyzed.

Stopping the Trace:

To deactivate the trace:

...

Choose Test &#61614;Performance Trace in the ABAP Workbench. The initial screen of the test tool appears. It contains a status line displaying the traces that are active, the users for whom they are active, and the user who activated them.

Select the trace functions that you want to switch off.

Choose Deactivate Trace. If you started the trace yourself, you can now switch it off immediately. If the performance trace was started by a different user, a confirmation prompt appears before deactivation-

Analyzing a Sample trace data:

PREPARE: Prepares the OPEN statement for use and determines the access method.

OPEN: Opens the cursor and specifies the selection result by filling the selection fields with concrete values.

FETCH: Moves the cursor through the dataset created by the OPEN operation. The array size displayed beside the fetch data means that the system can transfer a maximum package size of 392 records at one time into the buffered area.

/people/siegfried.boes/blog/2007/09/05/the-sql-trace-st05-150-quick-and-easy

<b>3. what is the diff between watch point and break point?</b>

<b>Breakpoints</b>

Instead of starting an ABAP program directly in the Debugger, you can also debug a program by creating one or more breakpoints in the program. A breakpoint is a signal at a particular point in the program that tells the ABAP runtime processor to interrupt processing and start the Debugger. The program runs normally until the breakpoint is reached.

There is also a special kind of breakpoint called a watchpoint. When you use watchpoints, the Debugger is not activated until the contents of a particular field change. For further information, refer to Watchpoints.

<b>Watchpoints</b>

Like a breakpoint, a watchpoint is an indicator in a program that tells the ABAP runtime processor to interrupt the program at a particular point. Unlike breakpoints, however, watchpoints are not activated until the contents of a specified field change. Watchpoints, like dynamic breakpoints, are user-specific, and so do not affect other users running the same program. You can only define watchpoints in the Debugger.

<b>4. what is al21</b>

Performance Analyzie(al21)

<b>Reward if usefull</b>

Read only

Former Member
0 Likes
876

I have provided 2 blogs on the performance tools because of the repeated questions here and would be happy, if they would also be found:

SQL trace:

/people/siegfried.boes/blog/2007/09/05/the-sql-trace-st05-150-quick-and-easy

SE30

/people/siegfried.boes/blog/2007/11/13/the-abap-runtime-trace-se30--quick-and-easy

If you have any further question just add a comment.

Siegfried