The DeleteTable operation deletes a table and all of its items. After a DeleteTable request, the specified table is in the DELETING state until DynamoDB completes the deletion. If the table is in the ACTIVE state, you can delete it. If a table is in CREATING or UPDATING states, then DynamoDB returns a ResourceInUseException . If the specified table does not exist, DynamoDB returns a ResourceNotFoundException . If table is already in the DELETING state, no error is returned.
NOTE: DynamoDB might continue to accept data read and write operations, such as GetItem and PutItem, on a table in the DELETING state until the table deletion is complete.
When you delete a table, any indexes on that table are also deleted.
Use the DescribeTable API to check the status of the table.
 Declaration Syntax
 Declaration Syntax| C# | 
public class DeleteTableRequest : AmazonWebServiceRequest
 Members
 Members| All Members | Constructors | Methods | Properties | ||
| Icon | Member | Description | 
|---|---|---|
|  | DeleteTableRequest()()()() | Initializes a new instance of the DeleteTableRequest class | 
|  | Equals(Object) | (Inherited from Object.) | 
|  | GetHashCode()()()() | Serves as a hash function for a particular type. (Inherited from Object.) | 
|  | GetType()()()() | Gets the type of the current instance.(Inherited from Object.) | 
|  | TableName | 
            The name of the table to delete.
             
             Constraints: | 
|  | ToString()()()() | Returns a string that represents the current object.(Inherited from Object.) | 
|  | WithTableName(String) | Obsolete. 
            Sets the TableName property
             | 
 Examples
 ExamplesThis example shows how to delete a table.
 CopyDeleteTable sample
CopyDeleteTable sample// Create a client AmazonDynamoDBClient client = new AmazonDynamoDBClient(); // Configure the DeleteTable request DeleteTableRequest request = new DeleteTableRequest { TableName = "SampleTable" }; // Issue DeleteTable request and retrieve the table description TableDescription tableDescription = client.DeleteTable(request).DeleteTableResult.TableDescription; Console.WriteLine("Table name: {0}", tableDescription.TableName); Console.WriteLine("Table status: {0}", tableDescription.TableStatus);
 Inheritance Hierarchy
 Inheritance Hierarchy| Object | ||
|  | AmazonWebServiceRequest | |
|  | DeleteTableRequest | |
 See Also
 See Also