batch_delete_partition

Glue.Client.batch_delete_partition(**kwargs)

Deletes one or more partitions in a batch operation.

See also: AWS API Documentation

Request Syntax

response = client.batch_delete_partition(
    CatalogId='string',
    DatabaseName='string',
    TableName='string',
    PartitionsToDelete=[
        {
            'Values': [
                'string',
            ]
        },
    ]
)
Parameters
  • CatalogId (string) -- The ID of the Data Catalog where the partition to be deleted resides. If none is provided, the Amazon Web Services account ID is used by default.
  • DatabaseName (string) --

    [REQUIRED]

    The name of the catalog database in which the table in question resides.

  • TableName (string) --

    [REQUIRED]

    The name of the table that contains the partitions to be deleted.

  • PartitionsToDelete (list) --

    [REQUIRED]

    A list of PartitionInput structures that define the partitions to be deleted.

    • (dict) --

      Contains a list of values defining partitions.

      • Values (list) -- [REQUIRED]

        The list of values.

        • (string) --
Return type

dict

Returns

Response Syntax

{
    'Errors': [
        {
            'PartitionValues': [
                'string',
            ],
            'ErrorDetail': {
                'ErrorCode': 'string',
                'ErrorMessage': 'string'
            }
        },
    ]
}

Response Structure

  • (dict) --

    • Errors (list) --

      The errors encountered when trying to delete the requested partitions.

      • (dict) --

        Contains information about a partition error.

        • PartitionValues (list) --

          The values that define the partition.

          • (string) --
        • ErrorDetail (dict) --

          The details about the partition error.

          • ErrorCode (string) --

            The code associated with this error.

          • ErrorMessage (string) --

            A message describing the error.

Exceptions

  • Glue.Client.exceptions.InvalidInputException
  • Glue.Client.exceptions.EntityNotFoundException
  • Glue.Client.exceptions.InternalServiceException
  • Glue.Client.exceptions.OperationTimeoutException