Courseiva
Data Store ManagementeasyMultiple ChoiceObjective-mapped

DEA-C01 Data Store Management Practice Question

Network Topology
aws dynamodb describe-tabletable-name OrdersRefer to the exhibit."Table": {"AttributeDefinitions": ["AttributeName": "OrderID","AttributeType": "S"},"AttributeName": "CustomerID",],"TableName": "Orders","KeySchema": ["KeyType": "HASH""KeyType": "RANGE""TableStatus": "ACTIVE","ProvisionedThroughput": {"ReadCapacityUnits": 5,"WriteCapacityUnits": 5"TableSizeBytes": 0,"ItemCount": 0

A data engineer ran the above CLI command to describe an Amazon DynamoDB table named 'Orders'. The table has a key schema with 'OrderID' as the partition key and 'CustomerID' as the sort key. The table currently has no items. The engineer wants to add a new attribute 'OrderDate' and then query all orders for a specific customer within a date range. Which of the following actions is the MOST efficient approach to support this query pattern?

⚠ Common exam trap

AWS often tests the distinction between LSIs and GSIs, specifically that LSIs require the same partition key as the base table, while GSIs allow a different partition key, which is a common point of confusion for candidates.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Create a Global Secondary Index (GSI) with 'CustomerID' as partition key and 'OrderDate' as sort key.

A Global Secondary Index (GSI) allows querying on a different partition key ('CustomerID') and sort key ('OrderDate') without altering the base table's key schema. This supports efficient range queries on 'OrderDate' for a specific customer, as GSIs provide a separate index with its own provisioned throughput and can be created on existing tables with items. The base table's primary key remains unchanged, and the GSI enables the desired query pattern with low latency.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Modify the table's primary key to include 'OrderDate' as an additional sort key.

    Why it's wrong here

    Primary key cannot be altered after table creation.

  • Use a Scan operation with a filter expression on 'CustomerID' and 'OrderDate' to retrieve the data.

    Why it's wrong here

    Scan is expensive and slow for large tables; it reads every item.

  • Create a Local Secondary Index (LSI) with 'CustomerID' as partition key and 'OrderDate' as sort key.

    Why it's wrong here

    LSI must be defined at table creation; it cannot be added later.

  • Create a Global Secondary Index (GSI) with 'CustomerID' as partition key and 'OrderDate' as sort key.

    Why this is correct

    GSI can be added at any time and supports efficient queries on CustomerID and OrderDate.

About these practice questions

This DEA-C01 question is part of Courseiva's 1,711-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

1 more way this is tested on DEA-C01

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. A data engineer runs the above CLI command to describe the DynamoDB table 'Orders'. The table has a partition key 'OrderID' and sort key 'CustomerID'. Which query operation is most efficient for retrieving all orders for a specific customer?

medium
  • A.Query the table using CustomerID as the partition key
  • B.Scan the table and filter by CustomerID
  • C.Use GetItem with CustomerID as the key
  • D.Create a Global Secondary Index on CustomerID and query the index

Why D: A Global Secondary Index (GSI) on CustomerID allows you to query efficiently using CustomerID as the partition key, avoiding a full table scan. Since the base table's primary key is (OrderID, CustomerID), you cannot directly query by CustomerID alone; a GSI provides an alternative access pattern optimized for this query.

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This DEA-C01 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DEA-C01 exam.