1

I am grabbing friends' statuses using STREAM table and FQL. I want to get back ONLY one status per friend, but FQL doesn't support "normal" SQL operators like DISTINCT. Any ideas how to make such a distinct based on actor_id column?

my FQL:

"SELECT actor_id, message FROM stream WHERE filter_key in (SELECT filter_key FROM stream_filter WHERE uid=me() AND type=\'newsfeed\')"
4

1 回答 1

0

好吧,您不能在 FQL ( enables you to use a SQL-style interface to query the data exposed by the Graph API)中使用 distinct 关键字

你必须在你的应用程序中处理它。遍历您的结果并将每个结果friend_id作为键存储在关联数组中并存储值(基于时间戳)

于 2013-02-20T07:52:33.140 回答