Recall & Review
beginner
What is a key-value store in the context of databases?
A key-value store is a type of database that stores data as a collection of key and value pairs. Each key is unique and is used to retrieve the associated value quickly.
Click to reveal answer
beginner
How does a document store differ from a key-value store?
A document store is a type of key-value store where the value is a complex document, often in JSON format, allowing nested data and richer queries compared to simple key-value pairs.
Click to reveal answer
beginner
In DynamoDB, what is the role of the partition key?
The partition key, as part of the primary key (with an optional sort key), uniquely identifies each item in a DynamoDB table and determines the partition where the data is stored, enabling fast data retrieval.
Click to reveal answer
intermediate
Why are key-value and document stores considered flexible for developers?
Because they allow storing data without a fixed schema, developers can easily add or change data structures without redesigning the database.
Click to reveal answer
beginner
Give a real-life example of when to use a key-value store.
A key-value store is great for caching user session data in a web app, where each session ID (key) maps to session details (value) for quick access.
Click to reveal answer
What does a key in a key-value store represent?
✗ Incorrect
In key-value stores, the key is a unique identifier used to retrieve the associated value quickly.
Which data format is commonly used in document stores like DynamoDB?
✗ Incorrect
Document stores often use JSON format to store complex, nested data structures.
What is a main advantage of using a document store over a relational database?
✗ Incorrect
Document stores allow flexible, schema-less data storage, making it easier to evolve data models.
In DynamoDB, what determines where data is stored?
✗ Incorrect
The partition key determines the partition where the data is stored in DynamoDB.
Which scenario best fits using a key-value store?
✗ Incorrect
Key-value stores are ideal for caching session tokens because they provide fast access using unique keys.
Explain the difference between a key-value store and a document store.
Think about how simple or complex the stored data is.
You got /4 concepts.
Describe how DynamoDB uses keys to organize and retrieve data.
Focus on the role of partition and sort keys.
You got /4 concepts.