It looks like you can use
SELECT * FROM xml WHERE url="http://api.flickr.com/services/rest/?method=flickr.photos.getSizes&api_key=41c85efb4676ea8060b400cdd8de3df4&photo_id=3271002434" and itemPath="rsp" and sizes.size.label='Medium'
So I think what he wants is this:
SELECT sizes.size FROM xml WHERE url="http://api.flickr.com/services/rest/?method=flickr.photos.getSizes&api_key=41c85efb4676ea8060b400cdd8de3df4&photo_id=3271002434" and itemPath="rsp" and sizes.size.label='Medium'
The issue is that * returns any matching element at the top level. The rsp element is the only one at the top level and it satisfies the filter as it contains a sizes.size.label element that is equal to Medium. If you *only* want the size element that matches then you need to project out that element and YQL magic will do the right thing.