FHIR Chat · Reference to another entity in the same Bundle · implementers

Stream: implementers

Topic: Reference to another entity in the same Bundle


view this post on Zulip Joris Scharp (Nov 12 2021 at 14:16):

Hi all,

I can't seem to find any information on this, but I can imagine this use-case existing:

I want to POST a transactional Bundle to the REST API (HAPI R4) with:

  • a Patient resource (ifNoneExist conditional create, based on Patient.identifier)
  • Multiple Observations that reference to the Patient's logical id (added in the conditional create in the same Bundle)

Is it possible to do so in a single Bundle? Or would it be required to first execute the conditional create of the Patient resource and then POST the remaining resources in a Bundle?

view this post on Zulip René Spronk (Nov 12 2021 at 14:21):

Subsection 'conditional references' under http://build.fhir.org/http.html#trules may prove helpful in this context.

view this post on Zulip Joris Scharp (Nov 12 2021 at 14:24):

Ah that's amazing! I was searching in the wrong documentation part. That makes sense, thanks a lot René!

view this post on Zulip Lokesh G S (Nov 18 2021 at 04:34):

How to add revolvers to get references data

view this post on Zulip Lokesh G S (Nov 18 2021 at 05:20):

like __resolveReference in apollo graphql what do we need to do in fhir ?

view this post on Zulip Vassil Peytchev (Nov 18 2021 at 05:24):

Is _include what you are asking for? http://build.fhir.org/search.html#include

view this post on Zulip Lokesh G S (Nov 18 2021 at 07:02):

Hi @Vassil Peytchev my doubt is suppose the account schema has the patient reference ., when i am pulling the account data i need to get the patient details too

view this post on Zulip Lokesh G S (Nov 18 2021 at 07:02):

How to add the resolvers

view this post on Zulip René Spronk (Nov 18 2021 at 08:38):

That's _include, please study the page referenced above..

view this post on Zulip Lokesh G S (Nov 18 2021 at 13:10):

Actually we are doing using the graphql

view this post on Zulip Lokesh G S (Nov 18 2021 at 13:10):

Can you please help me is it same in graphql

view this post on Zulip Josh Mandel (Nov 18 2021 at 13:34):

Consider asking a question on #graphql (and the more specific you can be about what you're trying to do and what you have attempted already, the more likely you are to elicit a helpful response).


Last updated: Apr 12 2022 at 19:14 UTC