How to exclude deleted jobs from a ujo_job query
search cancel

How to exclude deleted jobs from a ujo_job query

book

Article ID: 225467

calendar_today

Updated On:

Products

CA Workload Automation AE

Issue/Introduction

When running a query against the ujo_job table, the results will sometimes contain jobs that have been recently deleted. How can the query be written to filter out the deleted jobs?

Environment

Release : 11.3.6/12.0

Component : CA Workload Automation AE (AutoSys)

Cause

The row in ujo_job for a deleted job will stay in the table for 7 days by default. At that time, they are archived by the archive_jobs command that runs as part of the DBMaint script.

Resolution

In the WHERE clause of the query, include is_active=1 AND is_currver=1 to weed out deleted jobs that have not yet been archived. The value for those columns for a deleted job would both be 0.