我做了一个fql查询,返回有关单个url的详细信息。此时,我为网站上的每个页面创建了一个新查询 - 这显然效率不高。有没有办法创建一个返回所有页面及其详细信息的查询。 例如: 我现在得到的是什么:
<fql_query_response xmlns="http://api.facebook.com/1.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" list="true">
<link_stat>
<url>www.facebook.com</url>
<normalized_url>http://www.facebook.com/</normalized_url>
<share_count>50783153</share_count>
<like_count>2482551</like_count>
<comment_count>2371768</comment_count>
<total_count>55637472</total_count>
<commentsbox_count>0</commentsbox_count>
<comments_fbid>10150187081535131</comments_fbid>
<click_count>243646</click_count>
</link_stat>
</fql_query_response>
我需要什么:
<fql_query_response xmlns="http://api.facebook.com/1.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" list="true">
<link_stat>
<url>www.facebook.com</url>
<normalized_url>http://www.facebook.com/</normalized_url>
<share_count>50783153</share_count>
<like_count>2482551</like_count>
<comment_count>2371768</comment_count>
<total_count>55637472</total_count>
<commentsbox_count>0</commentsbox_count>
<comments_fbid>10150187081535131</comments_fbid>
<click_count>243646</click_count>
</link_stat>
<link_stat>
<url>www.yahoo.com</url>
<normalized_url>http://www.yahoo.com/</normalized_url>
<share_count>50783153</share_count>
<like_count>2482551</like_count>
<comment_count>2371768</comment_count>
<total_count>55637472</total_count>
<commentsbox_count>0</commentsbox_count>
<comments_fbid>10150187081535131</comments_fbid>
<click_count>243646</click_count>
</link_stat>
</fql_query_response>
答案 0 :(得分:0)
您应该尝试关闭此问题,使其标记为已解决。
回顾一下,你的IN()和你在域名字符串上引用时遇到了一些问题
IN('www.facebook.com, www.yahoo.com')
应该是
IN('www.facebook.com', 'www.yahoo.com')
http://api.facebook.com/method/fql.query?query=SELECT%20url,%20normalized_url,%20share_count,%20like_count,%20comment_count,%20total_count,%20commentsbox_count,%20comments_fbid,%20click_count%20FROM%20link_stat%20WHERE%20url%20IN( 'www.facebook.com',%20'www.yahoo.com')