SAP SAPTUNE_GET_SUMMARY_STATISTIC Function Module for Returns a Selection of Statistics About Buffers and SAP Memory









SAPTUNE_GET_SUMMARY_STATISTIC is a standard saptune get summary statistic SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Returns a Selection of Statistics About Buffers and SAP Memory processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for saptune get summary statistic FM, simply by entering the name SAPTUNE_GET_SUMMARY_STATISTIC into the relevant SAP transaction such as SE37 or SE38.

Function Group: STUB
Program Name: SAPLSTUB
Main Program: SAPLSTUB
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function SAPTUNE_GET_SUMMARY_STATISTIC pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'SAPTUNE_GET_SUMMARY_STATISTIC'"Returns a Selection of Statistics About Buffers and SAP Memory
EXPORTING
* DESTINATION = 'NONE' "RFC Target System (Default: Local System)

IMPORTING
ROLL_AREA = "Roll Area Statistics
TOTAL_DURATIONS = "Times for Individual DB Access Types
TOTAL_ROWS = "Tuple for Individual DB Access Types
TOTAL_OPERATIONS = "Number of Operations (Requests, Fails, Calls, Rows)
SAP_CURSOR_CACHE_TOTAL = "Complete SAP Cursor Cache Statistics for all WPs
NUMBER_OF_TABLES = "Number of Tables in Table Statistics
EXTENDED_MEMORY_USAGE = "EM Usage Statistics
HEAP_MEMORY_USAGE = "Heap Usage Statistics
RFC_ERROR = "RFC error message when using RFC
RFC_ERROR_TYPE = "RFC Error Type (Set even if there is no error)
PXA_INFO = "Program Buffer Information
PAGING_AREA = "Paging Area Statistics
BUFSTAT_AVAILABLE = "Are buffer statistics available?
TABSTAT_AVAILABLE = "Are table statistics available?
RPSTAT_AVAILABLE = "Are roll and paging statistics available?
PXAINF_AVAILABLE = "Are program buffer statistics available?
CCSTAT_AVAILABLE = "Are SAP Cursor Cache statistics available?
EMSTAT_AVAILABLE = "Are extended memory statistics available?
LOGIC_ACCESSES_64 = "Logical (ABAP) Database Accesses 64-Bit
DB_ACCESSES_64 = "Physical Database Accesses 64-Bit
TOTAL_DURATIONS_64 = "Times for Individual DB Access Types 64-Bit
TOTAL_ROWS_64 = "Tuple for Individual DB Access Types 64-Bit
LOGIC_ACCESSES = "Logical (ABAP) Database Accesses
DB_ACCESSES = "Physical Database Accesses
TOTAL_HITRATIO = "Hit Rates for Individual DB Access Types
STARTUP_TIME = "System Start Time
STARTUP_DATE = "System Start Date
ANALYSIS_DATE = "Analysis Date
ANALYSIS_TIME = "Analysis Time

TABLES
* BUFFER_STATISTIC = "Buffer statistics
* MODE_MEMORY_HISTORY = "Short history of import/export modes
* BUFFER_STATISTIC_64 = "64-Bit Buffer Statistics
* TABLE_STATISTIC_64 = "Structure: Table Call Statistics with Decimal Fields
* TABLE_STATISTIC = "Table Statistics
* BUFFER_NAMES = "Names of the Buffers Containing SAPTUNE Statistics
* TABLE_QUALITIES = "Table Access Qualities
* CURSOR_CACHE_INFO = "SAP Cursor Cache Information
* EXTENDED_MEMORY_ACTIVE_CONTEXT = "Extended Memory User Context Information
* ALLOC_PROCEDURE_DIA = "Memory Allocation Procedure for Dialog WPs
* ALLOC_PROCEDURE_NONDIA = "Memory Allocation Procedure for Non-Dialog WPs
* INTERNAL_EXTERNAL_MODES_MEMORY = "Memory requirement for import/export modes

EXCEPTIONS
NO_AUTHORIZATION = 1
.



IMPORTING Parameters details for SAPTUNE_GET_SUMMARY_STATISTIC

DESTINATION - RFC Target System (Default: Local System)

Data type: RFCDES-RFCDEST
Default: 'NONE'
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for SAPTUNE_GET_SUMMARY_STATISTIC

ROLL_AREA - Roll Area Statistics

Data type: RLPG_STAT
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_DURATIONS - Times for Individual DB Access Types

