SAP CGPL_PROJECT_POST Function Module for Update Module: Projects and Tasks









CGPL_PROJECT_POST is a standard cgpl project post SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Update Module: Projects and Tasks 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 cgpl project post FM, simply by entering the name CGPL_PROJECT_POST into the relevant SAP transaction such as SE37 or SE38.

Function Group: CGPL_UPDATE
Program Name: SAPLCGPL_UPDATE
Main Program:
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update: 1



Function CGPL_PROJECT_POST 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 'CGPL_PROJECT_POST'"Update Module: Projects and Tasks
TABLES
TINSERT_PROJECT = "Insert: Project Headers
TUPDATE_PROJECT = "Update: Project Headers
TDELETE_PROJECT = "Delete: Project Headers
TINSERT_TASK = "Insert: Tasks
TUPDATE_TASK = "Update: Tasks
TDELETE_TASK = "Delete: Tasks
TINSERT_HIERARCHY = "Insert: Hierarchy Entries
TUPDATE_HIERARCHY = "Update: Hierarchy Entries
TDELETE_HIERARCHY = "Delete: Hierarchy Entries

EXCEPTIONS
ERR_DELETE = 1 ERR_INSERT = 2 ERR_UPDATE = 3
.



TABLES Parameters details for CGPL_PROJECT_POST

TINSERT_PROJECT - Insert: Project Headers

Data type: CGPL_PROJECT
Optional: No
Call by Reference: Yes

TUPDATE_PROJECT - Update: Project Headers

Data type: CGPL_PROJECT
Optional: No
Call by Reference: Yes

TDELETE_PROJECT - Delete: Project Headers

Data type: CGPL_PROJECT
Optional: No
Call by Reference: Yes

TINSERT_TASK - Insert: Tasks

Data type: CGPL_TASK
Optional: No
Call by Reference: Yes

TUPDATE_TASK - Update: Tasks

Data type: CGPL_TASK
Optional: No
Call by Reference: Yes

TDELETE_TASK - Delete: Tasks

Data type: CGPL_TASK
Optional: No
Call by Reference: Yes

TINSERT_HIERARCHY - Insert: Hierarchy Entries

Data type: CGPL_HIERARCHY
Optional: No
Call by Reference: Yes

TUPDATE_HIERARCHY - Update: Hierarchy Entries

Data type: CGPL_HIERARCHY
Optional: No
Call by Reference: Yes

TDELETE_HIERARCHY - Delete: Hierarchy Entries

Data type: CGPL_HIERARCHY
Optional: No
Call by Reference: Yes

EXCEPTIONS details

ERR_DELETE - Error when deleting

Data type:
Optional: No
Call by Reference: Yes

ERR_INSERT - Error when adding

Data type:
Optional: No
Call by Reference: Yes

ERR_UPDATE - Update Error

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for CGPL_PROJECT_POST 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_err_delete  TYPE STRING, "   
lt_tinsert_project  TYPE STANDARD TABLE OF CGPL_PROJECT, "   
lv_err_insert  TYPE CGPL_PROJECT, "   
lt_tupdate_project  TYPE STANDARD TABLE OF CGPL_PROJECT, "   
lv_err_update  TYPE CGPL_PROJECT, "   
lt_tdelete_project  TYPE STANDARD TABLE OF CGPL_PROJECT, "   
lt_tinsert_task  TYPE STANDARD TABLE OF CGPL_TASK, "   
lt_tupdate_task  TYPE STANDARD TABLE OF CGPL_TASK, "   
lt_tdelete_task  TYPE STANDARD TABLE OF CGPL_TASK, "   
lt_tinsert_hierarchy  TYPE STANDARD TABLE OF CGPL_HIERARCHY, "   
lt_tupdate_hierarchy  TYPE STANDARD TABLE OF CGPL_HIERARCHY, "   
lt_tdelete_hierarchy  TYPE STANDARD TABLE OF CGPL_HIERARCHY. "   

  CALL FUNCTION 'CGPL_PROJECT_POST'  "Update Module: Projects and Tasks
    TABLES
         TINSERT_PROJECT = lt_tinsert_project
         TUPDATE_PROJECT = lt_tupdate_project
         TDELETE_PROJECT = lt_tdelete_project
         TINSERT_TASK = lt_tinsert_task
         TUPDATE_TASK = lt_tupdate_task
         TDELETE_TASK = lt_tdelete_task
         TINSERT_HIERARCHY = lt_tinsert_hierarchy
         TUPDATE_HIERARCHY = lt_tupdate_hierarchy
         TDELETE_HIERARCHY = lt_tdelete_hierarchy
    EXCEPTIONS
        ERR_DELETE = 1
        ERR_INSERT = 2
        ERR_UPDATE = 3
. " CGPL_PROJECT_POST




ABAP code using 7.40 inline data declarations to call FM CGPL_PROJECT_POST

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.

 
 
 
 
 
 
 
 
 
 
 
 


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!