0
0
DynamoDBquery~30 mins

Contributor Insights in DynamoDB - Mini Project: Build & Apply

Choose your learning style9 modes available
Contributor Insights with DynamoDB
📖 Scenario: You work for a small online bookstore. You want to track which authors contribute the most books to your inventory. This helps you understand popular authors and manage stock better.
🎯 Goal: Create a DynamoDB table to store book data, enable Contributor Insights to track the number of books per author, and query the insights to see top contributors.
📋 What You'll Learn
Create a DynamoDB table named Books with BookID as the primary key.
Add items with BookID, Title, and Author attributes.
Enable Contributor Insights on the Author attribute to count books per author.
Write a query to retrieve the top authors by book count.
💡 Why This Matters
🌍 Real World
Tracking contributors helps businesses understand which authors or creators are most active and popular, aiding inventory and marketing decisions.
💼 Career
Many data analyst and database administrator roles require knowledge of monitoring and analyzing data contributions using tools like DynamoDB Contributor Insights.
Progress0 / 4 steps
1
Create the DynamoDB table and add book items
Create a DynamoDB table called Books with BookID as the primary key. Then add these three items exactly: {"BookID": "1", "Title": "The Great Gatsby", "Author": "F. Scott Fitzgerald"}, {"BookID": "2", "Title": "1984", "Author": "George Orwell"}, and {"BookID": "3", "Title": "Animal Farm", "Author": "George Orwell"}.
DynamoDB
Need a hint?

Use aws dynamodb create-table to create the table and aws dynamodb put-item to add items.

2
Enable Contributor Insights on the Author attribute
Enable Contributor Insights on the Books table for the Author attribute to track the number of books contributed by each author.
DynamoDB
Need a hint?

Use aws dynamodb update-contributor-insights with --contributor-insights-action ENABLE and specify the Author attribute.

3
Query Contributor Insights for top authors
Write a command to query Contributor Insights on the Books table to get the top authors by the number of books contributed.
DynamoDB
Need a hint?

Use aws dynamodb describe-contributor-insights to get the insights data.

4
Complete the setup by confirming Contributor Insights status
Add a command to confirm that Contributor Insights is enabled and running on the Books table.
DynamoDB
Need a hint?

Use aws dynamodb list-contributor-insights to check the status of Contributor Insights.