Creating a Table .......................................................................................................... 66
Updating a Table .......................................................................................................... 67
Deleting a Table ........................................................................................................... 68
Listing Tables .............................................................................................................. 68
Example: Create, Update, Delete and List Tables - Java Document API ................................. 69
Working with Tables - .NET Low-Level API ............................................................................... 71
Creating a Table .......................................................................................................... 72
Updating a Table .......................................................................................................... 73
Deleting a Table ........................................................................................................... 74
Listing Tables .............................................................................................................. 74
Example: Create, Update, Delete and List Tables - .NET Low-Level API ................................ 75
Working with Tables - PHP Low-Level API ................................................................................ 78
Creating a Table .......................................................................................................... 79
Updating a Table .......................................................................................................... 80
Deleting a Table ........................................................................................................... 81
Listing Tables .............................................................................................................. 81
Example: Create, Update, Delete and List Tables - PHP Low-Level API ................................. 82
Working with Items ....................................................................................................................... 85
Overview ............................................................................................................................ 85
Reading an Item .................................................................................................................. 86
Read Consistency ........................................................................................................ 87
Writing an Item .................................................................................................................... 87
Batch Operations ................................................................................................................. 88
Atomic Counters .................................................................................................................. 88
Conditional Writes ................................................................................................................ 88
Reading and Writing Items Using Expressions .......................................................................... 91
Case Study: A ProductCatalog Item ................................................................................ 91
Accessing Item Attributes with Projection Expressions ....................................................... 92
Using Placeholders for Attribute Names and Values ........................................................... 94
Specifying Conditions with Condition Expressions ............................................................. 96
Modifying Items and Attributes with Update Expressions ................................................... 100
Guidelines for Working with Items ......................................................................................... 106
Use One-to-Many Tables Instead Of Large Set Attributes .................................................. 106
Use Multiple Tables to Support Varied Access Patterns ..................................................... 107
Compress Large Attribute Values .................................................................................. 108
Store Large Attribute Values in Amazon S3 ..................................................................... 108
Break Up Large Attributes Across Multiple Items ............................................................. 109
Working with Items - Java Document API ............................................................................... 110
Putting an Item .......................................................................................................... 110
Getting an Item .......................................................................................................... 113
Batch Write: Putting and Deleting Multiple Items .............................................................. 115
Batch Get: Getting Multiple Items .................................................................................. 116
Updating an Item ....................................................................................................... 118
Deleting an Item ....................................................................................................... 120
Example: CRUD Operations - Java Document API ........................................................... 120
Example: Batch Operations - Java Document API ............................................................ 125
Example: Handling Binary Type Attributes - Java Document API ......................................... 129
Working with Items - .NET Low-Level API ............................................................................... 132
Putting an Item .......................................................................................................... 133
Getting an Item .......................................................................................................... 135
Updating an Item ....................................................................................................... 136
Atomic Counter .......................................................................................................... 138
Deleting an Item ....................................................................................................... 138
Batch Write: Putting and Deleting Multiple Items .............................................................. 139
Batch Get: Getting Multiple Items .................................................................................. 141
Example: CRUD Operations - .NET Low-Level API ........................................................... 144
Example: Batch Operations - .NET Low-Level API ........................................................... 151
Example: Handling Binary Type Attributes - .NET Low-Level API ........................................ 162
API Version 2012-08-10
iv
Amazon DynamoDB Developer Guide