对于我的Facebook帖子,我的朋友分享(不喜欢)我想得到谁分享它和什么时候.使用图形api,我可以获得相似或评论信息以及帖子共享的次数.我正在寻找的是图表api调用或Facebook fql查询共享,返回类似于此的结果集:
data": [
{
"id": "user_id_1",
"name": "Username 1",
"created": "some date"
},
{
"id": "user_id_2",
"name": "Username 2",
"created": "some other date"
}
]
Run Code Online (Sandbox Code Playgroud) 我试图雄辩地生成的查询是
SELECT *, (SELECT COUNT(comment_id) FROM comment AS c WHERE c.approved=true AND c.blog_fk=b.blog_id) AS comment_count FROM blog AS b
Run Code Online (Sandbox Code Playgroud)
这是结果
blog_id | title | author | blog | image | tags | created | updated | comment_count
--------|-------------------|--------------|----------------|------------------|---------|---------------------|---------------------|--------------
21 | A day.. | dsyph3r | Lorem ipsum... | beach.jpg | symf... | 2014-12-22 19:14:34 | 2014-12-22 19:14:34 | 2
22 | The pool .. | Zero Cool | Vestibulum ... | pool_leak.jpg | pool,.. | 2011-07-23 06:12:33 | 2011-07-23 06:12:33 …Run Code Online (Sandbox Code Playgroud)