DP-420 practice question 19 of 25
You have an Azure Cosmos DB Core (SQL) API account. You run the following query against a container in the account. SELECT IS_NUMBER("1234") AS A, IS_NUMBER(1234) AS B, IS_NUMBER({prop: 1234}) AS C What is the output of the query?
Full set: 144 questionsCorrect Answer:
A. [{"A": false, "B": true, "C": false}]
Explanation
ISNUMBER returns true only for JSON numeric primitives.
• "1234" is a string ⇒ false.
• 1234 is a number ⇒ true.
• {prop: 1234} is an object ⇒ false. Therefore the output is [{"A": false, "B": true, "C": false}].
Why Incorrect
B. Treats number literal as non-numeric and object as numeric—opposite of function semantics.
C. Mis-labels string “1234” as numeric; object still non-numeric.
D. Says every argument is numeric; contradicts ISNUMBER definition.
References
1. Microsoft Docs – “System functions > ISNUMBER
” learn.microsoft.com/en-us/azure/cosmos-db/nosql/query/isnumber (returns true when input is numeric literal).
Keep practicing
Take the free DP-420 practice test
Ten exam-style questions with answers and explanations, plus the exam facts and study guides.
More questions
Other DP-420 practice questions
- Question 1You have an Azure Cosmos DB for NoSQL account. You need to create an Azure Monitor query …
- Question 3You have a database in an Azure Cosmos DB Core (SQL) API account. You need to create an A…
- Question 6You are troubleshooting the current issues caused by the application updates. Which actio…
- Question 9You have an Azure Cosmos DB Core (SQL) API account that is used by 10 web apps. You need …
- Question 12You need to create a data store for a directory of small and medium-sized businesses (SMB…
- Question 13You need to configure an Apache Kafka instance to ingest data from an Azure Cosmos DB Cor…
