Navigation :
fieldCount
fieldCount, function
def pure fieldCount(haystack: text, separator: text): number
Returns the number of fields separated by separator in haystack.
haystack: text to split.
separator: delimiter between fields.
Examples
haystack = "a-b-c"
separator = "-"
count = fieldCount(haystack, separator)
table S = with
[| as Count |]
[| count |]
show table "Field count" with
S.Count
This produces the following table:
Errors
separator cannot be empty.
fieldCount is case-sensitive.
See also