0

I'm rying to eventually populate a spreadsheet with only the dosage_and_administration section for like 2000 medications. I created a query for this:

https://api.fda.gov/drug/label.json?search=openfda.substance_name:acetaminophen+AND+exists:dosage_and_administration

However all the other headings show up every time and I can't focus the query on just dosage_and_administration section. Is this possible?

3
  • pinging @openfdateam opendata.stackexchange.com/users/19731/openfda-team
    – philshem
    Jul 15, 2018 at 11:09
  • 1
    As a picky detail, the data is in JSON format, which is more associated with JavaScript than Java. I'm guessing you need this info for many drugs and don't want to download unnecessary data? Otherwise, it seems fairly easy to programmatically clip out the section you need (even without knowing JavaScript)
    – user3856
    Jul 15, 2018 at 15:08
  • I used to program a bit in the passed, but unfortunately haven't kept up with it. If I could make it in a query format like the URL I gave above, it would fit nicely with excels query feature and I could populate my table as needed. I wouldn't even know where to start with making a javascript to only keep the section I need, and then have it export to excel. As it stands now I would have to do all this manually (which I'm really trying to avoid haha). I can definitely download the data if need be, its more just me not knowing what to do with it once its downloaded.
    – 4ntibody
    Jul 15, 2018 at 16:36

1 Answer 1

0

Unfortunately, we don't have a way to return only selected portions of JSON. Shouldn't be a problem though as long as you are processing the results programmatically -- just ignore the sections that are not relevant.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.