string-length
The length of a string
Description
The fn-string-length function returns an xs:integer value indicating the number of characters in the string. Whitespace is significant, so leading and trailing whitespace characters are counted.
Parameters |
Description |
---|---|
arg:string() |
Examples
XPath |
Results |
---|---|
string-length(‘query’) |
5 |
string-length(’ query ‘) |
9 |
string-length(normalize-space(’ query ‘)) |
5 |
string-length(‘xml query’) |
9 |
string-length(‘’) |
0 |
string-length(()) |
0 |