smart-on-fhir / cumulus-library-data-metrics

A data metrics study for the Cumulus project
https://docs.smarthealthit.org/cumulus/
Apache License 2.0
2 stars 0 forks source link

feat!: rejigger resource/stratifier info for non-cubed tables #47

Closed mikix closed 4 months ago

mikix commented 4 months ago

For never-cubed tables (resources_per_pt and all quality summaries), we were previously sticking a not-very-human-friendly identifier like observation_valuecodeableconcept in the first column, named "id".

Now, we always name the first column "resource", add a second column with the specific metric's stratifier, and use better casing.

id: observation_valuecodeableconcept -> becomes -> resource: Observation field: valueCodeableConcept

All such tables now have two columns, even if a stratifier isn't used. In which case, we call the second column "stratifier" and leave it as all NULL.