3

I used the following query: https://api.fda.gov/device/event.json?search=date_received:[20130101+TO+20141231]+AND+device.device_report_product_code=LLZ+AND+adverse_event_flag=Y&limit=1

In the query, adverse_event_flag field was specified as Y. However, the result I got is report number 3363982 with adverse_event_flag=N. Could anyone help me figure out whether my query is wrong?

3

The problem was a minor one with query syntax: You're using equals signs = when you should be using colons :.

For example, adverse_event_flag=Y should be adverse_event_flag:Y.

The new query returns only 23 results instead of about 1300.

The openFDA API basics page has information about the correct syntax for these queries.

Your Answer

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

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