OBSERVATION-from-assessments
Source file: OBSERVATION-from-assessments.py
Root XPath
./hl7:component/hl7:structuredBody/hl7:component/hl7:section/hl7:templateId[ @root="2.16.840.1.113883.10.20.22.2.8" or @root="2.16.840.1.113883.10.20.22.2.8.1"]/..
Expected OMOP domain: Observation
Fields
Field |
Type |
Order |
Details |
|---|---|---|---|
observation_id |
HASH |
1 |
hash(person_id, provider_id, observation_concept_code, observation_concept_codeSystem, observation_date, value_as_string, unit_source_value) |
person_id |
FK |
2 |
FK → |
observation_concept_id |
DERIVED |
3 |
|
observation_date |
FIELD |
4 |
|
observation_datetime |
PRIORITY |
5 |
coalesce candidates by priority |
observation_type_concept_id |
CONSTANT |
6 |
|
value_as_number |
FIELD |
7 |
|
value_as_string |
DERIVED |
8 |
|
value_as_concept_id |
DERIVED |
9 |
|
qualifier_concept_id |
None |
10 |
— |
unit_concept_id |
DERIVED |
11 |
|
provider_id |
None |
12 |
— |
visit_occurrence_id |
FK |
13 |
FK → |
visit_detail_id |
None |
14 |
— |
observation_source_value |
DERIVED2 |
15 |
{‘config_type’: ‘DERIVED2’, ‘FUNCTION’: VT.concat_field_list_values, ‘argument_list’: {‘key_list’: [‘observation_concept_code’, ‘observation_concept_codeSystem’, ‘value_codeSystem’, ‘value_code’, ‘value_as_string’, ‘value_as_number_string’]}, ‘order’: 15} |
observation_source_concept_id |
DERIVED |
16 |
|
unit_source_value |
FIELD |
17 |
|
qualifier_source_value |
CONSTANT |
18 |
|
data_partner_id |
DERIVED |
20 |
|
filename |
FILENAME |
100 |
source XML filename |
cfg_name |
CONSTANT |
101 |
|
domain_id |
DERIVED |
|
|
observation_concept_code |
FIELD |
|
|
observation_concept_codeSystem |
FIELD |
|
|
observation_datetime_effectiveTime |
FIELD |
|
|
observation_datetime_high |
FIELD |
|
|
observation_datetime_low |
FIELD |
|
|
text_value |
FIELD |
|
|
title_value |
FIELD |
|
|
unit_codeSystem |
CONSTANT |
|
|
value_as_number_string |
FIELD |
|
|
value_code |
FIELD |
|
|
value_codeSystem |
FIELD |
|
Config type reference
config_type |
Meaning |
|---|---|
ROOT |
Defines the XPath root element for this config |
FIELD |
Extracts an XML attribute value via XPath |
DERIVED |
Computed by a Python function from other fields |
HASH |
MD5/hash of a set of fields, used as a surrogate key |
FK |
Foreign key copied from a joined dataset |
CONSTANT |
Fixed literal value written to every row |
PRIORITY |
Coalesces the first non-null value from prioritized candidates |
FILENAME |
The source XML filename |
None |
Not populated (placeholder) |