Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Intermediate table from FDA NDC Class -> RxNorm ingredient #200

Open
jrlegrand opened this issue Jul 17, 2023 · 0 comments
Open

Intermediate table from FDA NDC Class -> RxNorm ingredient #200

jrlegrand opened this issue Jul 17, 2023 · 0 comments

Comments

@jrlegrand
Copy link
Member

jrlegrand commented Jul 17, 2023

Proposal

Something like this:

select distinct
	cls.class_type
	, trim(cls.class_name) as class_name
	, cpi.ingredient_rxcui
	, cpi.ingredient_name
	, cpi.ingredient_tty
from staging.stg_fda_ndc__class cls
left join staging.stg_fda_ndc__ndc ndc
	on cls.productid = ndc.productid
left join intermediate.int_rxnorm_clinical_products_to_ndcs ndccp
	on ndc.ndc11 = ndccp.ndc
left join intermediate.int_rxnorm_clinical_products_to_ingredients cpi
	on ndccp.clinical_product_rxcui = cpi.clinical_product_rxcui
where trim(cls.class_name) = 'Angiotensin-converting Enzyme Inhibitors'
	and cpi.ingredient_tty = 'IN'
order by cpi.ingredient_name asc

Rationale

If we could just use RxClass we wouldn't need to do this. In lieu of that, it might be useful to do this. As I was writing this, I was wondering how RxClass takes the class from DailyMed and converts it to the ingredient-level. Maybe in DailyMed it's at the ingredient level? In FDA, it's at the product-level which makes it hard to be certain that it's a class for ingredient A vs ingredient B... which is why I just limited this to single-ingredient products as you can see in the query above.

Additional Info

FDA Class -> NDC -> RxNorm NDC to clinical product -> RxNorm clinical product to ingredient [components?]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

1 participant