Data type: TABPHYSACC
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_ROWS - Tuple for Individual DB Access Types

Data type: TABPHYSACC
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_OPERATIONS - Number of Operations (Requests, Fails, Calls, Rows)

Data type: TABOPERTNS
Optional: No
Call by Reference: No ( called with pass by value option)

SAP_CURSOR_CACHE_TOTAL - Complete SAP Cursor Cache Statistics for all WPs

Data type: CCSTATSTTL
Optional: No
Call by Reference: No ( called with pass by value option)

NUMBER_OF_TABLES - Number of Tables in Table Statistics

Data type: SY-INDEX
Optional: No
Call by Reference: No ( called with pass by value option)

EXTENDED_MEMORY_USAGE - EM Usage Statistics

Data type: EMSTATUSAG
Optional: No
Call by Reference: No ( called with pass by value option)

HEAP_MEMORY_USAGE - Heap Usage Statistics

Data type: HPSTATUSAG
Optional: No
Call by Reference: No ( called with pass by value option)

RFC_ERROR - RFC error message when using RFC

Data type: RFCCALSTUN-ERROR_MSG
Optional: No
Call by Reference: No ( called with pass by value option)

RFC_ERROR_TYPE - RFC Error Type (Set even if there is no error)

Data type: RFCCALSTUN-RFCERRTYPE
Optional: No
Call by Reference: No ( called with pass by value option)

PXA_INFO - Program Buffer Information

Data type: PXAINFOS
Optional: No
Call by Reference: No ( called with pass by value option)

PAGING_AREA - Paging Area Statistics

Data type: RLPG_STAT
Optional: No
Call by Reference: No ( called with pass by value option)

BUFSTAT_AVAILABLE - Are buffer statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

TABSTAT_AVAILABLE - Are table statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

RPSTAT_AVAILABLE - Are roll and paging statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

PXAINF_AVAILABLE - Are program buffer statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

CCSTAT_AVAILABLE - Are SAP Cursor Cache statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

EMSTAT_AVAILABLE - Are extended memory statistics available?

Data type: RFCCALSTUN-AVAILABLE
Optional: No
Call by Reference: No ( called with pass by value option)

LOGIC_ACCESSES_64 - Logical (ABAP) Database Accesses 64-Bit

Data type: TABLLOGACC64
Optional: No
Call by Reference: No ( called with pass by value option)

DB_ACCESSES_64 - Physical Database Accesses 64-Bit

Data type: TABPHYSACC64
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_DURATIONS_64 - Times for Individual DB Access Types 64-Bit

Data type: TABPHYSACC64
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_ROWS_64 - Tuple for Individual DB Access Types 64-Bit

Data type: TABPHYSACC64
Optional: No
Call by Reference: No ( called with pass by value option)

LOGIC_ACCESSES - Logical (ABAP) Database Accesses

Data type: TABLLOGACC
Optional: No
Call by Reference: No ( called with pass by value option)

DB_ACCESSES - Physical Database Accesses

Data type: TABPHYSACC
Optional: No
Call by Reference: No ( called with pass by value option)

TOTAL_HITRATIO - Hit Rates for Individual DB Access Types

Data type: TABHITRATO
Optional: No
Call by Reference: No ( called with pass by value option)

STARTUP_TIME - System Start Time

Data type: SY-UZEIT
Optional: No
Call by Reference: No ( called with pass by value option)

STARTUP_DATE - System Start Date

Data type: SY-DATUM
Optional: No
Call by Reference: No ( called with pass by value option)

ANALYSIS_DATE - Analysis Date

Data type: SY-DATUM
Optional: No
Call by Reference: No ( called with pass by value option)

ANALYSIS_TIME - Analysis Time

Data type: SY-UZEIT
Optional: No
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for SAPTUNE_GET_SUMMARY_STATISTIC

BUFFER_STATISTIC - Buffer statistics

Data type: TUNEHDWQ
Optional: Yes
Call by Reference: No ( called with pass by value option)

MODE_MEMORY_HISTORY - Short history of import/export modes

Data type: MEMMODETAB
Optional: Yes
Call by Reference: No ( called with pass by value option)

BUFFER_STATISTIC_64 - 64-Bit Buffer Statistics

Data type: TUNEHDWQ64
Optional: Yes
Call by Reference: Yes

TABLE_STATISTIC_64 - Structure: Table Call Statistics with Decimal Fields

