nerdexam
Microsoft

DP-420 · Question #168

You have an Azure subscription. The subscription contains an Azure Cosmos DB for NoSQL account named account1 that uses a default consistency level of Consistent Prefix. You execute a SELECT query…

The correct answer is D. Eventual. Azure Cosmos DB consistency levels from strongest to weakest are: Strong > Bounded Staleness > Session > Consistent Prefix > Eventual. The first query used Consistent Prefix. The only consistency level lower than Consistent Prefix is Eventual. Session, Bounded Staleness, and…

Optimize an Azure Cosmos DB solution

Question

You have an Azure subscription. The subscription contains an Azure Cosmos DB for NoSQL account named account1 that uses a default consistency level of Consistent Prefix. You execute a SELECT query and specify the Consistent Prefix consistency level. You need to execute a second SELECT query during the same session and specify a lower consistency level. Which consistency level can be used for the second SELECT query?

Options

  • ASession
  • BStrong
  • CBounded Staleness
  • DEventual

How the community answered

(44 responses)
  • A
    5% (2)
  • B
    2% (1)
  • C
    2% (1)
  • D
    91% (40)

Explanation

Azure Cosmos DB consistency levels from strongest to weakest are: Strong > Bounded Staleness > Session > Consistent Prefix > Eventual. The first query used Consistent Prefix. The only consistency level lower than Consistent Prefix is Eventual. Session, Bounded Staleness, and Strong are all higher (stronger) than Consistent Prefix, so they cannot satisfy the requirement for a lower consistency level. Within a session, you can request a weaker consistency than the account default, but you cannot request a stronger one - Eventual is the only valid choice here.

Topics

#Cosmos DB Consistency Levels#Consistent Prefix#Eventual Consistency#Request-level Consistency

Community Discussion

No community discussion yet for this question.

Full DP-420 Practice