Check whether string 1 starts with string 2
The following construct(s) refer to this construct:
fn:starts-with(string $string, string $startString) => boolean
fn:starts-with(string $string, string $startString, string $collation) => boolean
This function checks whether or not the value of $string
starts with the value of $startString
. If the value of
$startString
is a string of length zero, the function returns
true
. If the value of $string
is a string of length
zero, but the value of $startString
is not, the function returns
false
. If the value of either string is the empty sequence, the
function returns the empty sequence.
$string |
string value |
---|---|
$startString |
string value to be searched for in |
$collation |
optional valid collation string literal |
Select all patients that have some form of angina:
for $a in input()/patient let $b := $a/submitted/diagnosis where starts-with($b, "Angina") return $a/name