Yahoo Query Language: Difference between revisions

Content deleted Content added
m Examples: <source lang="sql">
m Task 70: Update syntaxhighlight tags - remove use of deprecated <source> tags
Line 6:
==Examples==
Filter RSS feeds
<sourcesyntaxhighlight lang="sql">select title, link from rss where url = 'https://www.engadget.com/rss.xml')</sourcesyntaxhighlight>
 
Convert CSV to JSON or XML
<sourcesyntaxhighlight lang="sql">select * from csv where url='http://download.finance.yahoo.com/d/quotes.csv?s=YHOO,GOOG,AAPL&f=sl1d1t1c1ohgv&e=.csv' and columns='symbol,price,date,time,change,col1,high,low,col2'</sourcesyntaxhighlight>
 
Extract HTML via CSS Selectors
<sourcesyntaxhighlight lang="sql">SELECT * FROM data.html.cssselect WHERE url='http://www.w3.org/' AND css='ul.theme'</sourcesyntaxhighlight>
 
Get AppLinks meta data
<sourcesyntaxhighlight lang="sql">SELECT * from applinks WHERE url IN ('movietickets.com', 'pinterest.com')</sourcesyntaxhighlight>
 
Parse any XML source
<sourcesyntaxhighlight lang="sql">select Status.presence from xml where url = 'http://mystatus.skype.com/pjjdonnelly.xml' and Status.presence.lang = 'en'</sourcesyntaxhighlight>
 
==Rate limits==