Need your help with setting SQL data to FHIR resrouce

Dear Sir/Madam,

I would be so thankful if anyone advice me, which FHIR resource would be represent the following data
Patient ID, Visit ID, Diagnoses code, Diagnosis Description
12341 1 Z13.85 Encounter for screening for nervous
system disorders

I have table having four attributes( Patient ID, visit ID, Diagnoses code, Diagnosis Description) and more than 100 records, I mentioned one record example above. I would be so thankful if anyone guide me to which FHIR resource this data would be map.
I am interested the resource name.
Your king cooperation would be highly appreciated.
Looking forward to hearing from you soon.
Thanks,
Ayaz
Email: mond.ayazkn@gmail.com

What is the relationship between the diagnosis and the encounter?

Dear Sir,

Thanks for your prompt response. I don’t understand your question, but I assume that you are asking about the relationship between Visit ID and diagnosis details.

I have just this data and want to map to FHIR resources. I don’t know which resource would be feasible for this data.

Also, we have patient ID, their visit to the hospital and diagnosis details.
Visit ID, mean the patient visit ID (for example, the patient visit, sometime the patient visit multiple times on same or different dates to the hospital).
Please advice me further.
Looking forward to hearing from you soon.
Thanks,
Ayaz

You have a visit and you have a diagnosis - how are the two related? Understanding what the elements mean and how they’re related to each other is essential to being able to determine how to map them. (Relationship of patient is already clear - presumably it’s the patient who had the visit and the patient who suffers from the diagnosis.)

@mayazkn,
Getting started with FHIR is not a quick and easy process. You should plan on investing some time to understand the basics. Some of your fields are already clearly listed on the Welcome page

In the Administration box, you’ll see Patient.

A visit is a type of encounter in FHIR (and CDA). Encounter is not listed on the welcome page (which is unfortunate) but it can also be found on the administration page followed by the Encounter page.

From the Resource page understand the following:
A resource is an entity that:

  • has a known identity ([or] a URL) by which it can be addressed
    See: /fhir/resource.html#id

Patient - from the Patient page, notice it has type DomainResource which has type Resource so it has an id. You don’t actually see the id as a field on the patient Resource Content section 8.1.2 but it’s in the Resource “base class.”

An encounter is also a Resource so it has an ID, for your Visit ID.

An encounter has a diagnosis element which holds a list of diagnoses for the encounter. You should relate your diagnoses to encounters. Otherwise, if they are just problems or conditions, use the Condition element, shown as “Problem” in the Clinical box of the welcome page which actually links you to the Condition page. It’s a little confusing but Problem and Condition are equivalent in the context of FHIR.

Note that a diagnosis has a condition or “references” a condition. In section 8.11.3, you’ll see the diagnosis.condition data type is Reference.

The condition is a type of DomainReference which has a type “text” for a description (typically shown as display_name in C-CDA documents). Condition also has a “code” which is of type CodeableConcept which is explained on the DataTypes page in 2.24.0.5. The CodeableConcept has 2 fields, coding and text. Coding can be used for your diagnosis code (ICD-10, SNOMED CT, etc.). It includes a “system” field for the code system. There’s an example of a SNOMED CT Diagnosis CodeableConcept on section 2.24.1.6 with the fields you should use.

I would also take the time to learn about versioning a resource whereby the Meta.versionId is updated by the FHIR server whenever the resource changes. This is helpful to know for instance when you update a patient resource with new clinical or demographic data.

Hopefully that will get you started. If it seems frustrating, don’t worry. We’ve all had to go through it.