FHIR to OMOP FHIR IG, published by HL7 International / Biomedical Research and Regulation. This guide is not an authorized publication; it is the continuous build for version 2.0.0-ballot built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/HL7/fhir-omop-ig/ and changes regularly. See the Directory of published versions
| Official URL: http://hl7.org/fhir/uv/omop/StructureMap/PersonMap | Version: 2.0.0-ballot | ||||
| Standards status: Trial-use | Maturity Level: 2 | Computable Name: PersonMap | |||
| Other Identifiers: OID:2.16.840.1.113883.4.642.40.77.43.8 | |||||
This mapping maps FHIR Patient instances to OMOP Person Table objects.
FHIR to OMOP gender mapping requires attention to both technical precision and the evolving OHDSI conventions around gender and sex data representation. The key to successful implementation lies in establishing clear protocols that respect the OHDSI community's ratified conventions, maintaining comprehensive validation across both Person and Observation domain tables, and preparing for future standard evolution while ensuring current system reliability and accuracy.
NOTE: The OMOP concept identifiers shown in the examples on this page reflect the OHDSI Standardized Vocabularies as they stood when this guide was written. Concept mappings, Standard concept designations, domain assignments, and display names can change between vocabulary releases. Implementers ought to verify these values against the vocabulary version their transformation is bound to rather than copying them forward.
FHIR implements gender as a CodeableConcept within the Patient resource, providing flexibility in representation while maintaining standardization. The gender field accepts four primary values:
The CodeableConcept structure allows implementers to include additional context through display text and system URIs, enabling reference to established terminologies such as SNOMED CT or HL7 value sets.
OMOP takes a more rigid approach through the gender_concept_id field in the person table. This field requires a mandatory reference to standardized vocabulary concepts:
MALE, Gender vocabulary)FEMALE, Gender vocabulary)UNKNOWN, Gender vocabulary)Unknown, PCORNet vocabulary)The last two entries deserve attention, because they show a condition that recurs throughout vocabulary work and is easily mistaken for an error in the guide. Concepts 8551 and 44814653 both carry the display name Unknown. To a transformation engine matching on display text, they are indistinguishable, and a pipeline that resolves concepts by name rather than by identifier will choose between them arbitrarily.
They are not the same concept. 8551 belongs to the Gender vocabulary and sits in the Gender domain. 44814653 belongs to the PCORNet vocabulary and sits in the Observation domain. Neither is a Standard concept. The FHIR other value is being served here by a concept drawn from a different vocabulary and a different domain than the one serving unknown, which is why two rows that look alike carry different meaning.
What separates them is provenance, not display. The vocabulary_id, the domain_id, and the source system that supplied the value are what allow a human reviewer to tell one from the other, and they are what an ETL specification has to record. An implementation that documents only the display name has discarded the information that makes its own assignment reconstructable. This is the practical reason the source value preservation guidance in this guide asks for the original code and system to be retained alongside the resolved concept: a resolved identifier does not always disambiguate itself.
Implementers mapping the FHIR other value ought to record the selection explicitly in their ETL documentation, naming the concept chosen and the basis for choosing it, so that a later reader can distinguish a deliberate assignment from a display-name collision.
The mandatory nature of this field ensures every person record contains gender information, requiring careful handling of missing or null values during transformation.
Important OHDSI Convention Update: The OHDSI community has recognized that the term "gender_concept_id" is outdated and ought to more accurately be "sex_concept_id" to reflect biological sex rather than gender identity. However, due to the significant development effort required to change this field name across all OMOP implementations and package dependencies, this update will be implemented in the next major release of the OMOP Common Data Model.
The OHDSI community has established important conventions regarding gender-related data storage in the OMOP Common Data Model that directly impact FHIR to OMOP mapping strategies. The current gender_concept_id field in the OMOP person table represents a legacy naming convention that causes conceptual confusion. The OHDSI community acknowledges that this field more accurately represents biological sex rather than gender identity. The preferred term ought to be sex_concept_id to reflect this distinction properly.
Implementation Timeline: Due to the substantial development effort required to rename this field across all OMOP implementations, packages, and dependent systems, this change will be implemented in the next major release of the OMOP Common Data Model. Until then, implementers ought to understand that gender_concept_id conceptually represents biological sex.
Scope: This convention applies to any database that captures gender identity information, regardless of data provenance or source system. Core Principle: Any gender-related information that can change over time, particularly gender identity, ought to be stored in the OBSERVATION table rather than the person table. Rationale: The person table is designed for relatively static demographic information, while the OBSERVATION table accommodates time-varying clinical and social observations, making it the appropriate location for gender identity data that might evolve over time.
The key distinctions implementers must understand are:
gender_concept_id field in the person table ought to be treated as biological sex informationsex_concept_id in the next major OMOP releaseBy following these implementation guidelines and adhering to OHDSI conventions, healthcare organizations can achieve reliable, compliant, and inclusive gender data transformation that supports both clinical care and research objectives while properly distinguishing between biological sex and gender identity.
When mapping FHIR resources that contain gender identity information (as distinguished from biological sex), implementers should:
gender_concept_id for biological sex information onlyGiven the OHDSI conventions, the mapping strategy must differentiate between biological sex and gender identity:
For Biological Sex (Person Table):
gender_concept_id using the established concept IDsFor Gender Identity (Observation Table):
person_idThe core mapping process follows these direct transformations:
| FHIR Gender Value | OMOP Concept ID | Description |
|---|---|---|
| "male" | 8507 |
This represents the most straightforward mapping case, where explicit male identification in FHIR translates directly to the OMOP male concept. |
| "female" | 8532 |
Female gender identification follows the same direct mapping approach, ensuring consistency across both standards. |
| "other" | 44814653 |
This mapping accommodates diverse gender identities that fall outside traditional binary classifications, providing inclusive representation in OMOP. |
| "unknown" | 8551 |
When gender information is explicitly marked as unknown in FHIR, this maps to the corresponding unknown concept in OMOP. |
The most complex aspect of FHIR to OMOP gender mapping involves managing absent gender information. Since OMOP requires a gender_concept_id for every person record, implementers must establish clear protocols for null value handling.
Recommended Approach: When gender information is completely absent from the FHIR resource, assign OMOP concept ID 0, indicating no appropriate concept could be determined. This approach maintains data integrity while acknowledging information gaps.
Alternative Consideration: Some implementations might prefer mapping null values to concept ID 8551 (Unknown), treating missing information as equivalent to unknown gender. Organizations ought to establish consistent policies based on their specific requirements and regulatory environment.
The HL7 Gender Harmony Project produced a FHIR implementation Guide that introduces sophisticated gender and sex categorization that extends beyond traditional binary representations. Implementation teams ought to prepare for enhanced gender concepts including:
These concepts will require OMOP vocabulary extensions and updated mapping protocols as standards evolve.
Different healthcare jurisdictions might have specific requirements for gender data representation. Implementation teams must consider:
As the OMOP Common Data Model evolves, implementation teams should:
gender_concept_id to sex_concept_id in the next major OMOP releaseMonitor Gender Harmony Project developments for vocabulary updates, particularly:
Language: en
/// url = 'http://hl7.org/fhir/uv/omop/StructureMap/PersonMap' /// name = 'PersonMap' /// title = 'Mapping Patient resource to Person OMOP Domain' /// status = 'active' /// description = 'This mapping maps FHIR Patient instances to OMOP Person Table objects.' uses "http://hl7.org/fhir/StructureDefinition/Patient" alias Patient as source uses "http://hl7.org/fhir/uv/omop/StructureDefinition/Person" alias PersonTable as target group Person(source src : Patient, target tgt : PersonTable) { // OMOP person ID would be a map from FHIR ID to an external key src as s -> tgt then { s.id as id -> tgt.person_source_value, tgt.person_id = cast(id, 'integer'); } "personID"; src.gender as gender -> tgt.gender_concept_id = translate(gender, 'http://hl7.org/fhir/uv/omop/ConceptMap/GenderClass', 'code'), tgt.gender_source_value = gender; src where (src.gender.empty()) -> tgt.gender_concept_id = 0, tgt.gender_source_value = 'unknown' "nogender"; src.birthDate as bdSrc -> tgt.birth_datetime = cast(bdSrc, 'dateTime'), tgt.year_of_birth = (src.birthDate.toString().substring(0, 4)), tgt.month_of_birth = (src.birthDate.toString().substring(5, 2)), tgt.day_of_birth = (src.birthDate.toString().substring(8, 2)); }