FHIR Chat · reference type search parameters · implementers

Stream: implementers

Topic: reference type search parameters


view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:13):

Do we have any description of how reference type search parameters work with logical references anywhere? I can't find anything...
This paragraph doesn't mention anything relating to logical references:
http://build.fhir.org/search.html#referenceBehavior of reference type search parameters

I am currently wondering how I'd be able to search e.g. for all Patients with a specific generalPractitioner, assuming that the practitioners are only known/referenced by a national identifier.

view this post on Zulip Christiaan Knaap (Dec 29 2017 at 18:15):

I recently had the same question from a Vonk user. My simple solution was to create a custom Token-type searchparameter with an expression extracting the reference.identifier element, and search on that parameter.

view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:22):

Yes, my thought exactly. However I find it a bit strange that the resource-type search parameters target the complex type Reference (e.G. the Patient search parameter "general-practitioner" points at Patient.generalPractitioner . But somehow it is implicit that the search only operates on Patient.generalPractitioner.reference.

view this post on Zulip Christiaan Knaap (Dec 29 2017 at 18:23):

I agree that could use clarification. Do you create a CR for that?

view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:24):

BTW: Does the modifier :text do anything with reference types?
We say it targets the display portion of a CodableConcept but does it also work on the display portion of a Reference?

view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:24):

http://build.fhir.org/search.html#modifiers

view this post on Zulip Christiaan Knaap (Dec 29 2017 at 18:24):

That paragraph only defines :[type] as a valid modifier for reference parameters, not :text.

view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:26):

Right, it says "for token" in the description of :text. I missed that.

view this post on Zulip Simone Heckmann (Dec 29 2017 at 18:39):

GF#14375

view this post on Zulip Christiaan Knaap (Dec 29 2017 at 18:40):

Great

view this post on Zulip Ben Spencer (Dec 30 2017 at 07:07):

https://gforge.hl7.org/gf/project/fhir/tracker/?action=TrackerItemEdit&tracker_item_id=14103

view this post on Zulip Brian Postlethwaite (Dec 30 2017 at 23:14):

This would then only work for those using the reference identifier, and not the practitioner references where the prac instance has that value.
Or any that are a contained prac instance with that identifier.

view this post on Zulip Michele Mottini (Jan 02 2018 at 20:14):

@Simone Heckmann you can use chained searches: generalPractitioner.identifier=xxxx

view this post on Zulip Simone Heckmann (Jan 03 2018 at 13:50):

Chaining won't work when the reference doesn't point at another FHIR resource


Last updated: Apr 12 2022 at 19:14 UTC