SAP Function Modules

PA_MAINTAIN_PACKAGE_DARK SAP Function module







PA_MAINTAIN_PACKAGE_DARK is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name PA_MAINTAIN_PACKAGE_DARK into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: PA_PACKAGE_SERVICES
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM PA_MAINTAIN_PACKAGE_DARK - PA MAINTAIN PACKAGE DARK





CALL FUNCTION 'PA_MAINTAIN_PACKAGE_DARK' "
  EXPORTING
    i_operation =               "               Operation
*   i_modify_data_sign =        " scompksign
*   i_cascade_cpro_info =       " flag
*   i_suppress_dialog = ' '     " flag
  CHANGING
    c_package_data =            " scompkdtln    Package Data
*   c_transport_request =       " e070-trkorr   Transport Request
  EXCEPTIONS
    API_INIT_FAILED = 1         "               Cannot initialize package API
    OPERATION_NOT_SUPPORTED = 2  "              Operation is not supported
    NO_AUTHORIZATION = 3        "               Insufficient authorization
    PACKAGE_NOT_EXISTING = 4    "               Package Does Not Exist
    PACKAGE_DELETED = 5         "
    PACKAGE_ALREADY_EXISTING = 6  "
    PACKAGE_NOT_EMPTY = 7       "
    INVALID_PACKAGE_NAME = 8    "
    INVALID_SOFTWARE_COMPONENT = 9  "
    INVALID_TRANSPORT_LAYER = 10  "
    INVALID_TRANSPORT_PROPERTIES = 11  "
    INVALID_AUTHOR = 12         "               Invalid author
    INVALID_APPLICATION_COMPONENT = 13  "
    SHORT_TEXT_MISSING = 14     "               Short Text missing
    CANCELLED_IN_CORR = 15      "
    LOCKED_BY_OTHER_USER = 16   "
    INTERNAL_ERROR = 17         "               Internal Error
    INVALID_TRANSLATION_DEPTH = 18  "
    WRONG_MAINPACK_VALUE = 19   "
    SUPERPACKAGE_INVALID = 20   "
    ERROR_IN_CTS_CHECKS = 21    "
    .  "  PA_MAINTAIN_PACKAGE_DARK

ABAP code example for Function Module PA_MAINTAIN_PACKAGE_DARK





The ABAP code below is a full code listing to execute function module PA_MAINTAIN_PACKAGE_DARK including all data declarations. The code uses 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 original method of declaring data variables up front. 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).


DATA(ld_c_package_data) = 'Check type of data required'.

SELECT single TRKORR
FROM E070
INTO @DATA(ld_c_transport_request).

DATA(ld_i_operation) = 'some text here'.
DATA(ld_i_modify_data_sign) = 'Check type of data required'.
DATA(ld_i_cascade_cpro_info) = 'Check type of data required'.
DATA(ld_i_suppress_dialog) = 'Check type of data required'. . CALL FUNCTION 'PA_MAINTAIN_PACKAGE_DARK' EXPORTING i_operation = ld_i_operation * i_modify_data_sign = ld_i_modify_data_sign * i_cascade_cpro_info = ld_i_cascade_cpro_info * i_suppress_dialog = ld_i_suppress_dialog CHANGING c_package_data = ld_c_package_data * c_transport_request = ld_c_transport_request EXCEPTIONS API_INIT_FAILED = 1 OPERATION_NOT_SUPPORTED = 2 NO_AUTHORIZATION = 3 PACKAGE_NOT_EXISTING = 4 PACKAGE_DELETED = 5 PACKAGE_ALREADY_EXISTING = 6 PACKAGE_NOT_EMPTY = 7 INVALID_PACKAGE_NAME = 8 INVALID_SOFTWARE_COMPONENT = 9 INVALID_TRANSPORT_LAYER = 10 INVALID_TRANSPORT_PROPERTIES = 11 INVALID_AUTHOR = 12 INVALID_APPLICATION_COMPONENT = 13 SHORT_TEXT_MISSING = 14 CANCELLED_IN_CORR = 15 LOCKED_BY_OTHER_USER = 16 INTERNAL_ERROR = 17 INVALID_TRANSLATION_DEPTH = 18 WRONG_MAINPACK_VALUE = 19 SUPERPACKAGE_INVALID = 20 ERROR_IN_CTS_CHECKS = 21 . " PA_MAINTAIN_PACKAGE_DARK
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 4. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 5. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 6. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 7. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 8. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 9. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 10. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 11. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 12. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 13. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 14. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 15. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 16. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 17. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 18. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 19. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 20. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 21. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_c_package_data  TYPE SCOMPKDTLN ,
ld_i_operation  TYPE STRING ,
ld_c_transport_request  TYPE E070-TRKORR ,
ld_i_modify_data_sign  TYPE SCOMPKSIGN ,
ld_i_cascade_cpro_info  TYPE FLAG ,
ld_i_suppress_dialog  TYPE FLAG .

ld_c_package_data = 'Check type of data required'.
ld_i_operation = 'some text here'.

SELECT single TRKORR
FROM E070
INTO ld_c_transport_request.

ld_i_modify_data_sign = 'Check type of data required'.
ld_i_cascade_cpro_info = 'Check type of data required'.
ld_i_suppress_dialog = 'Check type of data required'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name PA_MAINTAIN_PACKAGE_DARK or its description.