Hi Igor,

 

AQL allows string RegEx pattern in an archetype predicate. RegEx pattern
needs to be enclosed by '{/' RegEx '/}'. For your scenario, the AQL may
include something like:

 

 ...[openEHR-EHR-CLUSTER.a.v1]
/items[{/openEHR-EHR-CLUSTER\.b(-[a-zA-Z0-9])*\.v1/}]     /
items[at0003]/value

 

Or something like the one below. The expression below is for retrieving both
element [at0003] instance value and the specialization of this element if
the specialized archetype has specialization of element at0003 (such as
at0003.1):

 

...[openEHR-EHR-CLUSTER.a.v1]
/items[{/openEHR-EHR-CLUSTER\.b(-[a-zA-Z0-9])*\.v1/}]     /
items[{/at0003([0-9.]+)*/}]/value

 

Hope this helps. Please let me know if you have more questions.

 

Regards,

 

Chunlan

 

From: [email protected]
[mailto:openehr-clinical-bounces at openehr.org] On Behalf Of ????? ???????
Sent: Monday, 28 June 2010 1:30 PM
To: openehr-clinical at openehr.org
Subject: AQL query to archetype and it's specializations in slot

 

Hi!

I have an archetype 'A' with slot named 'Slot In A'. 
There is constraint for possible archetypes for this slot: "B and
specializations of B".

I know that in archetype B (and in all of it's specializations) there is
field 'at0003' named 'Field In B'

I know only about B and particular clients has their own independent
specializations 'B-spec'.

Now I want to build a query like this:

...[openEHR-EHR-CLUSTER.a.v1]    /items[openEHR-EHR-CLUSTER.b.v1]     /
items[at0003]/value

And I want something like "Archetype of this type and it's specializations"
instead of just this "items[openEHR-EHR-CLUSTER.b.v1]".

The question is: how :-)


-- 
Best regards,
Igor Lizunov

-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<http://lists.openehr.org/mailman/private/openehr-clinical_lists.openehr.org/attachments/20100628/1eb69e24/attachment.html>

Reply via email to