Queries the details about a metadata table partition in Data Lake Formation (DLF).

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation uses only common request headers. For more information, see Common request parameters.

Request syntax

POST /api/metastore/catalogs/databases/tables/partitions/get 

Request parameters

ParameterTypePositionRequiredExampleDescription
ObjectBodyNo

The HTTP request body.

CatalogIdStringBodyNo1344371

The catalog ID of the metadatabase. Default value: the user ID of your Alibaba Cloud account.

DatabaseNameStringBodyNodatabase_test

The name of the metadatabase.

PartitionValuesListStringBodyNo

The values in the partition.

TableNameStringBodyNotest_table_20200715162543389

The name of the metadata table.

RegionIdStringHostNocn-hangzhou

The ID of the region where DLF is activated.

Response parameters

ParameterTypeExampleDescription
CodeStringOK

The description of the status code.

MessageString.

The error message that is returned.

PartitionPartition

The details about the partition.

RequestIdStringB7F4B621-E41E-4C84-B97F-42B5380A32BB

The ID of the request.

SuccessBooleantrue

Indicates whether the call was successful.

Error codes

NoSuchObject: The specified metadatabase, metadata table, or partition does not exist.

InternalError: An internal error has occurred. Troubleshoot the error based on the error message that is returned.

Examples

Sample requests

POST /api/metastore/catalogs/databases/tables/partitions/get HTTP/1.1 
{
    "CatalogId": "1344371",
    "DatabaseName": "database_test",
    "PartitionValues": ["20201124"],
    "TableName": "test_table_20201223"
}

Sample success responses

JSON format

{
  "Code": "OK",
  "HttpStatusCode": 200,
  "Message": "",
  "Partition": {
    "CatName": "1344371",
    "CreateTime": 1608813866,
    "DatabaseName": "database_test",
    "LastAccessTime": 0,
    "LastAnalyzedTime": 0,
    "Parameters": {
      "transient_lastDdlTime": "1608813866"
    },
    "PartitionId": "a44249eab61d495ab3f353dcd054b34b",
    "PartitionName": "day=20201124",
    "Privileges": {
      "GroupPrivileges": {},
      "RolePrivileges": {},
      "UserPrivileges": {}
    },
    "Sd": {
      "BucketCols": [],
      "Cols": [
        {
          "Comment": "user_name",
          "Id": "name",
          "Name": "name",
          "Type": "string"
        }
      ],
      "Compressed": false,
      "InputFormat": "input",
      "NumBuckets": 5,
      "OutputFormat": "output",
      "Parameters": {},
      "SerDeInfo": {
        "Parameters": {}
      },
      "SkewedInfo": {
        "SkewedColNames": [],
        "SkewedColValueLocationMaps": {},
        "SkewedColValues": []
      },
      "SortCols": [],
      "StoredAsSubDirectories": false
    },
    "TableId": "8b10f93518994891b58ce7db76df4929",
    "TableName": "test_table_20201223",
    "Values": [
      "20201124"
    ]
  },
  "RequestId": "507E9B42-9A63-418F-82CA-0EF1158D7E27",
  "Success": true
}