diff --git a/rmd/sqlScripts.Rmd b/rmd/sqlScripts.Rmd index 32a51d1..929c86c 100644 --- a/rmd/sqlScripts.Rmd +++ b/rmd/sqlScripts.Rmd @@ -290,7 +290,8 @@ FROM @TARGET_CDMV5_SCHEMA.DRUG_EXPOSURE d INNER JOIN @TARGET_CDMV5_SCHEMA.CONCEPT_ANCESTOR ca ON ca.DESCENDANT_CONCEPT_ID = d.DRUG_CONCEPT_ID INNER JOIN @TARGET_CDMV5_SCHEMA.CONCEPT c ON ca.ANCESTOR_CONCEPT_ID = c.CONCEPT_ID WHERE c.DOMAIN_ID = 'Drug' - AND c.CONCEPT_CLASS_ID = 'Ingredient'; + AND c.CONCEPT_CLASS_ID = 'Ingredient' + AND c.STANDARD_CONCEPT = 'S'; /* / */