Question 761 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: a partition key determines the logical partition for a document.. 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 using the NoSQL API. Each document includes: PostID (unique), UserID, Timestamp, Content. The most common query is: 'Get all posts for a specific UserID, sorted by Timestamp descending.' Which partition key should be chosen to distribute load evenly across physical partitions while also supporting this query efficiently?

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

UserID

UserID is the correct partition key because it evenly distributes write operations across physical partitions (each user has a unique ID) and directly supports the most common query: filtering by UserID. With UserID as the partition key, the query 'Get all posts for a specific UserID, sorted by Timestamp descending' becomes a single-partition query (using the partition key in the WHERE clause), which is efficient and avoids cross-partition fan-out. This design also allows Cosmos DB to use the Timestamp field as a sort key within each logical partition, enabling efficient sorting without additional indexing overhead.

Key principle: A partition key determines the logical partition for a document.

Answer analysis

Option-by-option breakdown

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

  • PostID

    Why it's wrong here

    Using PostID as the partition key would distribute posts evenly, but the query for all posts of a user would need to fan out across all partitions because posts for the same user would be scattered. This increases RU consumption and latency.

  • UserID

    Why this is correct

    UserID groups all posts for a user into one logical partition, making the query efficient. With many users, the load is balanced across physical partitions, avoiding hot spots.

    Related concept

    A partition key determines the logical partition for a document.

  • Timestamp

    Why it's wrong here

    Using Timestamp as partition key often leads to hot partitions because many writes may happen at the same time (e.g., burst of posts), causing throttling. It also does not support the query efficiently because posts for a user would be scattered.

  • Content

    Why it's wrong here

    Content is not suitable as a partition key because it is typically long, variable, and leads to high cardinality without logical grouping that matches the query pattern. It would cause inefficient queries.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The trap here is that candidates often choose a unique identifier like PostID (Option A) thinking it guarantees even distribution, but they overlook that the partition key must also match the most frequent query filter to avoid cross-partition queries and high RU costs.

Detailed technical explanation

How to think about this question

Under the hood, Cosmos DB uses the partition key to hash documents into physical partitions; choosing UserID ensures that each user’s posts are co-located in the same logical partition, allowing the Timestamp sort to be performed as an in-memory operation within that partition. A common real-world pitfall is using a partition key with high cardinality but poor query alignment (e.g., PostID), which forces every query to scatter across all physical partitions, dramatically increasing RU consumption and latency. Additionally, Cosmos DB automatically indexes the partition key, so queries filtering on UserID are routed directly to the correct physical partition without scanning others.

KKey Concepts to Remember

  • A partition key determines the logical partition for a document.
  • Efficient queries target a single logical partition.
  • A good partition key has high cardinality and distributes data evenly.
  • Cross-partition queries consume more Request Units (RUs) and have higher latency.

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

A partition key determines the logical partition for a document.

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. A partition key determines the logical partition for a document. 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 a partition key determines the logical partition for a document., 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 — A partition key determines the logical partition for a document..

What is the correct answer to this question?

The correct answer is: UserID — UserID is the correct partition key because it evenly distributes write operations across physical partitions (each user has a unique ID) and directly supports the most common query: filtering by UserID. With UserID as the partition key, the query 'Get all posts for a specific UserID, sorted by Timestamp descending' becomes a single-partition query (using the partition key in the WHERE clause), which is efficient and avoids cross-partition fan-out. This design also allows Cosmos DB to use the Timestamp field as a sort key within each logical partition, enabling efficient sorting without additional indexing overhead.

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

Review a partition key determines the logical partition for a document., then practise related DP-900 questions on the same topic to reinforce the concept.

What is the key concept behind this question?

A partition key determines the logical partition for a document.

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-900 practice questions

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.