This topic describes how to use Tablestore SDK for Python. The content in this topic applies to Tablestore SDK for Python V4.x.x.

Prerequisites

Download Tablestore SDK for Python

  • Download Tablestore SDK for Python by using the SDK package. For more information, see SDK package.
  • Download Tablestore SDK for Python from GitHub. For more information, visit GitHub.

For the versions of Tablestore SDK for Python, see SDK for Python.

Compatibility

  • Tablestore SDK for Python V5.x.x: compatible.
  • Tablestore SDK for Python V4.x.x: compatible.
  • Tablestore SDK for Python V2.x.x: incompatible. Tablestore SDK for Python V2.x.x supports primary key columns in random order, which are no longer supported in Tablestore SDK for Python V4.0.0 and later. Tablestore SDK for Python V4.x.x and Tablestore SDK for Python V2.x.x are incompatible in the following respects:
    • The package name is changed from ots2 to tablestore.
    • The TableOptions parameter is added for the Client.create_table operation.
    • The type of the primary_key parameter is changed from dict to list for the put_row, get_row, and update_row operations to ensure the sequence of primary keys.
    • The type of the attribute_columns parameter is changed from dict to list for the put_row and update_row operations.
    • The timestamp parameter is added to the attribute_columns parameter for the put_row and update_row operations.
    • The max_version and time_range parameters are added for the get_row and get_range operations. You must specify at least one of max_version and time_range.
    • The return_type parameter is added for the put_row, update_row, and delete_row operations. Only RT_PK is supported to return the primary key value of the current row.
    • The return_row parameter is added for the put_row, update_row, and delete_row operations. If you set return_type to RT_PK in the request, the primary key value of the row is returned in return_row.

Version

Latest version: 5.1.0.