length - Get the length of a string
The length
function will return a count of the number of individual characters in a string.
Syntax
Arguments
Name | Type | Required | Description |
---|---|---|---|
value | string | true | The string whose length we seek |
Example - Basic usage
There are two ways to invoke length
, either as a function of a string or as a standalone function.
Consider the following document:
If I wish to get the length of str_val
, and store it in a new field entitled str_val_len
, I can do so in two ways:
I can also invoke length
on a field separately:
Theme
Light