Excessive row count for a job in the ujo_job_runs table
search cancel

Excessive row count for a job in the ujo_job_runs table


Article ID: 138957


Updated On:


CA Workload Automation AE - Business Agents (AutoSys) CA Workload Automation AE - System Agent (AutoSys) CA Workload Automation AE - Scheduler (AutoSys) Workload Automation Agent Autosys Workload Automation


Some new jobs were inserted with some conditions set such that they were repeatedly run or rather autosys performed the processing of events but did not actually run the jobs as they were on noexec status.
The jobs did this for some time such that now they have a LARGE amount of history which impacts WCC's performance when trying to display the job in things like QuickView as it pulls back the past runs, and 3000k runs take some time to pull back. The environment is keeping six months of history, configured via DBMaint. With that being the case it would take some time before those records are automatically purged.

How can they be manually purged?





Release : 11.3.6

Component : CA Workload Automation AE (AutoSys)


The tables that need to be altered are 

First get the joid for the job(s) as the job_name is NOT in the tables we are deleting from.

select joid,job_name from aedbadmin.ujo_jobst where job_name = '<jobname>';

Run the above multiple times if there is more than one job who's history you want to delete.

Then you can run the following for each job:

delete from aedbadmin.ujo_job_runs where joid = <#_from_above_query>;
delete from aedbadmin.ujo_extended_jobrun_info where joid = <#_from_above_query>;
delete from aedbadmin.ujo_proc_event where joid = <#_from_above_query>;

That would delete ALL the events and past runs from the database associated with the job(s).
Consider running a database reorg and/or a reindex afterwards as well to aid in database performance and reclaim space.