This query is used to count the drug type concepts (drug_type_concept_id) across all drug exposure records. The input to the query is a value (or a comma-separated list of values) of a drug_type_concept_id. If the input is omitted, all possible values are summarized.
The following is a sample run of the query. The input parameters are highlighted in blue
SELECT
drug_type_concept_id AS drug_type_concept_id,
count(*) AS exposure_occurrence_count
FROM @cdm.drug_exposure
WHERE
drug_concept_id IN (SELECT DISTINCT drug_concept_id FROM @cdm.drug_era)
AND drug_type_concept_id IN (38000175, 38000180, 43542356)
GROUP BY drug_type_concept_id
;
| Parameter | Example | Mandatory | Notes | | --- | --- | --- | --- | | list of drug_type_concept_id | 38000175, 38000180 | Yes |
| Field | Description | | --- | --- | | drug_type_concept_id | A foreign key to the predefined concept identifier in the vocabulary reflecting the type of drug exposure recorded. It indicates how the drug exposure was represented in the source data: as medication history, filled prescriptions, etc. | | exposure_occurrence_count | The number of individual drug exposure occurrences used to construct the drug era. |
| Field | Sample | | --- | --- | | drug_type_concept_id | 43542356 (Physician administered drug) | | exposure_occurrence_count | 34583 |
https://github.com/OHDSI/CommonDataModel/wiki/drug_era
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.