View
3.180
Download
0
Category
Preview:
DESCRIPTION
Citation preview
Erik EldridgeSlideshare.net/erikeldridge
Yahoo!Kimo Introduction to the Yahoo! Query Language
Presentation structure
• Yahoo! Query Language (YQL) overview
• The YQL Console
• YQL Open Tables
• Examples of YQL usage
YQL = Yahoo! Query Language
• SQL-like syntax- SELECT {fields} from {table} WHERE {key} = {value}- SELECT * FROM flickr.photos.search WHERE text=" 臺北 101”- SELECT * FROM html where url=“http://www.wretch.cc/”- SELECT * FROM flickr.photos.search WHERE has_geo="true" and woe_id in
(SELECT woeid FROM geo.places WHERE text="taipei" LIMIT 1)
• Extensible access to APIs/data
• SELECT * FROM Internet
Presentation structure
• Yahoo! Query Language (YQL) overview
• The YQL Console
• YQL Open Tables
• Examples of YQL usage
The YQL statement to run
The YQL statement to run
Yahoo! starts us off w/ several pre-defined “tables”
Predefined YQL data tables
XML response from a public data requestPublic URLs do not require OAuth Raw XML output
Presentation structure
• Yahoo! Query Language (YQL) overview
• The YQL Console
• YQL Open Tables
• Examples of YQL usage
Anyone can create a table for yql. Seeing the community tables in the console
Now showing community tablesPulli
ng table
def
s fro
m d
atat
able
s.org
Anatomy of a simple table showing table url, base api endpoint, and input definitions
Tables can be very simple
Input d
efin
ition
Native YQL query
E4X
Using a custom table in the console
Specifying table w/ “use”
Transcript HTML output
All community tables in the console are open source and available in githubDefault behavior of the Yahoo! Weather table
Comm
unity ta
bles
shown in
YQL c
onsole
Hack idea:Plurk table
Presentation structure
• Yahoo! Query Language (YQL) overview
• The YQL Console
• YQL Open Tables
• Examples of YQL usage
YQL is great for mobile apps (1 request to yql for the heavy lifting results in faster apps). This app finds the locations of nearby bars:
YQL is g
reat
for m
obile a
pps
Search Flickr photos by celestial location
select * from flickr.photos.astro …
Thank You!
• Resources:- delicious.com/erikeldridge/
taiwanhackday09+presentation+yql
• Follow me on Twitter: - Twitter.com/erikeldridge
• Get these slides on Slideshare:- Slideshare.net/erikeldridge
Hack Ideas
• Plurk tables
Recommended