type: fhirpath-functionfunction: lengthcategory: String Manipulationsection: 5.6.13source: fhirpath/functions.json
FHIRPath Function: length
Returns the number of characters in the input string. If the input collection is empty ({ }), the result is empty.
If the input collection contains multiple items, the evaluation of the expression will end and signal an error to the calling environment.
Summary
- Category: String Manipulation
- Section:
5.6.13 - Return Type:
Integer - Empty Input Result:
empty - Errors on Multiple Input:
true
Description
Returns the length of the input string. Returns the number of characters in the string.
Arguments
Type Mapping
Example
'abcdefg'.length() // 7
''.length() // 0