To what should you set the partition key and the unique key?
HOTSPOT
You have a database in an Azure Cosmos DB Core (SQL) API account.
You plan to create a container that will store employee data for 5,000 small businesses. Each business will have up to 25 employees. Each employee item will have an email Address value. You need to ensure that the email Address value for each employee within the same company is unique.
To what should you set the partition key and the unique key? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.
Answer:
Explanation:
Box 1: CompanyID
After you create a container with a unique key policy, the creation of a new or an update of an existing item resulting in a duplicate within a logical partition is prevented, as specified by the unique key constraint. The partition key combined with the unique key guarantees the uniqueness of an item within the scope of the container.
For example, consider an Azure Cosmos container with Email address as the unique key constraint and CompanyID as the partition key. When you configure the user’s email address with a unique key, each item has a unique email address within a given CompanyID. Two items can’t be created with duplicate email addresses and with the same partition key value.
Box 2: emailAddress
Reference: https://docs.microsoft.com/en-us/azure/cosmos-db/unique-keys
Latest DP-420 Dumps Valid Version with 51 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund