ncats / bard

Sources for the BioAssay Research Database
Other
10 stars 2 forks source link

Some Substance resource filters do not return results #28

Open jasiedu opened 11 years ago

jasiedu commented 11 years ago

The following URLS seems takes a long time to return:

http://bard.nih.gov/api/latest/substances?skip=0&top=10&expand=true&filter=MLSMR[dep_regid]

http://bard.nih.gov/api/latest/substances?skip=0&top=10&expand=true&filter=MLSMR[substance_url]

The filter with the source_name seems to work though

caodac commented 11 years ago

This is because these fields aren't being indexed whereas source_name does. The indices are being generated now, so it should work once they're finished.

jasiedu commented 11 years ago

Has this been resolved yet? I clicked on the links and its been 5 minutes and still no results.

caodac commented 11 years ago

The indices have been created but because the way the filter code is implemented (using wildcard % appended to the value), it has rendered the indexing useless. If we take the wildcard character out, then the input string has to be exact for it to match properly. Another route is to use lucene/solr for this.