Skip to contents

Moves rows in drug_exposure whose standard drug_concept_id belongs to another OMOP v5.4 clinical event domain (Device, Procedure, Observation, Measurement) into the matching domain table and removes them from drug_exposure (0.36.0, M1/M2). When routing to observation or measurement, value_as_number is set to NULL (so an administered dose is never read as a lab or vital measurement result) and the dose text and unit are preserved in value_source_value and unit_source_value.

Usage

route_drug_domains(con, dry_run = FALSE)

Arguments

con

Active DuckDB connection.

dry_run

Logical; if TRUE, return counts without modifying tables.

Value

Named list of counts (device_exposure, procedure_occurrence, observation, measurement, total_routed).