0

vimeo table returns results with no content

Hi,

Since 2 days i have been using the following request:

select * from vimeo.user.videos where username="user1282871"

via php.

now suddenly the the properties of the returned objects are empty eg. the field "id" of the video.

if i try the request in the console i get the correct results. but my php script stopped working.

whats wrong?

thanks
Chris

by
9 Replies
  • QUOTE (chrisp_pc @ Apr 20 2010, 08:07 AM) <{POST_SNAPBACK}>
    Hi,

    Since 2 days i have been using the following request:

    select * from vimeo.user.videos where username="user1282871"

    via php.

    now suddenly the the properties of the returned objects are empty eg. the field "id" of the video.

    if i try the request in the console i get the correct results. but my php script stopped working.

    whats wrong?

    thanks
    Chris


    Can you provide the URL you are sending from PHP to YQL? e.g. what YQL url are you using.

    For example, heres the URL to get the content back in a JSON callback:

    http://query.yahooapis.com/v1/public/yql?q...callback=cbfunc

    ...which seems to work for me.

    Jonathan
    0
  • Hi Chris,

    I tried your query and it seems to be working fine. Maybe it was an intermittent issue with the Vimeo API itself. Here's my result:


    CODE
        <results>
    <videos>
    <video>
    <id>11075582</id>
    <title>TestProjekt2</title>
    <description>Beschreibung Video1 TestProjekt2</description>
    <url>http://vimeo.com/11075582</url>
    <upload_date>2010-04-20 08:12:23</upload_date>
    <thumbnail_small>http://ts.vimeo.com.s3.amazonaws.com/598/689/59868933_100.jpg</thumbnail_small>
    <thumbnail_medium>http://ts.vimeo.com.s3.amazonaws.com/598/689/59868933_200.jpg</thumbnail_medium>
    <thumbnail_large>http://ts.vimeo.com.s3.amazonaws.com/598/689/59868933_640.jpg</thumbnail_large>
    <user_name>Christoph Pacher</user_name>
    <user_url>http://vimeo.com/user1282871</user_url>
    <user_portrait_small>http://images.vimeo.com/11/52/67/115267802/115267802_30.jpg</user_portrait_small>
    <user_portrait_medium>http://images.vimeo.com/11/52/67/115267802/115267802_75.jpg</user_portrait_medium>
    <user_portrait_large>http://images.vimeo.com/11/52/67/115267802/115267802_100.jpg</user_portrait_large>
    <user_portrait_huge>http://images.vimeo.com/11/52/67/115267802/115267802_300.jpg</user_portrait_huge>
    <stats_number_of_likes>0</stats_number_of_likes>
    <stats_number_of_plays>0</stats_number_of_plays>
    <stats_number_of_comments>0</stats_number_of_comments>
    <duration>57</duration>
    <width>640</width>
    <height>360</height>
    <tags>mediaTag-TestProjekt2</tags>
    </video>
    <video>
    <id>3164596</id>
    <title>Big Snowflakes in Vienna</title>
    <description>Sudden Snowflakeattack in Vienna</description>
    <url>http://vimeo.com/3164596</url>
    <upload_date>2009-02-10 15:56:13</upload_date>
    <thumbnail_small>http://ts.vimeo.com.s3.amazonaws.com/531/531373_100.jpg</thumbnail_small>
    <thumbnail_medium>http://ts.vimeo.com.s3.amazonaws.com/531/531373_200.jpg</thumbnail_medium>
    <thumbnail_large>http://ts.vimeo.com.s3.amazonaws.com/531/531373_640.jpg</thumbnail_large>
    <user_name>Christoph Pacher</user_name>
    <user_url>http://vimeo.com/user1282871</user_url>
    <user_portrait_small>http://images.vimeo.com/11/52/67/115267802/115267802_30.jpg</user_portrait_small>
    <user_portrait_medium>http://images.vimeo.com/11/52/67/115267802/115267802_75.jpg</user_portrait_medium>
    <user_portrait_large>http://images.vimeo.com/11/52/67/115267802/115267802_100.jpg</user_portrait_large>
    <user_portrait_huge>http://images.vimeo.com/11/52/67/115267802/115267802_300.jpg</user_portrait_huge>
    <stats_number_of_likes>0</stats_number_of_likes>
    <stats_number_of_plays>11</stats_number_of_plays>
    <stats_number_of_comments>0</stats_number_of_comments>
    <duration>25</duration>
    <width>504</width>
    <height>404</height>
    <tags>Snow Flake Vienna, mediaTag-TestProjekt1</tags>
    </video>
    </videos>
    </results>


    If you are still getting bad results, copy the XML here to take a look at.
    0
  • sorry my fault.

    i changed the contents of my vimeo account (added a second video), which caused a change in data structures in the query result.

    debugging in php on a live server is quite frustrating... :r
    0
  • why does the following query not return any results?

    select id from vimeo.user.videos where username="user1282871"


    thanks

    chris
    0
  • QUOTE (chrisp_pc @ Apr 21 2010, 01:02 AM) <{POST_SNAPBACK}>
    why does the following query not return any results?

    select id from vimeo.user.videos where username="user1282871"


    thanks

    chris


    The vimeo table is unfortunately not really returning the "list" of results but one single "videos" result with the items inside. Your "project" part (id) doesnt match anything at that level of the returned results, so YQL correctly gives you nothing.

    select video.id from vimeo.user.videos where username="user1282871"

    Is closer to what I think you want.

    Jonathan
    0
  • QUOTE (Jonathan @ Apr 23 2010, 09:37 AM) <{POST_SNAPBACK}>
    The vimeo table is unfortunately not really returning the "list" of results but one single "videos" result with the items inside. Your "project" part (id) doesnt match anything at that level of the returned results, so YQL correctly gives you nothing.

    select video.id from vimeo.user.videos where username="user1282871"

    Is closer to what I think you want.

    Jonathan


    is it possible to get several parts of the videos Object?

    eg:
    select video.id video.description from vimeo.user.videos where username="user1282871";

    but this query does not work.

    thanks
    Chris
    0
  • QUOTE (chrisp_pc @ Apr 24 2010, 01:01 AM) <{POST_SNAPBACK}>
    is it possible to get several parts of the videos Object?

    eg:
    select video.id video.description from vimeo.user.videos where username="user1282871";

    but this query does not work.

    thanks
    Chris



    Sorry my fault

    select video.id, video.description from vimeo.user.videos where username="user1282871";

    does the job
    0
  • now what is the problem again...? the whole vimeo table is gone... any ideas?
    0
  • QUOTE (Christoph @ Oct 27 2010, 01:22 AM) <{POST_SNAPBACK}>
    now what is the problem again...? the whole vimeo table is gone... any ideas?


    well sorry it is not. just the console does not list the opendata tables anymore by clicking on the community tables link.
    0

Recent Posts

in YQL