Successfully reported this slideshow.

Yql And Its Hotness

1

Share

Loading in …3
×
1 of 44
1 of 44

Yql And Its Hotness

1

Share

Download to read offline

I gave a presentation to RORO in Sydney on 2009-02-17 about Yahoo! Query Language (YQL) and why I think it's hot. I wound up with a couple of demos including the new version of the GitHub Activity Badge and a Flickr slideshow site I built just for the presentation called StreamSlide.

I gave a presentation to RORO in Sydney on 2009-02-17 about Yahoo! Query Language (YQL) and why I think it's hot. I wound up with a couple of demos including the new version of the GitHub Activity Badge and a Flickr slideshow site I built just for the presentation called StreamSlide.

More Related Content

Related Books

Free with a 14 day trial from Scribd

See all

Yql And Its Hotness

  1. 1. YQL (and its hotness)
  2. 2. YQL is Yahoo! Query Language
  3. 3. Yahoo! calls it:
  4. 4. A “mediator service” that enables developers to query, filter, and combine data across Yahoo! and beyond.
  5. 5. I call it:
  6. 6. An API for the public internet.
  7. 7. I think my description is a bit more catchy.
  8. 8. YQL offers a SQL-like syntax.
  9. 9. SELECT * FROM search.web WHERE query=quot;rubyquot;
  10. 10. Look familiar?
  11. 11. SELECT what FROM table WHERE filter
  12. 12. Tables in YQL are much the same as tables in SQL.
  13. 13. SELECT * FROM search.web WHERE query=quot;rubyquot;
  14. 14. You can SELECT specific elements or objects.
  15. 15. SELECT title FROM search.web WHERE query=quot;rubyquot;
  16. 16. WHERE filters have lots of operators.
  17. 17. = =! > < <= >= IN LIKE IS NULL IS NOT NULL AND OR
  18. 18. Join tables with sub-selects using matching values as a foreign key.
  19. 19. What is a YQL table?
  20. 20. The defaults are mostly data sources for Yahoo's own data APIs.
  21. 21. Some for HTML, JSON, XML, RSS, ATOM, CSV, feeds and microformats.
  22. 22. Tables are defined in XML.
  23. 23. <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?> <table xmlns=quot;http://query.yahooapis.com/v1/schema/table.xsdquot;> <meta> <author>Paul Daniel</author> <documentationURL>http://apiwiki.twitter.com/REST+API +Documentation#show</documentationURL> </meta> <bindings> <select itemPath=quot;feed.entryquot; produces=quot;XMLquot;> <urls> <url>http://twitter.com/statuses/user_timeline/{id}.atom</url> </urls> <paging model=quot;pagequot;> <start default=quot;0quot; id=quot;pagequot;/> <pagesize max=quot;200quot; id=quot;countquot;/> <total default=quot;20quot;/> </paging> <inputs> <key id=quot;sincequot; type=quot;xs:stringquot; paramType=quot;queryquot; /> <key id=quot;since_idquot; type=quot;xs:stringquot; paramType=quot;queryquot; /> <key id=quot;idquot; type=quot;xs:stringquot; paramType=quot;pathquot; required=quot;truequot;/> </inputs> </select> </bindings> </table>
  24. 24. You can write your own.
  25. 25. And share them for others to use.
  26. 26. SHOW tables DESC table
  27. 27. What’s the output?
  28. 28. <?xml version=quot;1.0quot; encoding=quot;UTF-8quot;?> <query xmlns:yahoo=quot;http://www.yahooapis.com/v1/base.rngquot; yahoo:count=quot;10quot; yahoo:created=quot;2009-02-11T03:16:48Zquot; yahoo:lang=quot;en-USquot; yahoo:updated=quot;2009-02-11T03:16:48Zquot; yahoo:uri=quot;http:// query.yahooapis.com/v1/yql?q=SELECT+*+%0AFROM+search.web+WHERE+query%3D %22ruby%22quot;> <diagnostics> <publiclyCallable>true</publiclyCallable> <url execution-time=quot;116quot;>http://boss.yahooapis.com/ysearch/web/ v1/ruby?format=xml&amp;start=0&amp;count=10</url> <user-time>119</user-time> <service-time>116</service-time> <build-version>851</build-version> </diagnostics> <results> <result xmlns=quot;http://www.inktomi.com/quot;> <abstract><![CDATA[<b>Ruby</b> originated in Japan during the mid-1990s and was initially developed and <b>...</b> <b>Ruby</b> supports multiple programming paradigms, including functional, object <b>...</ b>]]></abstract> <clickurl>http://lrd.yahooapis.com/ _ylc=X3oDMTQ4NWxyYWUxBF9TAzIwMjMxNTI3MDIEYXBwaWQDb0pfTWdwbklrWW5CMWhTZnFUZ Ed5TkouTXNxZlNMQmkEcG9zAzEEc2VydmljZQNZU2VhcmNoV2ViBHNsawN0aXRsZQRzcmNwdml kA253RkNNVVBEQjJIMkxjVFRsQWt1ZVI0VXl6LkNJVW1TUXlBQUFLckk-/SIG=11tsuk1oo/ **http%3A//en.wikipedia.org/wiki/Ruby_(programming_language)</clickurl>
  29. 29. { quot;queryquot;: { quot;countquot;:quot;10quot;, quot;createdquot;:quot;2009-02-11T03:20:22Zquot;, quot;langquot;:quot;en-USquot;, quot;updatedquot;:quot;2009-02-11T03:20:22Zquot;, quot;uriquot;:quot;http://query.yahooapis.com/v1/yql? q=SELECT+*+%0AFROM+search.web+WHERE+query%3D %22ruby%22quot;, quot;diagnosticsquot;: { quot;publiclyCallablequot;:quot;truequot;, quot;urlquot;: { quot;execution-timequot;:quot;109quot;,
  30. 30. Specify callback with ‘callback’ for JSON-P.
  31. 31. call({ quot;queryquot;: { quot;countquot;:quot;10quot;, quot;createdquot;:quot;2009-02-11T03:20:22Zquot;, quot;langquot;:quot;en-USquot;, quot;updatedquot;:quot;2009-02-11T03:20:22Zquot;, quot;uriquot;:quot;http://query.yahooapis.com/v1/yql? q=SELECT+*+%0AFROM+search.web+WHERE+query%3D %22ruby%22quot;, quot;diagnosticsquot;: { quot;publiclyCallablequot;:quot;truequot;, quot;urlquot;: { quot;execution-timequot;:quot;109quot;,
  32. 32. http://query.yahooapis.com/v1/ public/yql?q=SELECT%20* %20%0AFROM%20search.web %20WHERE%20query%3D %22ruby%22 &format=json&callback=call
  33. 33. Where is all this?
  34. 34. http://developer.yahoo.com/ yql/
  35. 35. http://developer.yahoo.com/ yql/console
  36. 36. Examples
  37. 37. I converted the GitHub Activity Badge today.
  38. 38. Took me 5 minutes. http://github.com/ lachlanhardy/github- activity-badge/
  39. 39. Oh! And I built this...
  40. 40. http://streamslide.com http://github.com/ lachlanhardy/ streamslide/
  41. 41. Thank you
  42. 42. http://lachstock.com.au

×