Yahoo Query Langauge

Wednesday, November 18th, 2009 at 11:29 am

Following on from a previous post on Yahoo Developer Tools I have been playing around with another clever Yahoo tool called Yahoo Query Language (you will need a yahoo account to access this page).

Recently I have been doing a lot of research on The Semantic Web (which I will be talking about in a future post), the idea that one day the whole of the web will be accessible as one large connected information cloud. While this tool is not Semantic web it is a good step in the right direction.

What is YQL?

Yahoo! Query Language (YQL) Web Service is a tool which enables you to access Internet data with SQL-like commands. The YQL Web Service enables applications to query, filter, and combine data from different sources across the Internet. YQL statements have a SQL-like syntax, familiar to any developer with database experience.

The following YQL statement, for example, retrieves a list of cat photos from Flickr:
SELECT * FROM flickr.photos.search WHERE text=”cat”

To access the YQL Web Service, a Web application can call HTTP GET, passing the YQL statement as a URL parameter, for example:
http://query.yahooapis.com/v1/public/yql?q=SELECT * FROM flickr.photos.search WHERE text=”Cat”

When it processes a query, the YQL Web Service accesses a datasource on the Internet, transforms the data, and returns the results in either XML or JSON format. YQL can access several types of datasources, including Yahoo! Web Services, other Web services, and Web content in formats such as HTML, XML, RSS, and Atom.

Open data tables

Yahoo provide a large list of open data tables that you can query covering the Yahoo services e.g. Flickr, maps, weather.

But the great thing is that you can create your own open data table from your web app that you can then make available to the community for other to query. I have had a quick look at the community tables and the ones that caught my eye are: Amazon, Craigslist, Delicious, Facebook, Instapaper, lastfm and Twitter to name just a few. That means you can use all the power of YQL to access all of these great services.

While I have not used YQL in a web app yet, I have played around with the service and so far I am very impressed. I have a use case for some of the tables in an upcoming project so I will let you know how I find it.

You can read the YQL documentation here.

Play with the YQL console here (requires a Yahoo login)


Related posts:
  1. Yahoo YQL Auto Tagger
  2. Which Is Best A Thin Or Fat Client?
  3. BWEA Wind Energy Conference

Tags: , ,

This entry was posted on Wednesday, November 18th, 2009 at 11:29 am and is filed under Naked CTO.
You can trackback from your own site.

Leave a Reply