ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

SQL: Display counts for all job statuses in Backlog/History

book

Article ID: 88881

calendar_today

Updated On:

Products

CA Automic Applications Manager (AM)

Issue/Introduction

SQL: Display counts for all job statuses in Backlog/History

Environment

Release: AAMOS499000-8.0-Automic Applications Manager-OS400 Agent
Component:

Resolution

Detailed Description and Symptoms

Below is the SQL required to get a count of the jobs in Backlog or History based on their unique status names.


Solution

?Backlog:

select so_status_name, count(*)
from so_job_queue
group by so_status_name;

History:

select so_status_name, count(*)
from so_job_history
group by so_status_name;