Question 817 of 846
Design and implement data storagehardMultiple ChoiceObjective-mapped

Quick Answer

The answer is the unique key on orderId does not index the field, so queries by orderId are cross-partition. This is the most likely cause of high RU consumption because a unique key constraint in Azure Cosmos DB for NoSQL only enforces uniqueness across items; it does not automatically create an index for efficient querying. Without an explicit indexing policy that includes orderId, any query filtering on that field cannot be served from a single physical partition, forcing a fan-out scan across all partitions and dramatically increasing Request Units. On the DP-203 exam, this scenario tests your understanding of the critical distinction between indexing and unique constraints—a common trap is assuming a unique key provides query performance benefits. Remember: a unique key is for data integrity, not query speed; always verify your indexing policy separately. Memory tip: “Unique keys lock data, indexes unlock queries.”

DP-203 Design and implement data storage Practice Question

This DP-203 practice question tests your understanding of design and implement data storage. The scenario asks you to isolate a root cause — eliminate options that address a different problem before choosing. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.

Exhibit

{
  "name": "CustomerOrders",
  "properties": {
    "ResourceType": "Microsoft.DocumentDB/databaseAccounts/sqlDatabases/containers",
    "Options": {
      "throughput": 400
    },
    "Resource": {
      "id": "CustomerContainer",
      "partitionKey": {
        "paths": ["/customerId"],
        "kind": "Hash"
      },
      "indexingPolicy": {
        "indexingMode": "consistent",
        "automatic": true,
        "includedPaths": [
          {
            "path": "/*"
          }
        ],
        "excludedPaths": [
          {
            "path": "/\"_etag\"/?"
          }
        ]
      },
      "uniqueKeyPolicy": {
        "uniqueKeys": [
          {
            "paths": ["/orderId"]
          }
        ]
      }
    }
  }
}

Refer to the exhibit. You are reviewing an Azure Cosmos DB for NoSQL container configuration. The container stores customer orders. The application frequently queries orders by orderId. However, these queries are consuming high RUs and are slow. What is the most likely cause?

Clue words in this question

Noticing these words before you look at the options changes how you read each choice.

  • Clue: "most likely"

    Why it matters: Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

Question 1hardmultiple choice
Full question →

Exhibit

{
  "name": "CustomerOrders",
  "properties": {
    "ResourceType": "Microsoft.DocumentDB/databaseAccounts/sqlDatabases/containers",
    "Options": {
      "throughput": 400
    },
    "Resource": {
      "id": "CustomerContainer",
      "partitionKey": {
        "paths": ["/customerId"],
        "kind": "Hash"
      },
      "indexingPolicy": {
        "indexingMode": "consistent",
        "automatic": true,
        "includedPaths": [
          {
            "path": "/*"
          }
        ],
        "excludedPaths": [
          {
            "path": "/\"_etag\"/?"
          }
        ]
      },
      "uniqueKeyPolicy": {
        "uniqueKeys": [
          {
            "paths": ["/orderId"]
          }
        ]
      }
    }
  }
}

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

The unique key on orderId does not index the field; queries by orderId are cross-partition.

Option A is correct because the unique key constraint on `orderId` does not automatically create an index for that field; it only enforces uniqueness. Without an explicit indexing policy that includes `orderId`, queries filtering by `orderId` must perform a cross-partition scan, which consumes high RUs and is slow. In Azure Cosmos DB for NoSQL, queries that cannot be served from a single physical partition due to missing index or partition key mismatch result in fan-out across all partitions, dramatically increasing RU consumption.

Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Answer analysis

Option-by-option breakdown

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

  • The unique key on orderId does not index the field; queries by orderId are cross-partition.

    Why this is correct

    Unique keys do not serve as indexes; the query must specify customerId to be efficient.

    Clue confirmation

    The clue word "most likely" in the question point toward this answer.

    Related concept

    Read the scenario before looking for a memorised answer.

  • The _etag field is excluded from indexing, causing high RU for queries that include it.

    Why it's wrong here

    _etag exclusion is standard and does not affect orderId queries.

  • The indexing mode is set to consistent, which causes high RU usage.

    Why it's wrong here

    Consistent indexing is standard and not the cause.

  • The container is provisioned with only 400 RU/s, which is too low for the workload.

    Why it's wrong here

    High RU consumption is due to cross-partition queries, not low throughput.

Common exam traps

Common exam trap: answer the scenario, not the keyword

Microsoft often tests the misconception that a unique key constraint automatically creates an index for querying, when in fact unique keys only enforce uniqueness and do not affect query performance; the trap is that candidates confuse unique keys with indexing policies.

Detailed technical explanation

How to think about this question

Azure Cosmos DB uses a hash-based partition key to distribute data across physical partitions. When a query filter does not include the partition key, the query engine must fan out to all partitions, each incurring RU cost. Even if `orderId` is unique, without an index on that field, each partition must scan all documents to find matches. The indexing policy must explicitly include `orderId` (e.g., as a composite index or a custom index path) to enable efficient point lookups. In real-world scenarios, this often happens when developers assume unique keys automatically create indexes, leading to unexpected cross-partition queries.

KKey Concepts to Remember

  • Read the scenario before looking for a memorised answer.
  • Find the constraint that changes the correct option.
  • Eliminate answers that are true in general but not in this case.

TExam Day Tips

  • Watch for words such as best, first, most likely and least administrative effort.
  • Review why wrong options are wrong, not only why the correct option is correct.

Key takeaway

Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Real-world example

How this comes up in practice

A cloud solutions architect for a retail company is evaluating services for a new workload. The correct answer here reflects best practice for the specific scenario described — not a general cloud recommendation. Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option. Cloud exam questions reward reading the constraint carefully: the same technology can be right or wrong depending on the use case.

What to study next

Got this wrong? Here's your next step.

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Related practice questions

Related DP-203 practice-question pages

Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.

Practice this exam

Start a free DP-203 practice session

Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.

FAQ

Questions learners often ask

What does this DP-203 question test?

Design and implement data storage — This question tests Design and implement data storage — Read the scenario before looking for a memorised answer..

What is the correct answer to this question?

The correct answer is: The unique key on orderId does not index the field; queries by orderId are cross-partition. — Option A is correct because the unique key constraint on `orderId` does not automatically create an index for that field; it only enforces uniqueness. Without an explicit indexing policy that includes `orderId`, queries filtering by `orderId` must perform a cross-partition scan, which consumes high RUs and is slow. In Azure Cosmos DB for NoSQL, queries that cannot be served from a single physical partition due to missing index or partition key mismatch result in fan-out across all partitions, dramatically increasing RU consumption.

What should I do if I get this DP-203 question wrong?

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Are there clue words in this question I should notice?

Yes — watch for: "most likely". Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

What is the key concept behind this question?

Read the scenario before looking for a memorised answer.

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Keep practising

More DP-203 practice questions

Last reviewed: Jun 30, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

This DP-203 practice question is part of Courseiva's free Microsoft 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 DP-203 exam.