Stream: hapi
Topic: Search for resources without extension
Andrew Broadbent (Aug 11 2017 at 14:32):
Hi all,
I'm just wondering how I invert a search? I've created a search parameter which looks for all instances of basic which have an extension with a references to a particular resource. I however want to find all resources which are missing this reference?
E.g.
A:
<Basic>
<code value=""/>
</Basic>
B:
<Basic>
<code value=""/>
<extension url="urn:resref" >
<reference value/>
</extension>
</Basic>
SearchParameter:
<SearchParameter xmlns="http://hl7.org/fhir">
<name value="myres"/>
<status value="active"/>
<code value="myres"/>
<base value="Basic"/>
<type value="reference"/>
<expression value="Basic.extension('urn:resref')"/>
<xpathUsage value="normal"/>
</SearchParameter>
What would a search look like to find A? I've tried the following, but it's not correct:
[base]/Basic?myres:missing=true
Grahame Grieve (Aug 11 2017 at 21:01):
why is it not correct?
Andrew Broadbent (Aug 14 2017 at 10:01):
It returns nothing
Last updated: Apr 12 2022 at 19:14 UTC