5

RxNorm is a database of drugs put out by the U.S. National Library of Medicine. I've pulled the RxNorm data into a Postgres database using some of the supplied MySQL scripts and some code that I wrote myself.

I am able to find the list of all strengths for a given drug, like say "gabapentin". First I find the identifier for "gabapentin":

select * from rxnconso where str = 'gabapentin' and sab = 'RXNORM';

which gives:

rxcui | lat | ts | lui | stt | sui | ispref | rxaui  |  saui  | scui  | sdui |  sab   | tty | code  |    str     | srl | suppress | cvf  
-------+-----+----+-----+-----+-----+--------+--------+--------+-------+------+--------+-----+-------+------------+-----+----------+------
25480 | ENG |    |     |     |     |        | 417389 | 417389 | 25480 |      | RXNORM | IN  | 25480 | gabapentin |     | N        | 4096

From that I learn that the identifier for gabapentin is '25480'. And then I can get the strengths for '25480' like so:

select * from rxnsat where atn='RXN_STRENGTH' and rxcui in (select distinct(rxcui) from rxnconso where rxcui in (select rxcui1 from rxnrel where rxcui2 = '25480')) order by NULLIF(regexp_replace(atv, E'\\D', '', 'g'), '')::int;

which gives:

  rxcui  | lui | sui |  rxaui  | stype |  code   | atui | satui |     atn      |  sab   |   atv    | suppress | cvf  
---------+-----+-----+---------+-------+---------+------+-------+--------------+--------+----------+----------+------
 997844  |     |     | 3276700 | AUI   | 997844  |      |       | RXN_STRENGTH | RXNORM | 25 MG/ML | N        | 4096
 346365  |     |     | 1533281 | AUI   | 346365  |      |       | RXN_STRENGTH | RXNORM | 50 MG/ML | N        | 4096
 345817  |     |     | 2061711 | AUI   | 345817  |      |       | RXN_STRENGTH | RXNORM | 100 MG   | N        | 4096
 1482816 |     |     | 5937983 | AUI   | 1482816 |      |       | RXN_STRENGTH | RXNORM | 300 MG   | N        | 4096
 345818  |     |     | 2061712 | AUI   | 345818  |      |       | RXN_STRENGTH | RXNORM | 300 MG   | N        | 4096
 345819  |     |     | 2061713 | AUI   | 345819  |      |       | RXN_STRENGTH | RXNORM | 400 MG   | N        | 4096
 346145  |     |     | 1532840 | AUI   | 346145  |      |       | RXN_STRENGTH | RXNORM | 600 MG   | N        | 4096
 1101334 |     |     | 3641350 | AUI   | 1101334 |      |       | RXN_STRENGTH | RXNORM | 600 MG   | N        | 4096
 346146  |     |     | 1532842 | AUI   | 346146  |      |       | RXN_STRENGTH | RXNORM | 800 MG   | N        | 4096

That means gabapentin is available in strengths of 25mg/mL, 50mg/mL, 100mg, 300mg (2 different forms), 400mg, 600mg (2 different forms), and 800mg.

But how do I find out what forms correspond to those different strengths? For instance, some of them are capsules, some are tablets, and some are solutions.

(If you go to this RxTerms demo page, you can enter "Gabapentin" in the first "Drug Name" field, and then choose the autocomplete option "Gabapentin (Oral Pill)", and then click in the Strength field, and you will see that it lists things like "300 mg Cap", "300 mg Tab", etc. RxTerms pulls its data from RxNorm, so it should be similar to the results gotten from querying RxNorm appropriately.)

  • I'm still interested in an answer to this, but I noticed that RxTerms provides comparable information in a much simpler format. There's basically one table, with one row for each item, such as a particular brand of gabapentin in a 100 mg tablet. See wwwcf.nlm.nih.gov/umlslicense/rxtermApp/rxTerm.cfm – aem Mar 26 '15 at 21:19
  • 1
    it would be legitimate to post your comment as an answer. Self-answering is not considered a problem. – Joe Germuska Mar 27 '15 at 14:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.