Was this helpful?
ELEMENT_COUNT Function
Splits the source string into elements separated by separator and returns the number of elements within input source string.
The following table lists the valid parameters:
Parameter
Description
src
Specifies the source string.
sep
Specifies the separator that can be used to search.
Examples
If the separator is an empty string, each unicode character in the source string is regarded as an element. The element_count function returns the number of elements (or count) only:
element_count('abcdefg', '') = 7
The element_count function returns 0 if both the source string and the separator are empty strings.
element_count('' , '') = 0
The element_count function returns NULL if and only if any argument is NULL.
Last modified date: 08/29/2024