OHDSI / dbt-synthea

[Under development] A dbt ETL project to convert a Synthea synthetic data set into the OMOP CDM
Apache License 2.0
7 stars 1 forks source link

Move date typecasts into stg models #40

Open katy-sadowski opened 2 weeks ago

katy-sadowski commented 2 weeks ago

There are repeated typecasts of timestamp-->date in the OMOP models. To DRY up the code we can move these into the original stg models by creating a _date column in those models and carrying it through to the final models.

For example: https://github.com/OHDSI/dbt-synthea/blob/236f52ab1f651e418eab6978d6a9bb92754ad682/models/omop/drug_exposure.sql#L11