DynamoDB Query in AWS Management Console

Perform the following steps:

  1. Sign in to the AWS Management Console and open the DynamoDB console at https://console.aws.amazon.com/dynamodb/
  2. In the DynamoDB navigation pane, choose Tables and choose user-visits
  3. On the user-visits pane, choose the Items* tab
  4. Select Query from the dropdown
  5. Under Partition Key, type 324
  6. Under Sort Key, select > and type 20171001
  7. Select Start Search

You will see that no results are returned, as we are looking for records with EventDay greater than 20171001 and there are none in the current table.

Modify the following to find the record:

  1. Under Sort Key, select >= and type 20171001
  2. Select Start Search

You will now see that the record we added is visible, as it meets the query search criterion.

Modify the following to find the record:

  1. Under Sort Key, select between and type 20170930 and 20171002
  2. Select Start Search

Here, we use the between condition to retrieve the records too.

This query flexibility gives you the ability to retrieve data at a very low latency. However, you will notice that the partition key for the condition expression is always fixed to =, and has to be provided to all Query operations—this is something common in many NoSQL databases. If you do not have, or know, the primary key, then you need to use Scan instead.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset