Procedure_occurrence

Reading from Synthea table procedures.csv

Destination Field Source field Logic Comment field
procedure_occurrence_id
person_id patient Map by mapping person.person_source_value to patient. Find person.person_id by mapping encouters.patient to person.person_source_value.
procedure_concept_id code Use code to lookup target_concept_id in CTE_TARGET_VOCAB_MAP: select ctvm.target_concept_id from procedures pr join cte_target_vocab_map ctvm on ctvm.source_code = pr.code and ctvm.target_domain_id = ‘Procedure’ and ctvm.target_vocabulary_id = ‘SNOMED’ and ctvm.target_invalid_reason is NULL and ctvm.target_standard_concept = ‘S’
procedure_date date, start(v3.0.0)
procedure_datetime date, start(v3.0.0) Use 00:00:00 as the time.
procedure_end_date stop(v3.0.0)
procedure_end_datetime stop(v3.0.0) Use 00:00:00 as the time.
procedure_type_concept_id Use concept_id 32827 (EHR encounter record) for all records.
modifier_concept_id Set to 0 for all records
quantity cast(null as integer)
provider_id encounters.provider
visit_occurrence_id encounter Lookup visit_occurrence_id using encounter, joining to temp table defined in final_visit_ids.sql.
visit_detail_id encounter Lookup visit_occurrence_id using encounter, joining to temp table defined in final_visit_ids.sql and all 1000000.
procedure_source_value code
procedure_source_concept_id code Use code to lookup source_concept_id in CTE_SOURCE_VOCAB_MAP: select csvm.source_concept_id from cte_source_vocab_map csvm join procedures pr on csvm.source_code = pr.code and csvm.source_vocabulary_id = ‘SNOMED’
modifier_source_value Set to null for all records