Select your cookie preferences

We use cookies and similar tools to enhance your experience, provide our services, deliver relevant advertising, and make improvements. Approved third parties also use these tools to help us deliver advertising and provide certain site features.

delete_table

delete_table(**kwargs)

Removes a table definition from the Data Catalog.

Note

After completing this operation, you no longer have access to the table versions and partitions that belong to the deleted table. Glue deletes these "orphaned" resources asynchronously in a timely manner, at the discretion of the service.

To ensure the immediate deletion of all related resources, before calling DeleteTable , use DeleteTableVersion or BatchDeleteTableVersion , and DeletePartition or BatchDeletePartition , to delete any resources that belong to the table.

See also: AWS API Documentation

Request Syntax

response = client.delete_table(
    CatalogId='string',
    DatabaseName='string',
    Name='string',
    TransactionId='string'
)
Parameters
  • CatalogId (string) -- The ID of the Data Catalog where the table 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 resides. For Hive compatibility, this name is entirely lowercase.

  • Name (string) --

    [REQUIRED]

    The name of the table to be deleted. For Hive compatibility, this name is entirely lowercase.

  • TransactionId (string) -- The transaction ID at which to delete the table contents.
Return type

dict

Returns

Response Syntax

{}

Response Structure

  • (dict) --

Exceptions

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