gpt4 book ai didi

Facebook FQL 获取所有位置的帖子

转载 作者:行者123 更新时间:2023-12-04 19:52:35 24 4
gpt4 key购买 nike

location_post FQL table描述如下:

An FQL table that returns Posts that have locations associated with them and that satisfy at least one of the following conditions:

  • you were tagged in the Post

  • a friend was tagged in the Post

  • you authored the Post

  • a friend authored the Post

所以我编写了以下 FQL 脚本,目的是获取我和我的 friend 在特定位置发布的所有帖子:

SELECT id、message、post_id、timestamp FROM location_post WHERE page_id=303736809701751

但是,返回一个空数据集。在这种特殊情况下,我希望我自己的一些帖子会被返回,尽管我已经尝试过应该也返回 friend 帖子的其他地方 ID。

请求中缺少什么,或者这是我应该向 Facebook 报告的错误?

最佳答案

您从文档中引用的段落只是说该表包含您和您的 friend 去过的地方。它试图解释你不会在那里找到公共(public)用户。

location_post 表的查询不会自动为您指定相关 ID。如果您想搜索您的所有 friend 去过的地方,您必须指明所有您的 friend 。如果您只有一群 friend 感兴趣,只需添加相关 ID。

应该这样做。

SELECT id, message, post_id, timestamp
FROM location_post
WHERE (author_uid IN (SELECT uid2 FROM friend WHERE uid1 = me())
OR author_uid = me()
OR tagged_uids IN (SELECT uid2 FROM friend WHERE uid1 = me())
OR tagged_uids = me())
AND page_id = 303736809701751

关于Facebook FQL 获取所有位置的帖子,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17537158/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com