Data type: DBSTATDEC64
Optional: Yes
Call by Reference: Yes

TABLE_STATISTIC - Table Statistics

Data type: DBSTATDEC
Optional: Yes
Call by Reference: No ( called with pass by value option)

BUFFER_NAMES - Names of the Buffers Containing SAPTUNE Statistics

Data type: SAPTUNEBFN
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLE_QUALITIES - Table Access Qualities

Data type: TABBUFQUAL
Optional: Yes
Call by Reference: No ( called with pass by value option)

CURSOR_CACHE_INFO - SAP Cursor Cache Information

Data type: CCSTATS
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXTENDED_MEMORY_ACTIVE_CONTEXT - Extended Memory User Context Information

Data type: EMCONTEXT
Optional: Yes
Call by Reference: No ( called with pass by value option)

ALLOC_PROCEDURE_DIA - Memory Allocation Procedure for Dialog WPs

Data type: MEMALLOC
Optional: Yes
Call by Reference: No ( called with pass by value option)

ALLOC_PROCEDURE_NONDIA - Memory Allocation Procedure for Non-Dialog WPs

Data type: MEMALLOC
Optional: Yes
Call by Reference: No ( called with pass by value option)

INTERNAL_EXTERNAL_MODES_MEMORY - Memory requirement for import/export modes

Data type: MEMMODETAB
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

NO_AUTHORIZATION - No authorization

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for SAPTUNE_GET_SUMMARY_STATISTIC Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.

