Hi Seref, It would return a cross join of the X.attr and Y.attr, but only from EHRs with both an X and Y.
We have uses workflow ids because this is more efficient to evaluate than URIs (including links) due to string length and being bidirectional, but this only works for certain usecases. Heath. On 20/08/2012 8:49 PM, "Seref Arikan" <serefarikan at kurumsalteknoloji.com> wrote: > Greetings, > Here is the setting in which AQL is being used: > We are interested in outcomes of a particular clinical instruction in > cases where a particular observation has been recorded. > We want to get an attribute of both the observation and the and the > instruction from patient EHR. The patient's EHR has multiple observations > and instructions, as shown in the following diagram (the dual line > connections are from the partial graph representation domain, meaning a > child contained somewhere) The diagram also contains the query and other > details, which I'll discuss below > > [image: Inline image 1] > > > The problem here is that the observation and instruction tuple can be > represented in 4 ways. (I hope the diagram represents why it is so) Should > AQL implementation return all 4? Then the consumer of the result set would > have to sort things out. This is similar to RDMS behaviour when a select > statement is issued on two tables without any joins. > I'm inclined to accept this as the expected behaviour, but I'd like to > hear what others think. > > (of course, adding some constraint that would enforce the instruction to > have a creation time later than the observation would return only two > tuples, but that is not the case I'm asking for) > > Best regards > Seref > > > > _______________________________________________ > openEHR-technical mailing list > openEHR-technical at lists.openehr.org > > http://lists.openehr.org/mailman/listinfo/openehr-technical_lists.openehr.org > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.openehr.org/pipermail/openehr-technical_lists.openehr.org/attachments/20120821/59caff4c/attachment-0001.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: aql-result-set-question.png Type: image/png Size: 35089 bytes Desc: not available URL: <http://lists.openehr.org/pipermail/openehr-technical_lists.openehr.org/attachments/20120821/59caff4c/attachment-0001.png>

