This builds off my previous post. Suppose you’ve got content in YQL that you’d like to GET (ha!) out. The table is super simple.  Ok, this is really just an unexciting GET request to YQL, but it’s cool because we’re starting to think of YQL as a file store accessible via WebDAV methods.

Prerequisites

Flow

  1. You make a GET request to YQL w/ a query param path set the the value of one of your keys in the JSON object described above, eg path=‘file1’
  2. YQL retrieves the storage record, converts it to JSON, and returns the value associated w/ the path you sent

Code

[sourcecode lang=“xml”]

//fetch ‘files’ var query = ‘select * from yql.storage where name=“store://{select store id}”’, results = y.xmlToJson(y.query(query).results);

return results.results.result.value[path]; }(); ]]>

Notes