Most SQL-like languages have the ability of returning literals (constants) as results of the query. It could be useful for CDSS-like queries. e.g.
SELECT "true" as dangerousBP
FROM EHR [ehr_id/value=$ehrUid] CONTAINS COMPOSITION [openEHR-EHR-COMPOSITION.encounter.v1]
CONTAINS OBSERVATION obs [openEHR-EHR-OBSERVATION.blood_pressure.v1]
WHERE obs/data[at0001]/events[at0006]/data[at0003]/items[at0004]/value/magnitude>= 180 OR
Bostjan: already implemented in Think!EHR
SA: could be done by a function 'const'?
with all the experience/competency of a clinical hacker I will offer my support for ‘literals’ (sometimes known as ‘constants’ in certain SQL implementations)’).
I would actually prefer to only use the term “literal” and never mention “constants” in this context, but if the others wish to have that clarification in the text, I won’t oppose it.
ok, agree and changed text according to suggestions above
In 3.4.12, the following text “All strings are enclosed in double or single quotes. Line breaks are not supported.” should probably read “All string literals…”.