SAP Function JOB_CLOSE - Close Background Request With COMMIT WORK

Parameter Reference Type Length Default Optional Text
AT_OPMODE SPFBA-BANAME C 20 SPACE X Job Start for Operation Mode: Operation Mode Name
AT_OPMODE_PERIODIC BTCH0000-CHAR1 C 1 SPACE X Job Start is Periodic According to Operation Mode
CALENDAR_ID TBTCJOB-CALENDARID C 2 SPACE X Factory Calendar ID for Start Date Restriction
DIRECT_START BTCH0000-CHAR1 C 1 X "X" - Start Without Converting to Time-Based Job
DONT_RELEASE BTCH0000-CHAR1 C 1 SPACE X Job Not Released in Spite of Start Condition
EVENT_ID TBTCJOB-EVENTID C 32 SPACE X Job Start After Event: Event Name
EVENT_PARAM TBTCJOB-EVENTPARM C 64 SPACE X Job Start After Event: Event Parameter
EVENT_PERIODIC BTCH0000-CHAR1 C 1 SPACE X Job Start is Periodic According to Event
JOBCOUNT TBTCJOB-JOBCOUNT C 8 Job number
JOBNAME TBTCJOB-JOBNAME C 32 Job Name
LASTSTRTDT TBTCJOB-LASTSTRTDT D 8 NO_DATE X No Start After: Date
LASTSTRTTM TBTCJOB-LASTSTRTTM T 6 NO_TIME X No Start After: Time
PRDDAYS TBTCJOB-PRDDAYS N 3 0 X Day Portion of Job Repetition Period
PRDHOURS TBTCJOB-PRDHOURS N 2 0 X Minute Portion of Job Repetition Period
PRDMINS TBTCJOB-PRDMINS N 2 0 X Hour Portion of Job Repetition Period
PRDMONTHS TBTCJOB-PRDMONTHS N 2 0 X Month Portion of Job Repetition Period
PRDWEEKS TBTCJOB-PRDWEEKS N 2 0 X Week Portion of Job Repetition Period
PREDJOB_CHECKSTAT TBTCSTRT-CHECKSTAT C 1 SPACE X Start Job Only if Predecessor Runs Without Error
PRED_JOBCOUNT TBTCJOB-JOBCOUNT C 8 SPACE X Job Start After Predecessor Job: Predecessor Job Count
PRED_JOBNAME TBTCJOB-JOBNAME C 32 SPACE X Job Start After Predecessor Job: Predecessor Job Name
RECIPIENT_OBJ SWOTOBJID u 100 X The Mail Recipient of the Spool Lists
SDLSTRTDT TBTCJOB-SDLSTRTDT D 8 NO_DATE X Start Date of Background Job
SDLSTRTTM TBTCJOB-SDLSTRTTM T 6 NO_TIME X Time of Start Date of Background Job
STARTDATE_RESTRICTION TBTCJOB-PRDBEHAV C 1 BTC_PROCESS_ALWAYS X Restrictions for Start Date
START_ON_WORKDAY_NOT_BEFORE TBTCSTRT-NOTBEFORE D 8 SY-DATUM X Earliest Start Date for Start 'On Workday'
START_ON_WORKDAY_NR TBTCSTRT-WDAYNO N 2 0 X Number of Workday on Which Job is to Start
STRTIMMED BTCH0000-CHAR1 C 1 SPACE X Immediate Execution of Background Job
TARGETGROUP BPSRVGRP C 20 SPACE X Target Application Server Group for Job
TARGETSERVER BTCTGTSRVR-SRVNAME C 20 SPACE X Target Application Server for Job
TARGETSYSTEM 0 SPACE X Target System of Job
WORKDAY_COUNT_DIRECTION TBTCSTRT-WDAYCDIR N 2 0 X Direction of Workday Count

Parameter Reference Type Length Text
JOB_WAS_RELEASED BTCH0000-CHAR1 C 1 = 'X', if Job Was Released

Parameter Reference Type Length Default Optional Text
RET I I 4 X Special Additional Error Code

Exception Text
CANT_START_IMMEDIATE Cannot Start Immediately
INVALID_STARTDATE Start Condition is Invalid
INVALID_TARGET Target Server or Group is Invalid
JOBNAME_MISSING Job Name Missing (Wildcards Allowed)
JOB_CLOSE_FAILED Error During JOB_CLOSE, See SYSLOG
JOB_NOSTEPS Job Specified Does Not Contain Any Steps
JOB_NOTEX Specified Job Does Not Exist
LOCK_FAILED Lock Attempt Failed


