ARRAY_LENGTH (NoSQL query)
APPLIES TO:
NoSQL
Returns the number of elements in the specified array expression.
Syntax
ARRAY_LENGTH(<array_expr>)
Arguments
Description | |
---|---|
array_expr |
An array expression. |
Return types
Returns a numeric expression.
Examples
The following example illustrates how to get the length of an array using the function.
SELECT VALUE {
length: ARRAY_LENGTH([70, 86, 92, 99, 85, 90, 82]),
emptyLength: ARRAY_LENGTH([]),
nullLength: ARRAY_LENGTH(null)
}
[
{
"length": 7,
"emptyLength": 0
}
]
Remarks
- This system function doesn't use the index.
Related content
प्रतिक्रिया
https://aka.ms/ContentUserFeedback.
जल्द आ रहा है: 2024 के दौरान हम सामग्री के लिए फीडबैक तंत्र के रूप में GitHub मुद्दों को चरणबद्ध तरीके से समाप्त कर देंगे और इसे एक नई फीडबैक प्रणाली से बदल देंगे. अधिक जानकारी के लिए, देखें:के लिए प्रतिक्रिया सबमिट करें और देखें