Stream: implementers
Topic: All resource type search
Shamil Nizamov (Feb 18 2022 at 18:41):
What would be an example of all resource type search other than operations, as said in the 3.1.1.2 Introduction section, i.e.:
GET [base]?parameters
Lloyd McKenzie (Feb 18 2022 at 18:47):
Not sure I understand the question. Are you just asking for an example of a cross-resource search?
Shamil Nizamov (Feb 18 2022 at 18:53):
That's what I'm trying to understand as well. The section says:
All resource types: GET [base]?parameter(s) (parameters common to all types). If the _type parameter is included, all other search parameters SHALL be common to all provided types. If _type is not included, all parameters SHALL be common to all resource types.
and then I do not see any example where a parameter would apply to the [base], again, other than operations.
Paul Church (Feb 18 2022 at 18:54):
GET [base]?_tag=XYZ
In general the search parameters common to all resource types are the ones beginning with _
.
Shamil Nizamov (Feb 18 2022 at 18:55):
OK, need to try.
Lloyd McKenzie (Feb 18 2022 at 19:29):
You could also do [base]?name=bob
- that would find all patients, practitioners, practitioner roles, devices, questionnaires and any other resources that have a 'name' search criteria and one of the names on the resource happens to start with 'bob'. (I.e. search isn't limited to only search parameters that are available on all resources.)
Shamil Nizamov (Feb 18 2022 at 19:46):
At least the HAPI FHIR test server does not support such request.
It's obviously fine with the [base]/Patient?name=<>
but not [base]?name=<>
I have not tried with other servers.
Paul Church (Feb 18 2022 at 20:33):
We didn't implement that in the Google implementation either. It's a bit weird, [base]?name is searching across a potentially very diverse set of resources. There's no guarantee that every search parameter called name
even has the same data type, let alone a compatible semantic meaning.
Last updated: Apr 12 2022 at 19:14 UTC