Selecting a job or job list
SelectJobs returns states and information for job instances. To retrieve job schedules, use SelectJobSchedules. SelectJobs retrieves information about a single job, a list of jobs, or jobs that match a certain condition. The ResultDef element specifies the job properties to retrieve, as shown in the following example:
<SOAP-ENV:Body>
<SelectJobs>
<ResultDef>
<String>JobName</String>
<String>JobId</String>
<String>State</String>
</ResultDef>
<Search>
<Condition>
<Fileld>Tokyo Forecasts</Fileld>
</Condition>
</Search>
</SelectJobs>
</SOAP-ENV:Body>
This request returns properties for the specified job and any previously generated instances of the job. A job’s state can be Pending, Running, Succeeded, Failed, Cancelled, or Expired. The response also includes the total count of jobs that match the condition.
<SOAP-ENV:Body>
<SelectJobsResponse>
<Jobs>
<JobProperties>
<JobId>2</JobId>
<JobName>Tokyo Forecasts</JobName>
<State>Succeeded</State>
</JobProperties>
<JobProperties>
<JobId>1</JobId>
<JobName>Tokyo Forecasts</JobName>
<State>Scheduled</State>
</JobProperties>
</Jobs>
<TotalCount>2</TotalCount>
</SelectJobsResponse>
</SOAP-ENV:Body>
To retrieve information regarding job schedules, use SelectJobSchedules.