开发者

Not able to pull more than 100 comments per post

We are trying to get the data from facebook. When trying to get all the comments using the fql query facebook is returning less than 100 comments per post.

Following is the fql query used.

SELE开发者_开发技巧CT text,id 
FROM comment 
WHERE post_id in (select post_id from stream where source_id=**** and actor_id = ****)

also tried

SELECT text,id FROM comment WHERE post_id = ****

Please help me solve the problem. Thanks in advance

note : both source_id and actor_id are same. and post_is mentioned has more than 100 comments (180) and is returning only 99 comments


Use fql query with limit. It will work.


Please note that fql is deprecated from graph api version 2.1 onwards

https://graph.facebook.com/v2.3/post-id?fields=comments&access_token=ACCESS_TOKEN gives you all the comments of that post with paging.

https://graph.facebook.com/v2.3/post-id?fields=comments.summary(true)&access_token=ACCESS_TOKEN will give you all the comments of that post with paging and also using "comments.summary(true)" gives you "summary" json object along with data and paging which gives you total comments count also.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