-1

I have to develop an ABAP report program. After it's execution, I have to display a popup with evaluating it's performance. It's possible? I mean without using transaction SAT.

The scenario is simple:

1) Run report from se38 or it's using related tcode

2) After running - display the performance.

Please give me any idea how to do that. Thank you.

Sandra Rossi
  • 11,934
  • 5
  • 22
  • 48
Saros Begh
  • 35
  • 2
  • 9

3 Answers3

1

I assume that you want to measure the runtime of the report.

So, you could easily save the timestamp of the beginning of the program into an variable and when the execution logic finished, you can get another timestamp.

If you subtract timestamp 1 from timestamp 2, you have your running time.

Felix
  • 78
  • 4
  • 15
0

For simple measurements you can you this snippet:

DATA: t1 TYPE i,
      t2 TYPE i.
DATA: gt_tabrows TYPE TABLE OF exp_tablrows,
      toff       TYPE p DECIMALS 2.

GET RUN TIME FIELD t1.

SELECT tabname
  FROM dd02l
  INTO CORRESPONDING FIELDS OF TABLE gt_tabrows
  WHERE tabname LIKE 'Y%'.

CALL FUNCTION 'EM_GET_NUMBER_OF_ENTRIES'
  TABLES
    it_tables = gt_tabrows.

GET RUN TIME FIELD t2.
toff = t2 - t1.

cl_demo_output=>new( )->begin_section(
|Y tables recordcount calculation:| 
)->write_text( 
| { toff } microseconds| 
)->write_data( gt_tabrows )->display( ).

This sample outputs runtime of code calculating recordcounts of tables that start with Y.

Suncatcher
  • 10,355
  • 10
  • 52
  • 90
-1

If you run your programm in backgroup, the job-log gives you all your needed information.

Christian
  • 19
  • 1