OData Filters in Azure Batch

OData filters are used to limit the amount of data returned from a query issued to the Batch service by filtering the results based on some criteria. Filter conditions can be combined using the "AND" and "OR" operators. Not every API supports filter queries, and each supported API allows filtering on a unique set of properties, as listed below.

List node agent skus

Reference

Property Operations allowed Type
osType eq, ne String

List certificates

Reference

Property Operations allowed Type
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime

List nodes in a pool

Reference

Property Operations allowed Type
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
lastBootTime eq, ne, ge, gt, le, lt DateTime
allocationTime eq, ne, ge, gt, le, lt DateTime
startTaskInfo/state eq String
startTaskInfo/result eq, ne String
startTaskInfo/exitCode eq, ne, ge, gt, le, lt Int
startTaskInfo/startTime eq, ne, ge, gt, le, lt DateTime
startTaskInfo/endTime eq, ne, ge, gt, le, lt DateTime

List pool node counts

Reference

Property Operations allowed Type
poolId eq String

List task files

Reference

Property Operations allowed Type
name startswith String

List compute node files

Reference

Property Operations allowed Type
name startswith String

List jobs in a job schedule

Reference

Property Operations allowed Type
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
creationTime eq, ne, ge, gt, le, lt DateTime
lastModified eq, ne, ge, gt, le, lt DateTime
executionInfo/startTime eq, ne, ge, gt, le, lt DateTime
executionInfo/endTime eq, ne, ge, gt, le, lt DateTime
executionInfo/poolId startswith, eq, ne, ge, gt, le, lt String

List job schedules

Reference

Property Operations allowed Type
id startswith, eq, ne, ge, gt, le, lt String
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
creationTime eq, ne, ge, gt, le, lt DateTime
lastModified eq, ne, ge, gt, le, lt DateTime
executionInfo/endTime eq, ne, ge, gt, le, lt DateTime
schedule/doNotRunUntil eq, ne, ge, gt, le, lt DateTime
schedule/doNotRunAfter eq, ne, ge, gt, le, lt DateTime

List jobs

Reference

Property Operations allowed Type
id startswith, eq, ne, ge, gt, le, lt String
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
creationTime eq, ne, ge, gt, le, lt DateTime
lastModified eq, ne, ge, gt, le, lt DateTime
executionInfo/startTime eq, ne, ge, gt, le, lt DateTime
executionInfo/endTime eq, ne, ge, gt, le, lt DateTime
executionInfo/poolId startswith, eq, ne, ge, gt, le, lt String

List pools

Reference

Property Operations allowed Type
id startswith, eq, ne, ge, gt, le, lt String
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
allocationState eq String
allocationStateTransitionTime eq, ne, ge, gt, le, lt DateTime
creationTime eq, ne, ge, gt, le, lt DateTime
enableAutoScale eq, ne Boolean
lastModified eq, ne, ge, gt, le, lt DateTime
vmSize eq, ne String
enableInterNodeCommunication eq, ne Boolean

List job preparation and release status

Reference

Property Operations allowed Type
poolId eq, ne String
nodeId eq, ne String
jobPreparationTaskExecutionInfo/state eq, ne String
jobPreparationTaskExecutionInfo/startTime eq, ne, ge, gt, le, lt DateTime
jobPreparationTaskExecutionInfo/endTime eq, ne, ge, gt, le, lt DateTime
jobPreparationTaskExecutionInfo/exitCode eq, ne, ge, gt, le, lt Int
jobPreparationTaskExecutionInfo/result eq, ne String
jobReleaseTaskExecutionInfo/state eq, ne String
jobReleaseTaskExecutionInfo/startTime eq, ne, ge, gt, le, lt DateTime
jobReleaseTaskExecutionInfo/endTime eq, ne, ge, gt, le, lt DateTime
jobReleaseTaskExecutionInfo/exitCode eq, ne, ge, gt, le, lt Int
jobReleaseTaskExecutionInfo/result eq, ne String

List tasks

Reference

Property Operations allowed Type
id startswith, eq, ge, gt, le, lt, ne String
state eq, ne String
stateTransitionTime eq, ne, ge, gt, le, lt DateTime
creationTime eq, ne, ge, gt, le, lt DateTime
lastModifiedTime eq, ne, ge, gt, le, lt DateTime
executionInfo/startTime eq, ne, ge, gt, le, lt DateTime
executionInfo/endTime eq, ne, ge, gt, le, lt DateTime
executionInfo/exitCode eq, ne, ge, gt, le, lt Int
executionInfo/result eq, ne String

List account usage metrics

Reference

Property Operations allowed Type
poolId eq, ge, gt, le, lt, startswith String