ehrbase / openEHR_SDK

A SDK to facilitate the development of openEHR applications
Other
48 stars 28 forks source link

composition.versionUid is not being populated in a query output #44

Closed ppazos closed 4 years ago

ppazos commented 4 years ago

In a query that returns compositions like:

Query<Record1<IntensivmedizinischesMonitoringKorpertemperaturComposition>> query =
                Query.buildNativeQuery("SELECT c FROM EHR e CONTAINS COMPOSITION c where "
                     + "c/archetype_details/template_id/value = 'Intensivmedizinisches Monitoring Korpertemperatur' AND "
                     + "e/ehr_status/subject/external_ref/id/value = '"+ subject_id.getValue() +"'",
                     IntensivmedizinischesMonitoringKorpertemperaturComposition.class);

List<Record1<IntensivmedizinischesMonitoringKorpertemperaturComposition>> results = new ArrayList<Record1<IntensivmedizinischesMonitoringKorpertemperaturComposition>>();

results = service.getClient().aqlEndpoint().execute(query);

If I iterate through the results and print the compo.getVersionUid(), the value is null.

Full code: https://github.com/ehrbase/fhir-bridge/blob/master/src/main/java/org/ehrbase/fhirbridge/fhir/provider/ObservationResourceProvider.java#L80

stefanspiska commented 4 years ago

@ppazos Can you recheck with the newest develop. This should have been fixed already .

ppazos commented 4 years ago

@stefanspiska tested this and it's working as expected in the last develop.