从 APP 查询时 FQL 返回不同的结果

发布于 2024-12-24 19:28:28 字数 1333 浏览 0 评论 0 原文

我有一个进程定期为给定用户抓取流表,导入任何新评论或帖子。当我使用 facebooks fql.query 链接测试我的查询时,会列出正确的结果。例如:

SELECT post_id、app_id、actor_id、created_time、updated_time、消息、评论、app_data、喜欢、附件、永久链接 FROM 流 WHERE source_id = "652904096" ORDER BY Updated_time DESC LIMIT 0, 20

https://api.facebook.com/method/fql.query?query=SELECT%20post_id,%20app_id,%20actor_id,%20created_time,%20updated_time,%20message,%20comments,%20app_data,% 20 个赞,%20 个附件, %20permalink%20FROM%20stream%20WHERE%20source_id=652904096%20ORDER%20BY%20updated_time%20DESC%20LIMIT%200,%2020&access_token=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

第一个结果来自今天早些时候。

但是,当我使用我的应用程序和 php sdk,使用相同的查询和访问令牌时,第一个结果来自 12 月 23 日

以下是我从我的应用程序调用查询的方式

$result = $fb->api(array(
    "method"=>"fql.query",
     "query"=>$query,
     "access_token"=>$oauth_token
 ));

有谁知道为什么会发生这种情况?我已向 PHP SDK 添加了调试语句,以确认查询和访问令牌相同。

I have a process which scrapes the stream table periodically for given users, importing any new comments or posts which have come in. When I test my query using the facebooks fql.query link, the correct results are listed. For example:

SELECT post_id, app_id, actor_id, created_time, updated_time, message, comments, app_data, likes, attachment, permalink FROM stream WHERE source_id = "652904096" ORDER BY updated_time DESC LIMIT 0, 20

https://api.facebook.com/method/fql.query?query=SELECT%20post_id,%20app_id,%20actor_id,%20created_time,%20updated_time,%20message,%20comments,%20app_data,%20likes,%20attachment,%20permalink%20FROM%20stream%20WHERE%20source_id=652904096%20ORDER%20BY%20updated_time%20DESC%20LIMIT%200,%2020&access_token=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

The first result is from earlier today.

But when I use my app and the php sdk, with the same query and access token, the first result is from December 23rd

Here is how I am calling the query from my App

$result = $fb->api(array(
    "method"=>"fql.query",
     "query"=>$query,
     "access_token"=>$oauth_token
 ));

Does anyone have any idea why this could be occurring? I have added debug statements to the PHP SDK to confirm that the query and access tokens are the same.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

善良天后 2024-12-31 19:28:28

如果查询 &访问令牌是相同的,您正在使用的 API 中发生了一些缓存。您尝试过使用 Javascript SDK 吗?您可以在 https://developers.facebook.com/tools/console/

If both the query & the access tokens are the same, there's some caching happening in the API you're using. Have you tried using the Javascript SDK? You can give it a quick test at https://developers.facebook.com/tools/console/.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文