lsc-sde / dbt_omop_rxn_silver

Transformations, tests and snapshots for generating a clean 'silver' OMOP layer from raw 'bronze' layer.
0 stars 0 forks source link

Date constraints and tests for sources #11

Open quindavies opened 9 months ago

quindavies commented 9 months ago

CARE_SITE

Not applicable

CONDITION_OCCURRENCE

For discussion

condition_start_datetime <= death_datetime condition_start_datetime >= visit_start_datetime condition_start_datetime <= visit_end_datetime

DEVICE_EXPOSURE

DRUG_EXPOSURE

LOCATION

Not applicable

MEASUREMENT

For discussion

measurement_datetime >= visit_start_datetime measurement_datetime <= visit_end_datetime measurement_datetime >= birth_datetime measurement_datetime <= death_datetime

OBSERVATION

For discussion

observation_datetime >= visit_start_datetime observation_datetime <= visit_end_datetime observation_datetime >= birth_datetime observation_datetime <= death_datetime

PERSON

For discussion

Do we need further checks on numbers in year, month and day

PROCEDURE_OCCURRENCE

For discussion

procedure_datetime >= visit_start_datetime procedure_datetime <= visit_end_datetime procedure_datetime <= death_datetime

PROVIDER

Not applicable

SPECIMEN

For discussion

specimen_datetime >= visit_start_datetime specimen_datetime <= visit_end_datetime specimen_datetime >= birth_datetime specimen_datetime <= death_datetime

VISIT_DETAIL

For discussion

VISIT_OCCURRENCE

For discussion