SAP SO_FOLDER_INSERT Function Module for









SO_FOLDER_INSERT is a standard so folder insert 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 so folder insert FM, simply by entering the name SO_FOLDER_INSERT into the relevant SAP transaction such as SE37 or SE38.

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



Function SO_FOLDER_INSERT 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 'SO_FOLDER_INSERT'"
EXPORTING
FOLDER_ID = "Folder for inserting new folder
OBJECT_FL_CHANGE = "Folder-related folder data
OBJECT_HD_CHANGE = "Definition data of folder
OBJECT_SD_CHANGE = "Folder-specific header
* OWNER = "Owner of folder

IMPORTING
OBJECT_FL_DISPLAY = "Folder-related folder data; part which can be displayed
OBJECT_HD_DISPLAY = "Definition data; part that can be displayed
OBJECT_ID = "ID that was allocated
OBJECT_SD_DISPLAY = "Folder-specific header data that can be displayed

EXCEPTIONS
ACTIVE_USER_NOT_EXIST = 1 PARAMETER_ERROR = 10 SUBSTITUTE_NOT_ACTIVE = 11 SUBSTITUTE_NOT_DEFINED = 12 SYSTEM_FAILURE = 13 X_ERROR = 14 COMMUNICATION_FAILURE = 2 COMPONENT_NOT_AVAILABLE = 3 FOLDER_NOT_EXIST = 4 FOLDER_NO_AUTHORIZATION = 5 FOLDER_TITLE_MISSING = 6 OBJECT_TYPE_NOT_EXIST = 7 OPERATION_NO_AUTHORIZATION = 8 OWNER_NOT_EXIST = 9
.



IMPORTING Parameters details for SO_FOLDER_INSERT

FOLDER_ID - Folder for inserting new folder

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

OBJECT_FL_CHANGE - Folder-related folder data

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

OBJECT_HD_CHANGE - Definition data of folder

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

OBJECT_SD_CHANGE - Folder-specific header

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

OWNER - Owner of folder

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

EXPORTING Parameters details for SO_FOLDER_INSERT

OBJECT_FL_DISPLAY - Folder-related folder data; part which can be displayed

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

OBJECT_HD_DISPLAY - Definition data; part that can be displayed

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

OBJECT_ID - ID that was allocated

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

OBJECT_SD_DISPLAY - Folder-specific header data that can be displayed

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

EXCEPTIONS details

ACTIVE_USER_NOT_EXIST - Active user does not exist

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

PARAMETER_ERROR - Incorrect combination of parameters

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

SUBSTITUTE_NOT_ACTIVE - Substitute is inactive

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

SUBSTITUTE_NOT_DEFINED - Substitute is not defined

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

SYSTEM_FAILURE -

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

X_ERROR - Internal error

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

COMMUNICATION_FAILURE -

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

COMPONENT_NOT_AVAILABLE - Component not available

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

FOLDER_NOT_EXIST - Specified folder does not exist

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

FOLDER_NO_AUTHORIZATION - No authorization for folder

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

FOLDER_TITLE_MISSING - Title of folder is missing

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

OBJECT_TYPE_NOT_EXIST - Object type does not exist

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

OPERATION_NO_AUTHORIZATION - No authorization for operation

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

OWNER_NOT_EXIST - Owner does not exist

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

Copy and paste ABAP code example for SO_FOLDER_INSERT 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_folder_id  TYPE SOODK, "   
lv_object_fl_display  TYPE SOFM2, "   
lv_active_user_not_exist  TYPE SOFM2, "   
lv_parameter_error  TYPE SOFM2, "   
lv_substitute_not_active  TYPE SOFM2, "   
lv_substitute_not_defined  TYPE SOFM2, "   
lv_system_failure  TYPE SOFM2, "   
lv_x_error  TYPE SOFM2, "   
lv_object_fl_change  TYPE SOFM1, "   
lv_object_hd_display  TYPE SOOD2, "   
lv_communication_failure  TYPE SOOD2, "   
lv_object_id  TYPE SOODK, "   
lv_object_hd_change  TYPE SOOD1, "   
lv_component_not_available  TYPE SOOD1, "   
lv_folder_not_exist  TYPE SOOD1, "   
lv_object_sd_change  TYPE SOFH1, "   
lv_object_sd_display  TYPE SOFH2, "   
lv_owner  TYPE SOUD-USRNAM, "   
lv_folder_no_authorization  TYPE SOUD, "   
lv_folder_title_missing  TYPE SOUD, "   
lv_object_type_not_exist  TYPE SOUD, "   
lv_operation_no_authorization  TYPE SOUD, "   
lv_owner_not_exist  TYPE SOUD. "   

  CALL FUNCTION 'SO_FOLDER_INSERT'  "
    EXPORTING
         FOLDER_ID = lv_folder_id
         OBJECT_FL_CHANGE = lv_object_fl_change
         OBJECT_HD_CHANGE = lv_object_hd_change
         OBJECT_SD_CHANGE = lv_object_sd_change
         OWNER = lv_owner
    IMPORTING
         OBJECT_FL_DISPLAY = lv_object_fl_display
         OBJECT_HD_DISPLAY = lv_object_hd_display
         OBJECT_ID = lv_object_id
         OBJECT_SD_DISPLAY = lv_object_sd_display
    EXCEPTIONS
        ACTIVE_USER_NOT_EXIST = 1
        PARAMETER_ERROR = 10
        SUBSTITUTE_NOT_ACTIVE = 11
        SUBSTITUTE_NOT_DEFINED = 12
        SYSTEM_FAILURE = 13
        X_ERROR = 14
        COMMUNICATION_FAILURE = 2
        COMPONENT_NOT_AVAILABLE = 3
        FOLDER_NOT_EXIST = 4
        FOLDER_NO_AUTHORIZATION = 5
        FOLDER_TITLE_MISSING = 6
        OBJECT_TYPE_NOT_EXIST = 7
        OPERATION_NO_AUTHORIZATION = 8
        OWNER_NOT_EXIST = 9
. " SO_FOLDER_INSERT




ABAP code using 7.40 inline data declarations to call FM SO_FOLDER_INSERT

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 USRNAM FROM SOUD INTO @DATA(ld_owner).
 
 
 
 
 
 


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!