DP-420 · Question #169
You have an Azure subscription that contains an Azure Cosmos DB for NoSQL database named DB1. In DB1, you plan to create a container that will use a hierarchical partition key. You need to identify…
The correct answer is D. PartitionKeyBuilder. Manually specify the path The PartitionKeyBuilder class in the SDK can construct a value for a previously defined hierarchical partition key path. Use this class when you add a new item to a container that has subpartitioning enabled…
Question
You have an Azure subscription that contains an Azure Cosmos DB for NoSQL database named DB1. In DB1, you plan to create a container that will use a hierarchical partition key. You need to identify which hierarchical partition key path to use when adding new items to the container. Which SDK class should you use?
Options
- ACompositePath
- BPartitionKeyDefinition
- CPartitionKey
- DPartitionKeyBuilder
How the community answered
(49 responses)- A4% (2)
- B8% (4)
- C2% (1)
- D86% (42)
Explanation
Manually specify the path The PartitionKeyBuilder class in the SDK can construct a value for a previously defined hierarchical partition key path. Use this class when you add a new item to a container that has subpartitioning enabled. https://learn.microsoft.com/en-us/azure/cosmos-db/hierarchical-partition-keys
Topics
Community Discussion
No community discussion yet for this question.