SAP BP_JOBCONTEXT_ADD Function Module for









BP_JOBCONTEXT_ADD is a standard bp jobcontext add 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 bp jobcontext add FM, simply by entering the name BP_JOBCONTEXT_ADD into the relevant SAP transaction such as SE37 or SE38.

Function Group: BTCHCNTXT
Program Name: SAPLBTCHCNTXT
Main Program: SAPLBTCHCNTXT
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function BP_JOBCONTEXT_ADD 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 'BP_JOBCONTEXT_ADD'"
EXPORTING
JOBNAME = "
JOBCOUNT = "
* NO_CHECK = "
* NO_EXISTENCE_CHECK = "

TABLES
JOBCONTEXTS = "

EXCEPTIONS
EMPTY_CONTEXTS_TABLE = 1 EMPTY_CONTEXTTYPES_TABLE = 2 MISSING_JOBNAME_OR_JOBCOUNT = 3 INCOMPLETE_CONTEXT = 4 INVALID_CONTEXT_TYPE = 5 JOB_FOR_CONTEXT_NOT_FOUND = 6 UNKNOWN_JOB_ERROR = 7 DUPLICATE_CONTEXT_RECORD = 8 JOB_LOCKING_ERROR = 9
.



IMPORTING Parameters details for BP_JOBCONTEXT_ADD

JOBNAME -

Data type: TBTCO-JOBNAME
Optional: No
Call by Reference: Yes

JOBCOUNT -

Data type: TBTCO-JOBCOUNT
Optional: No
Call by Reference: Yes

NO_CHECK -

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

NO_EXISTENCE_CHECK -

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

TABLES Parameters details for BP_JOBCONTEXT_ADD

JOBCONTEXTS -

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

EXCEPTIONS details

EMPTY_CONTEXTS_TABLE -

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

EMPTY_CONTEXTTYPES_TABLE -

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

MISSING_JOBNAME_OR_JOBCOUNT -

Data type:
Optional: No
Call by Reference: Yes

INCOMPLETE_CONTEXT -

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

INVALID_CONTEXT_TYPE -

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

JOB_FOR_CONTEXT_NOT_FOUND -

Data type:
Optional: No
Call by Reference: Yes

UNKNOWN_JOB_ERROR -

Data type:
Optional: No
Call by Reference: Yes

DUPLICATE_CONTEXT_RECORD -

Data type:
Optional: No
Call by Reference: Yes

JOB_LOCKING_ERROR -

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for BP_JOBCONTEXT_ADD 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_jobname  TYPE TBTCO-JOBNAME, "   
lt_jobcontexts  TYPE STANDARD TABLE OF BTCJOBCTXT, "   
lv_empty_contexts_table  TYPE BTCJOBCTXT, "   
lv_jobcount  TYPE TBTCO-JOBCOUNT, "   
lv_empty_contexttypes_table  TYPE TBTCO, "   
lv_no_check  TYPE C, "   
lv_missing_jobname_or_jobcount  TYPE C, "   
lv_incomplete_context  TYPE C, "   
lv_no_existence_check  TYPE C, "   
lv_invalid_context_type  TYPE C, "   
lv_job_for_context_not_found  TYPE C, "   
lv_unknown_job_error  TYPE C, "   
lv_duplicate_context_record  TYPE C, "   
lv_job_locking_error  TYPE C. "   

  CALL FUNCTION 'BP_JOBCONTEXT_ADD'  "
    EXPORTING
         JOBNAME = lv_jobname
         JOBCOUNT = lv_jobcount
         NO_CHECK = lv_no_check
         NO_EXISTENCE_CHECK = lv_no_existence_check
    TABLES
         JOBCONTEXTS = lt_jobcontexts
    EXCEPTIONS
        EMPTY_CONTEXTS_TABLE = 1
        EMPTY_CONTEXTTYPES_TABLE = 2
        MISSING_JOBNAME_OR_JOBCOUNT = 3
        INCOMPLETE_CONTEXT = 4
        INVALID_CONTEXT_TYPE = 5
        JOB_FOR_CONTEXT_NOT_FOUND = 6
        UNKNOWN_JOB_ERROR = 7
        DUPLICATE_CONTEXT_RECORD = 8
        JOB_LOCKING_ERROR = 9
. " BP_JOBCONTEXT_ADD




ABAP code using 7.40 inline data declarations to call FM BP_JOBCONTEXT_ADD

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 JOBNAME FROM TBTCO INTO @DATA(ld_jobname).
 
 
 
"SELECT single JOBCOUNT FROM TBTCO INTO @DATA(ld_jobcount).
 
 
 
 
 
 
 
 
 
 
 


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!