A developer is working on an existing application that uses Amazon DynamoDB as its data store. The DynamoDB table has the following attributes: partNumber (partition key), vendor (sort key), description, productFamily, and productType. When the developer analyzes the usage patterns, the developer notices that there are application modules that frequently look for a list of products based on the productFamily and productType attributes. The developer wants to make changes to the application to improve performance of the query operations. Which solution will meet these requirements?
Select one answer.
Marked answer: A
Community Discussion
Written by other learners. Comments can disagree with the marked answer — check the official documentation when in doubt.
Chose A2
A) Correct - GSI will give alternative Primary Key (HASH or HASH + Sort Key) from the base table. B) Eliminated - An LSI shares the same partition key as the base table but allows a different sort key. LSIs must be defined at the time of table creation and cannot be added to an existing table.
Chose A1
A is the correct answer.
Chose C1
Option C improve more performance. The question didn't care about effort