How To
Summary
Sometimes it could occurs that
Some jobs for dynamic agents are stuck in a USERJOBS schedule. You are unable to cancel or remove these jobs that are carried forward each day.
Steps
STEP A) Clean the TAJ_TWS_AGENT_JOBS table
-------------------------------------------------------------
A.1) Identify and check the record to be removed:
select TAJ_TWS_AGENT_JOBS.TAJ_ID, TAJ_TWS_AGENT_JOBS.TAJ_EXEC_ID,
TAJ_TWS_AGENT_JOBS.TAJ_WORKSTATION_NAME,
TAJ_TWS_AGENT_JOBS.TAJ_JOB_STREAM_NAME, TAJ_TWS_AGENT_JOBS.TAJ_JOB_NAME,
TAJ_TWS_AGENT_JOBS.TAJ_JOB_NUMBER from TAJ_TWS_AGENT_JOBS where
TAJ_TWS_AGENT_JOBS.TAJ_JOB_NUMBER = <JOB_NUMBER>
A.2) Save the value of DWB.TAJ_TWS_AGENT_JOBS.TAJ_EXEC_ID in the
EXEC_KEY variable:
EXEC_KEY = TAJ_TWS_AGENT_JOBS.TAJ_EXEC_ID
A.3) Remove the record:
If the selected record is the one to be deleted, remove it by running
the following statement:
delete from TAJ_TWS_AGENT_JOBS where TAJ_TWS_AGENT_JOBS.TAJ_JOB_NUMBER
= '<JOB_NUMBER>'
STEP B) Clean the JOB_BROKER_JOBS table
---------------------------------------------------------
B.1) Identify and check the record to be removed:
select JOB_BROKER_JOBS.JOB_ID, JOB_BROKER_JOBS.JOB_NAME,
JOB_BROKER_JOBS.JOB_ALIAS_NAME from JOB_BROKER_JOBS where
JOB_BROKER_JOBS.JOB_ALIAS_NAME LIKE '%<JOB_NUMBER>'
B.2) Save the value of JOB_BROKER_JOBS.JOB_ID in the JOB_ID variable:
JOB_ID = JOB_BROKER_JOBS.JOB_ID
B.3) Remove the record:
If the selected record is the one to be deleted, remove it by running
the following statement:
delete from JOB_BROKER_JOBS where JOB_BROKER_JOBS.JOB_ID = '<JOB_ID>'
STEP C) Clean ALL_ALLOCATIONS table
-----------------------------------------------------
C.1) Identify the allocation record to be removed:
select ALL_ALLOCATIONS.ALL_ID, ALL_ALLOCATIONS.ALL_REQUEST_TIME from
ALL_ALLOCATIONS where ALL_ALLOCATIONS.ALL_CLIENT_NOTIFY_EPR LIKE
'%<EXEC_KEY>%'
C.2) Save the value of ALL_ALLOCATIONS.ALL_ID in the ALL_ID variable:
ALL_ID = ALL_ALLOCATIONS.ALL_ID
C.3) Remove the record:
delete from ALL_ALLOCATIONS where ALL_ALLOCATIONS.ALL_ID = '<ALL_ID>'
PLEASE NOTE:
If the record is not present into ALL_ALLOCATIONS then the user needs to delete only the record into JOB_BROKER_JOBS and TAJ_TWS_AGENT_JOBS
If the record into JOB_BROKER_JOBS is not found then the user can delete only the record into TAJ_TWS_AGENT_JOBS
Was this topic helpful?
Document Information
Modified date:
07 February 2020
UID
ibm10742187