DATA:
lv_roll_area  TYPE RLPG_STAT, "   
lv_destination  TYPE RFCDES-RFCDEST, "   'NONE'
lt_buffer_statistic  TYPE STANDARD TABLE OF TUNEHDWQ, "   
lv_no_authorization  TYPE TUNEHDWQ, "   
lv_total_durations  TYPE TABPHYSACC, "   
lt_mode_memory_history  TYPE STANDARD TABLE OF MEMMODETAB, "   
lv_total_rows  TYPE TABPHYSACC, "   
lt_buffer_statistic_64  TYPE STANDARD TABLE OF TUNEHDWQ64, "   
lv_total_operations  TYPE TABOPERTNS, "   
lt_table_statistic_64  TYPE STANDARD TABLE OF DBSTATDEC64, "   
lv_sap_cursor_cache_total  TYPE CCSTATSTTL, "   
lv_number_of_tables  TYPE SY-INDEX, "   
lv_extended_memory_usage  TYPE EMSTATUSAG, "   
lv_heap_memory_usage  TYPE HPSTATUSAG, "   
lv_rfc_error  TYPE RFCCALSTUN-ERROR_MSG, "   
lv_rfc_error_type  TYPE RFCCALSTUN-RFCERRTYPE, "   
lv_pxa_info  TYPE PXAINFOS, "   
lv_paging_area  TYPE RLPG_STAT, "   
lt_table_statistic  TYPE STANDARD TABLE OF DBSTATDEC, "   
lv_bufstat_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_tabstat_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_rpstat_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_pxainf_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_ccstat_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_emstat_available  TYPE RFCCALSTUN-AVAILABLE, "   
lv_logic_accesses_64  TYPE TABLLOGACC64, "   
lv_db_accesses_64  TYPE TABPHYSACC64, "   
lv_total_durations_64  TYPE TABPHYSACC64, "   
lv_total_rows_64  TYPE TABPHYSACC64, "   
lt_buffer_names  TYPE STANDARD TABLE OF SAPTUNEBFN, "   
lv_logic_accesses  TYPE TABLLOGACC, "   
lv_db_accesses  TYPE TABPHYSACC, "   
lt_table_qualities  TYPE STANDARD TABLE OF TABBUFQUAL, "   
lv_total_hitratio  TYPE TABHITRATO, "   
lt_cursor_cache_info  TYPE STANDARD TABLE OF CCSTATS, "   
lv_startup_time  TYPE SY-UZEIT, "   
lt_extended_memory_active_context  TYPE STANDARD TABLE OF EMCONTEXT, "   
lv_startup_date  TYPE SY-DATUM, "   
lt_alloc_procedure_dia  TYPE STANDARD TABLE OF MEMALLOC, "   
lv_analysis_date  TYPE SY-DATUM, "   
lt_alloc_procedure_nondia  TYPE STANDARD TABLE OF MEMALLOC, "   
lv_analysis_time  TYPE SY-UZEIT, "   
lt_internal_external_modes_memory  TYPE STANDARD TABLE OF MEMMODETAB. "   

  CALL FUNCTION 'SAPTUNE_GET_SUMMARY_STATISTIC'  "Returns a Selection of Statistics About Buffers and SAP Memory
    EXPORTING
         DESTINATION = lv_destination
    IMPORTING
         ROLL_AREA = lv_roll_area
         TOTAL_DURATIONS = lv_total_durations
         TOTAL_ROWS = lv_total_rows
         TOTAL_OPERATIONS = lv_total_operations
         SAP_CURSOR_CACHE_TOTAL = lv_sap_cursor_cache_total
         NUMBER_OF_TABLES = lv_number_of_tables
         EXTENDED_MEMORY_USAGE = lv_extended_memory_usage
         HEAP_MEMORY_USAGE = lv_heap_memory_usage
         RFC_ERROR = lv_rfc_error
         RFC_ERROR_TYPE = lv_rfc_error_type
         PXA_INFO = lv_pxa_info
         PAGING_AREA = lv_paging_area
         BUFSTAT_AVAILABLE = lv_bufstat_available
         TABSTAT_AVAILABLE = lv_tabstat_available
         RPSTAT_AVAILABLE = lv_rpstat_available
         PXAINF_AVAILABLE = lv_pxainf_available
         CCSTAT_AVAILABLE = lv_ccstat_available
         EMSTAT_AVAILABLE = lv_emstat_available
         LOGIC_ACCESSES_64 = lv_logic_accesses_64
         DB_ACCESSES_64 = lv_db_accesses_64
         TOTAL_DURATIONS_64 = lv_total_durations_64
         TOTAL_ROWS_64 = lv_total_rows_64
         LOGIC_ACCESSES = lv_logic_accesses
         DB_ACCESSES = lv_db_accesses
         TOTAL_HITRATIO = lv_total_hitratio
         STARTUP_TIME = lv_startup_time
         STARTUP_DATE = lv_startup_date
         ANALYSIS_DATE = lv_analysis_date
         ANALYSIS_TIME = lv_analysis_time
    TABLES
         BUFFER_STATISTIC = lt_buffer_statistic
         MODE_MEMORY_HISTORY = lt_mode_memory_history
         BUFFER_STATISTIC_64 = lt_buffer_statistic_64
         TABLE_STATISTIC_64 = lt_table_statistic_64
         TABLE_STATISTIC = lt_table_statistic
         BUFFER_NAMES = lt_buffer_names
         TABLE_QUALITIES = lt_table_qualities
         CURSOR_CACHE_INFO = lt_cursor_cache_info
         EXTENDED_MEMORY_ACTIVE_CONTEXT = lt_extended_memory_active_context
         ALLOC_PROCEDURE_DIA = lt_alloc_procedure_dia
         ALLOC_PROCEDURE_NONDIA = lt_alloc_procedure_nondia
         INTERNAL_EXTERNAL_MODES_MEMORY = lt_internal_external_modes_memory
    EXCEPTIONS
        NO_AUTHORIZATION = 1
. " SAPTUNE_GET_SUMMARY_STATISTIC




ABAP code using 7.40 inline data declarations to call FM SAPTUNE_GET_SUMMARY_STATISTIC

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

 
"SELECT single RFCDEST FROM RFCDES INTO @DATA(ld_destination).
DATA(ld_destination) = 'NONE'.
 
 
 
 
 
 
 
 
 
 
"SELECT single INDEX FROM SY INTO @DATA(ld_number_of_tables).
 
 
 
"SELECT single ERROR_MSG FROM RFCCALSTUN INTO @DATA(ld_rfc_error).
 
"SELECT single RFCERRTYPE FROM RFCCALSTUN INTO @DATA(ld_rfc_error_type).
 
 
 
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_bufstat_available).
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_tabstat_available).
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_rpstat_available).
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_pxainf_available).
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_ccstat_available).
 
"SELECT single AVAILABLE FROM RFCCALSTUN INTO @DATA(ld_emstat_available).
 
 
 
 
 
 
 
 
 
 
 
"SELECT single UZEIT FROM SY INTO @DATA(ld_startup_time).
 
 
"SELECT single DATUM FROM SY INTO @DATA(ld_startup_date).
 
 
"SELECT single DATUM FROM SY INTO @DATA(ld_analysis_date).
 
 
"SELECT single UZEIT FROM SY INTO @DATA(ld_analysis_time).
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!