SAP STAT_MAINTAIN Function Module for
STAT_MAINTAIN is a standard stat maintain SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 stat maintain FM, simply by entering the name STAT_MAINTAIN into the relevant SAP transaction such as SE37 or SE38.
Function Group: STATUS
Program Name: SAPLSTATUS
Main Program: SAPLSTATUS
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function STAT_MAINTAIN 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 'STAT_MAINTAIN'".
EXPORTING
ID = "
APPLICATION = "
DISPLAY = "
* LANGUAGE = SY-LANGU "
* OBJECT_DATA = "
* FILTERTREE = "
* TREE_VIEW = ' ' "
* GET_DATA_FROM_ARCHIVE = "
* CALLED_BY_SOLUTION_MANAGER = ' ' "
IMPORTING
DATA_CHANGED = "
ACTUAL_STATUS = "
ACTION = "
TABLES
* IT_ISSUE_ALV = "Issue Management: Display Table
IMPORTING Parameters details for STAT_MAINTAIN
ID -
Data type: ISTATIFACE-IDOptional: No
Call by Reference: No ( called with pass by value option)
APPLICATION -
Data type: CHAR6Optional: No
Call by Reference: No ( called with pass by value option)
DISPLAY -
Data type: CHAR1Optional: No
Call by Reference: No ( called with pass by value option)
LANGUAGE -
Data type: SY-LANGUDefault: SY-LANGU
Optional: Yes
Call by Reference: No ( called with pass by value option)
OBJECT_DATA -
Data type: STACU_OBJECT_DATAOptional: Yes
Call by Reference: No ( called with pass by value option)
FILTERTREE -
Data type: HIER_IFACE-TREE_IDOptional: Yes
Call by Reference: No ( called with pass by value option)
TREE_VIEW -
Data type: CHAR1Default: SPACE
Optional: Yes
Call by Reference: Yes
GET_DATA_FROM_ARCHIVE -
Data type: CHAR1Optional: Yes
Call by Reference: Yes
CALLED_BY_SOLUTION_MANAGER -
Data type: XFELDDefault: SPACE
Optional: Yes
Call by Reference: Yes
EXPORTING Parameters details for STAT_MAINTAIN
DATA_CHANGED -
Data type: CHAR1Optional: No
Call by Reference: No ( called with pass by value option)
ACTUAL_STATUS -
Data type: ISTATIFACEOptional: No
Call by Reference: No ( called with pass by value option)
ACTION -
Data type: SY-UCOMMOptional: No
Call by Reference: Yes
TABLES Parameters details for STAT_MAINTAIN
IT_ISSUE_ALV - Issue Management: Display Table
Data type: TABTYPE_ISSUE_ALVOptional: Yes
Call by Reference: Yes
Copy and paste ABAP code example for STAT_MAINTAIN 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_id | TYPE ISTATIFACE-ID, " | |||
| lv_data_changed | TYPE CHAR1, " | |||
| lt_it_issue_alv | TYPE STANDARD TABLE OF TABTYPE_ISSUE_ALV, " | |||
| lv_application | TYPE CHAR6, " | |||
| lv_actual_status | TYPE ISTATIFACE, " | |||
| lv_action | TYPE SY-UCOMM, " | |||
| lv_display | TYPE CHAR1, " | |||
| lv_language | TYPE SY-LANGU, " SY-LANGU | |||
| lv_object_data | TYPE STACU_OBJECT_DATA, " | |||
| lv_filtertree | TYPE HIER_IFACE-TREE_ID, " | |||
| lv_tree_view | TYPE CHAR1, " SPACE | |||
| lv_get_data_from_archive | TYPE CHAR1, " | |||
| lv_called_by_solution_manager | TYPE XFELD. " SPACE |
|   CALL FUNCTION 'STAT_MAINTAIN' " |
| EXPORTING | ||
| ID | = lv_id | |
| APPLICATION | = lv_application | |
| DISPLAY | = lv_display | |
| LANGUAGE | = lv_language | |
| OBJECT_DATA | = lv_object_data | |
| FILTERTREE | = lv_filtertree | |
| TREE_VIEW | = lv_tree_view | |
| GET_DATA_FROM_ARCHIVE | = lv_get_data_from_archive | |
| CALLED_BY_SOLUTION_MANAGER | = lv_called_by_solution_manager | |
| IMPORTING | ||
| DATA_CHANGED | = lv_data_changed | |
| ACTUAL_STATUS | = lv_actual_status | |
| ACTION | = lv_action | |
| TABLES | ||
| IT_ISSUE_ALV | = lt_it_issue_alt | |
| . " STAT_MAINTAIN | ||
ABAP code using 7.40 inline data declarations to call FM STAT_MAINTAIN
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 ID FROM ISTATIFACE INTO @DATA(ld_id). | ||||
| "SELECT single UCOMM FROM SY INTO @DATA(ld_action). | ||||
| "SELECT single LANGU FROM SY INTO @DATA(ld_language). | ||||
| DATA(ld_language) | = SY-LANGU. | |||
| "SELECT single TREE_ID FROM HIER_IFACE INTO @DATA(ld_filtertree). | ||||
| DATA(ld_tree_view) | = ' '. | |||
| DATA(ld_called_by_solution_manager) | = ' '. | |||
Search for further information about these or an SAP related objects