In openEHR as it stands now, the answer would be no, because the snomed-ct:263495000 code is just one binding to at0017. What is reliable in the data is the at0017 internal code.

In future, it is not out of the question that different types of OPTs would be generated that would treat bound terminology codes as if they were the structural ones, but this is probably a long way off. Some further ideas about this in the ADL2 spec <https://www.openehr.org/releases/AM/latest/docs/ADL2/ADL2.html#_terminology_integration>, and also the OPT2 spec <https://www.openehr.org/releases/AM/latest/OPT2.html>.

It also might not be hard to preprocess AQL queries written like this into the standard form, but that would require that the code snomed-ct:263495000 be bound uniquely to at0017, and no other node code e.g. at0015. So doing this would require stricter binding rules than we currently have, and which I think are not semantically justifiable.

- thomas


On 06/09/2018 09:21, Georg Fette wrote:
Hello,
In AQL it is possible to constrain the value of a node to one of the codes that are allowed for that value (as specified in the respective archetype). To find patients with gender (snomed-ct:248153007) male (snomed-ct:248153007) I could write something like this:

SELECT e FROMEHR e CONTAINSDEMOGRAPHICS d

WHERE d.items[at0017].value = 'snomed-ct:248153007'


Is it possible to identify the node of an archetype instead of its path parts (e.g. d.gender or d.items[at0017]) also with a terminology code, so the query would rather look like something like that:

SELECT e FROMEHR e CONTAINSDEMOGRAPHICS d

WHERE d.items['snomed-ct:263495000'].value = 'snomed-ct:248153007'


I am not very experienced with AQL so the queries are probably already syntactically wrong.
Greetings
Georg

--
Thomas Beale
Principal, Ars Semantica <http://www.arssemantica.com>
Consultant, ABD Project, Intermountain Healthcare <https://intermountainhealthcare.org/> Management Board, Specifications Program Lead, openEHR Foundation <http://www.openehr.org> Chartered IT Professional Fellow, BCS, British Computer Society <http://www.bcs.org/category/6044> Health IT blog <http://wolandscat.net/> | Culture blog <http://wolandsothercat.net/> | The Objective Stance <https://theobjectivestance.net/>
_______________________________________________
openEHR-technical mailing list
[email protected]
http://lists.openehr.org/mailman/listinfo/openehr-technical_lists.openehr.org

Reply via email to