Question 321 of 982

DP-900 Practice Question: Describe considerations for working with non-relational data on Azure

This DP-900 practice question tests your understanding of describe considerations for working with non-relational data on azure. Match the stated requirement to the specific cloud service, access model, or configuration option — many options are valid in isolation but not for this scenario. A key principle to apply: partition keys in Azure Cosmos DB distribute data across logical partitions.. 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.

A social media application stores user posts in Azure Cosmos DB. Each post has fields: PostID (unique), UserID, Timestamp, Content, LikesCount. The application frequently queries for all posts by a specific UserID ordered by Timestamp descending. To minimize Request Unit (RU) consumption, which partition key and indexing strategy should be used?

Clue words in this question

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

  • Clue: "minimum / minimize"

    Why it matters: Asks for the least resource use — fewest addresses, smallest subnet, lowest overhead. Eliminate over-provisioned options even if they would technically work.

Question 1mediummultiple choice
Full question →

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

Partition key: UserID, and create a composite index on (UserID, Timestamp DESC)

Option A is correct because UserID is the most frequently filtered attribute, making it an ideal partition key to distribute data evenly and avoid cross-partition queries. Adding a composite index on (UserID, Timestamp DESC) allows the query to be served from a single physical partition with an index seek, minimizing RU consumption by avoiding a full scan or sort operation.

Key principle: Partition keys in Azure Cosmos DB distribute data across logical partitions.

Answer analysis

Option-by-option breakdown

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

  • Partition key: UserID, and create a composite index on (UserID, Timestamp DESC)

    Why this is correct

    This design localizes all posts for a user in one partition and uses an index that directly supports the filter and sort order.

    Clue confirmation

    The clue word "minimum / minimize" in the question point toward this answer.

    Related concept

    Partition keys in Azure Cosmos DB distribute data across logical partitions.

  • Partition key: Timestamp, and sort by UserID in the query

    Why it's wrong here

    Partitioning by Timestamp spreads a single user's posts across many partitions, causing expensive cross-partition queries.

  • Partition key: PostID, and use ORDER BY Timestamp

    Why it's wrong here

    Partitioning by PostID scatters data randomly; queries for a specific user would hit many partitions, increasing RU consumption.

  • Partition key: UserID, and use ORDER BY PostID

    Why it's wrong here

    Ordering by PostID does not sort by Timestamp, which is the required order. Additional sorting would be needed.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The trap here is that candidates often pick a partition key based on the ORDER BY column (Timestamp) without realizing that the filter column (UserID) should be the partition key to avoid cross-partition queries, and that a composite index is needed to avoid an expensive sort.

Detailed technical explanation

How to think about this question

In Azure Cosmos DB, a composite index on (UserID, Timestamp DESC) enables the query engine to use an index seek for the UserID filter and then retrieve results in the exact sort order without an additional sort operation. Without this composite index, the query would need to fetch all posts for the UserID and then sort them in memory, consuming more RUs. This pattern is critical for feed-like queries where users view their own posts in reverse chronological order.

KKey Concepts to Remember

  • Partition keys in Azure Cosmos DB distribute data across logical partitions.
  • Queries targeting a single partition key value are more efficient (lower RU cost).
  • Composite indexes support queries with multiple filter conditions and specific sort orders.
  • An index on (field1, field2 DESC) directly supports queries filtering by field1 and ordering by field2 descending.

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

Partition keys in Azure Cosmos DB distribute data across logical partitions.

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. Partition keys in Azure Cosmos DB distribute data across logical partitions. 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.

Review partition keys in Azure Cosmos DB distribute data across logical partitions., then practise related DP-900 questions on the same topic to reinforce the concept.

Related practice questions

Related DP-900 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-900 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-900 question test?

Describe considerations for working with non-relational data on Azure — This question tests Describe considerations for working with non-relational data on Azure — Partition keys in Azure Cosmos DB distribute data across logical partitions..

What is the correct answer to this question?

The correct answer is: Partition key: UserID, and create a composite index on (UserID, Timestamp DESC) — Option A is correct because UserID is the most frequently filtered attribute, making it an ideal partition key to distribute data evenly and avoid cross-partition queries. Adding a composite index on (UserID, Timestamp DESC) allows the query to be served from a single physical partition with an index seek, minimizing RU consumption by avoiding a full scan or sort operation.

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

Review partition keys in Azure Cosmos DB distribute data across logical partitions., then practise related DP-900 questions on the same topic to reinforce the concept.

Are there clue words in this question I should notice?

Yes — watch for: "minimum / minimize". Asks for the least resource use — fewest addresses, smallest subnet, lowest overhead. Eliminate over-provisioned options even if they would technically work.

What is the key concept behind this question?

Partition keys in Azure Cosmos DB distribute data across logical partitions.

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

Last reviewed: Jun 11, 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-900 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-900 exam.