adsabs / object_service

ADS micro service for processing object and positional ("cone") searches (specifically SIMBAD and NED)
MIT License
5 stars 4 forks source link

topn query problem - trailing comma #103

Open ehenneken opened 4 years ago

ehenneken commented 4 years ago

The query

topn(5, object:M67, "date desc")

does not return any results. This is because there is no space between object:M67 and the comma that follows it. The query works when you add a space. Without the space, the object_service translates the query into

topn(5, ((=abs:M67, OR simbid:0 OR nedid:0) database:astronomy) "date desc")

which does not work because of =abs:M67,. With a space it becomes

{"query": "topn(5, ((=abs:M67 OR simbid:1136125 OR nedid:MESSIER_067) database:astronomy) , \"date desc\")"}