Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: a35ce99d19
Fetching contributors…

Cannot retrieve contributors at this time

100 lines (94 sloc) 4.948 kb
<?xml version="1.0" encoding="UTF-8"?>
<table xmlns="http://query.yahooapis.com/v1/schema/table.xsd">
<meta>
<author>Erik Eldridge</author>
<description>
</description>
<sampleQuery></sampleQuery>
</meta>
<bindings>
<select produces="XML">
<inputs></inputs>
<execute><![CDATA[
response.object = function () {
//fetch 'files'
var query = 'select * from yql.storage where name="store://FOUBAHrTP9vFVB2k8E2jEE"',
results = y.xmlToJson(y.query(query).results);
//for each file in files
var xml = <D:multistatus xmlns:D="DAV:"/>;
xml.appendChild(<D:response xmlns:D="DAV:" xmlns:lp1="DAV:" xmlns:lp2="http://apache.org/dav/props/">
<D:href>/webdav/</D:href>
<D:propstat>
<D:prop>
<lp1:resourcetype>
<D:collection/>
</lp1:resourcetype>
<lp1:creationdate>2010-01-02T19:43:01Z</lp1:creationdate>
<lp1:getlastmodified>Sat, 02 Jan 2010 19:43:01 GMT</lp1:getlastmodified>
<lp1:getetag>"19013d-1000-b2283b40"</lp1:getetag>
<D:supportedlock>
<D:lockentry>
<D:lockscope>
<D:exclusive/>
</D:lockscope>
<D:locktype>
<D:write/>
</D:locktype>
</D:lockentry>
<D:lockentry>
<D:lockscope>
<D:shared/>
</D:lockscope>
<D:locktype>
<D:write/>
</D:locktype>
</D:lockentry>
</D:supportedlock>
<D:lockdiscovery/>
<D:getcontenttype>httpd/unix-directory</D:getcontenttype>
</D:prop>
<D:status>HTTP/1.1 200 OK</D:status>
</D:propstat>
</D:response>);
for (var file in results.results.result.value) {
xml.appendChild(<D:response xmlns:D="DAV:" xmlns:lp1="DAV:" xmlns:lp2="http://apache.org/dav/props/">
<D:href>/webdav/{file}</D:href>
<D:propstat>
<D:prop>
<lp1:resourcetype/>
<lp1:creationdate>2010-01-02T19:43:01Z</lp1:creationdate>
<lp1:getcontentlength>0</lp1:getcontentlength>
<lp1:getlastmodified>Sat, 02 Jan 2010 19:43:01 GMT</lp1:getlastmodified>
<lp1:getetag>"19013f-0-b2283b40"</lp1:getetag>
<lp2:executable>F</lp2:executable>
<D:supportedlock>
<D:lockentry>
<D:lockscope>
<D:exclusive/>
</D:lockscope>
<D:locktype>
<D:write/>
</D:locktype>
</D:lockentry>
<D:lockentry>
<D:lockscope>
<D:shared/>
</D:lockscope>
<D:locktype>
<D:write/>
</D:locktype>
</D:lockentry>
</D:supportedlock>
<D:lockdiscovery/>
<D:getcontenttype>text/plain</D:getcontenttype>
</D:prop>
<D:status>HTTP/1.1 200 OK</D:status>
</D:propstat>
</D:response>);
}
return xml;
}();
]]></execute>
</select>
</bindings>
</table>
Jump to Line
Something went wrong with that request. Please try again.