INCLUDE BC_JOB_CLOSE OBJECT DOKU ID TX
Note: if a user does not have the authorization to release a job, thenthe job is scheduled with the status planned. The job cannot bestarted until it is released, regardless of any start specificationsmade for the job.
This parameter is returned with the value X, if the job wasautomatically released for execution at the scheduled start time.
A job is automatically released if the user has release authorizaton(authorization Background Processing: Operations on BackgroundJobs), RELE authorization or object Background Processing:Background Administrator.
INCLUDE BC_CCMS_BTC_AT_OPMODE OBJECT DOKU ID TX

Description
Set this parameter to the value X, if a job is always to bestarted when the operation mode specified in the parameter AT_OPMODEis activated.

Description
ID number of the factory calendar in the SAP system, with which youwant to specify whether there are restrictions for the start date.
Specify a factory calendar if you are scheduling a job for a particulartime or a particular date, and there are restrictions, such as whetherthe job can be started on non-work days. The factory calendar is used tospecify whether the proposed start date falls on a work-free day ornot.

Description
Although the job is closed with a start condition (for example,
start date <(>&<)> time), the job should not be released.

Default
Not set; that is, the job will be released, so long as the conditionsallow this.

Description
Name of the event for which a job is to wait. The job can be started ifthe event is triggered in the background processing system.
You can use transaction SM62 to display the events that have beendefined in the system.

Description
Enter the event argument for which the job is to wait. If you specifyan argument, the job can only be started if both the event specifiedin the parameter EVENT-ID and this argument are triggered in thebackground processing system.

Description
Set this parameter to the value X, if a job is always to bestarted, if the event specified in the parameters EVENT_ID andEVENT_PARAM is triggered.
INCLUDE 'BP_JOBLOG_READ JOBCOUNT' OBJECT DOKU ID FU
INCLUDE 'BP_JOBLOG_READ JOBNAME' OBJECT DOKU ID FU

Description
The last possible start date for the job. This specification is optionaland applies only for jobs that were scheduled for a particular timeor a particular date.

Description
The last possible start time for the job. This specification is optionaland applies only to jobs that were scheduled for a particular time ora particular date.
INCLUDE BC_CCMS_BTC_PRDDAYS OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PRDHOURS OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PRDMINS OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PRDMONTHS OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PRDWEEKS OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PREDJOB_CHECKSTA OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PREDJOB_COUNT OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_PREDJOB_NAME OBJECT DOKU ID TX

Description
The receiver ID of the spool list receiver.

Value range
Valid IDs can be created using office functions.

Default
space
INCLUDE BC_CCMS_BTC_STARTDATE OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_STARTTIME OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_STARTDATERESMEAN OBJECT DOKU ID TX
INCLUDE BC_CCMS_BTC_STARTDATERESRANG OBJECT DOKU ID TX

Description
Set this parameter to X, if the job is to be scheduled withimmediate start.

Description
A job can be scheduled with a target server group.
The jobs with this parameter then only run on the servers in the group.
The named target server group must already be defined in the system.
To place a job more precisely, the parameter Target Server should beused.

Value range
The parameter is optional. A consistency check is performed if a targetserver group, a target system or target server is specified.

Default
space

Description
The application server where the job is to run.
Application server is a more specific definition than target system andshould therefore be used.

Default
Not set
Optionally, you can enter the name of the host system on which this jobis to be processed. This is useful, for example, if a job is to use aresource that is available only on a particular host.
An SAP instance with background work processes must be running on thehost that you specify.
Note that another parameter targetserver is more precise than

targetsystem and should be used instead
Caution: In general, you should not set this option, as iteffectively turns off the automatic workload balancing of thebackground processing system. Workload balancing distributes thebackground processing workload evenly among the available SAPbackground servers.

1332133Using job API to create a job with a spool list recipient
1583563Process Model: Email from print parameter not in spool
4751Job chains, job streams, jobs with successors
1530713Improved load balancing
1366729TDMS data transfer error: duplicate keys for many objects
817709DB6: DB6CONV: Complete version history