Search Yahoo API geo.places with like operator

大城市里の小女人 提交于 2019-12-24 23:17:41

问题


I want to use the Yahoo API with the geo.places table. It really works great with single queries, but I want to list all city names which names BEGIN with the query text.

This is my query URL right now:

http://query.yahooapis.com/v1/public/yql?q=select * from geo.places where text = 'dallas'

And this is what I want:

http://query.yahooapis.com/v1/public/yql?q=select * from geo.places where text LIKE 'dallas%'

Is it possible? If yes, how exactly?

I can't find any useful information in the docs about this type of query regarding the geo.places table :(

Thank you very much!


回答1:


I was able to perform a request that seems to fit what you are looking for:

http://query.yahooapis.com/v1/public/yql?q=select * from geo.places where text ='dallas*'


来源:https://stackoverflow.com/questions/24285720/search-yahoo-api-geo-places-with-like-operator

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!