Stream: implementers
Topic: Search condition along with _revinclude or _include
Meghana (Dec 05 2020 at 08:09):
Hi All,
Trying to get search API which Selects Patient and related Encounters, but only those Encounters linked to specific Episode of care.
For example:
https://{FHIRServer}/Patient?_id={patientID}&_revinclude=Encounter:patient(How to fetch Encounter linked to specific Episode of care)
Using below API I can get all Encounters linked to episode of care having certain type code. Is it possible include this search condition(episodeofcare.type) along with _revinclude in the above API
https://{FHIRServer}/Encounter?episodeofcare.type=12303
Thanks
Meghana
René Spronk (Dec 05 2020 at 13:13):
Patient?_has:Encounter:patient:episode-of-care.type=12303&_include=Encounter:patient
Michele Mottini (Dec 05 2020 at 18:34):
/Encounter?episodeofcare.type=12303&patient=[patient id]&_include=Encounter:patient
= All encounters for the specified patient and linked to the specific episode of care, include also the patient
René Spronk (Dec 06 2020 at 11:25):
/Encounter?episode-of-care.type=12303&_include=Encounter:patient (even simpler than my previous suggestion). BTW, my previous suggestion should use a _revinclude instead of an _include.
Last updated: Apr 12 2022 at 19:14 UTC