Book Image

DynamoDB Cookbook

By : Tanmay Deshpande
Book Image

DynamoDB Cookbook

By: Tanmay Deshpande

Overview of this book

Table of Contents (18 chapters)
DynamoDB Cookbook
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Deleting a table using the AWS SDK for .Net


Now, let's understand how to delete a DynamoDB table using the AWS SDK for .Net.

Getting ready

You can use the IDE of your choice to code these recipes.

How to do it…

In this recipe, we will learn how to delete the table that we created earlier using the AWS SDK for .Net:

  1. Create a delete table request specifying the name of the table to be deleted:

    string tableName = "productTableNet";
    var request = new DeleteTableRequest
                {
                    TableName = tableName
                };
  2. Invoke the DeleteTable method to delete the table:

       var response = client.DeleteTable(request);
  3. Like create and update, delete also takes some time before the changes are effective.

Tip

Downloading the example code

You can download the example code files from your account at http://www.packtpub.com for all the Packt Publishing books you have purchased. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed...