Resolving issue where unit_concept_id was not mapped to the Measurement table properly

This commit is contained in:
Anthony Sena 2015-09-24 13:40:25 -04:00
parent 101c632072
commit 8badc57395
6 changed files with 437 additions and 504 deletions

View File

@ -1522,7 +1522,7 @@ FROM (
INNER JOIN #concept_map cm1 ON observation.observation_concept_id = cm1.source_concept_id
AND LOWER(cm1.domain_id) IN ('measurement')
LEFT JOIN #concept_map cm2 ON observation.unit_concept_id = cm2.source_concept_id
AND LOWER(cm1.domain_id) IN ('unit')
AND LOWER(cm2.domain_id) IN ('unit')
UNION ALL

View File

@ -1537,7 +1537,7 @@ FROM (
INNER JOIN concept_map cm1 ON observation.observation_concept_id = cm1.source_concept_id
AND LOWER(cm1.domain_id) IN ('measurement')
LEFT JOIN concept_map cm2 ON observation.unit_concept_id = cm2.source_concept_id
AND LOWER(cm1.domain_id) IN ('unit')
AND LOWER(cm2.domain_id) IN ('unit')
UNION ALL

View File

@ -1537,7 +1537,7 @@ FROM (
INNER JOIN concept_map cm1 ON observation.observation_concept_id = cm1.source_concept_id
AND LOWER(cm1.domain_id) IN ('measurement')
LEFT JOIN concept_map cm2 ON observation.unit_concept_id = cm2.source_concept_id
AND LOWER(cm1.domain_id) IN ('unit')
AND LOWER(cm2.domain_id) IN ('unit')
UNION ALL

View File

@ -1532,7 +1532,7 @@ FROM (
INNER JOIN #concept_map cm1 ON observation.observation_concept_id = cm1.source_concept_id
AND LOWER(cm1.domain_id) IN ('measurement')
LEFT JOIN #concept_map cm2 ON observation.unit_concept_id = cm2.source_concept_id
AND LOWER(cm1.domain_id) IN ('unit')
AND LOWER(cm2.domain_id) IN ('unit')
UNION ALL

View File

@ -1522,7 +1522,7 @@ FROM (
INNER JOIN #concept_map cm1 ON observation.observation_concept_id = cm1.source_concept_id
AND LOWER(cm1.domain_id) IN ('measurement')
LEFT JOIN #concept_map cm2 ON observation.unit_concept_id = cm2.source_concept_id
AND LOWER(cm1.domain_id) IN ('unit')
AND LOWER(cm2.domain_id) IN ('unit')
UNION ALL