Summary of Table Storage functionality

The Azure Table Storage REST API is compliant with the OData protocol specification, with some differences, as described in the following sections.

Table Storage extensions

Table Storage extends the functionality of OData in the following ways.

Shared Key, Shared Key Lite, and Azure Active Directory authorization

Table Storage requires that each request be authorized. Shared Key, Shared Key Lite, and Microsoft Entra ID authorization are supported. Microsoft Entra ID authorization is more secure, and it's recommended for requests made against Table Storage by using the REST API.

For more information about authorizing requests, see Authorize requests to Azure Storage.

Continuation tokens for query pagination

A query against Table Storage can return a maximum of 1,000 items at one time, and can run for a maximum of five seconds. If the result set contains more than 1,000 items, or if the query didn't finish within five seconds, the response includes headers. These headers provide the developer with continuation tokens to use, in order to resume the query at the next item in the result set. Continuation token headers can be returned for a Query Tables operation or a Query Entities operation.

Note that the total time allotted to the request for scheduling and processing the query is 30 seconds, including the five seconds for query execution.

For more information about continuation tokens, see Query timeout and pagination.

Primary key system properties

Every entity in Table Storage has two key properties: the PartitionKey property and the RowKey property. These properties form the table's primary key, and uniquely identify each entity in the table.

Both properties require string values. It's the developer's responsibility to provide values for these properties when a new entity is inserted, and to include them in any update or delete operation on an entity.

For more information about these required key properties, see Understanding the Table Storage data model.

Timestamp system property

Every entity in Table Storage has a Timestamp system property. The Timestamp property is a DateTime value, maintained on the server side, to record the time an entity was last modified. Table Storage uses the Timestamp property internally to provide optimistic concurrency. The value of Timestamp is a monotonically increasing value, meaning that each time the entity is modified, the value of Timestamp increases for that entity. This property should not be set on insert or update operations (the value will be ignored).

For more information about the Timestamp property, see Understanding the Table Storage data model.

Batch operations

Table Storage supports batch transactions on entities that are in the same table and belong to the same partition group, which means they have the same PartitionKey value. This allows multiple insert, update, merge, and delete operations to be supported within a single atomic transaction. Table Storage supports a subset of the functionality provided by the OData protocol.

For more information about batch operations, see Performing entity group transactions.

Table Storage restrictions

Table Storage has the following restrictions on functionality provided by OData.

Credentials property

Table Storage doesn't support using the Credentials property of the DataServiceContext class to authorize a request. Instead, you must authorize a request against Table Storage by adding an Authorization header to the request. For more information, see Authorize requests to Azure Storage.

Property types

Not all property types supported by OData are supported. For a list of supported property types, see Understanding the Table Storage data model.

Table Storage doesn't currently support links between tables. Links are associative relationships between data.

Operations on select properties

Projection refers to querying a subset of the properties for an entity or entities. It's analogous to selecting a subset of the columns or properties of a table when you're querying in language-integrated queries (LINQ).

Projection reduces the amount of data that must be returned by a query by specifying that only certain properties are returned in the response. Projection is supported as part of the 2011-08-18 version of Azure Storage. For more information, see Query Entities, Writing LINQ queries against Table Storage, and OData: Select System Query Option ($select).

LINQ query operators

Table Storage supports the following LINQ query operators:

  • From

  • Where

  • Take

For more information, see Query operators supported for Table Storage.

LINQ comparison operators

You can use a subset of the comparison operators provided by LINQ. For more information, see Querying tables and entities and Writing LINQ queries against Table Storage.

GetMetadataURI method

You can use the GetMetadataURI method of the DataServiceContext class, but it doesn't return any schema information beyond the three fixed schema properties. These properties are PartitionKey, RowKey, and Timestamp.

Payload formats

OData supports sending payloads in JSON format. Table Storage supports the OData JSON format as of API version 2013-08-15, with the OData data service version set to 3.0. Prior versions don't support the JSON format.

Atom payloads are supported in all versions prior to 2015-12-11. Version 2015-12-11 and later support only JSON payloads.

Note

JSON is the recommended payload format, and it's the only format supported for version 2015-12-11 and later.

For more information, see Payload format for Table Storage operations and Setting the OData data service version headers.

See also

Table Storage REST API