質問

Facebook FQL query returns no results for languages field if there is a clause specifying languages id or name. If there is no WHERE clause for languages then all fields are returned.

SELECT uid,name,languages.name FROM user WHERE uid IN (SELECT uid2 FROM friend WHERE uid1 = me()) AND (strpos(lower(languages.name), lower("English")) >= 0)

See the following link for an example:

https://developers.facebook.com/tools/explorer?fql=SELECT%20uid%2Cname%2Clanguages.name%20FROM%20user%20WHERE%20uid%20IN%20(SELECT%20uid2%20FROM%20friend%20WHERE%20uid1%20%3D%20me())%20AND%20(strpos(lower(languages.name)%2C%20lower(%22English%22))%20%3E%3D%200)%20

I have had no problems with other fields or FQL queries. All permissions are requested for authorization token.

役に立ちましたか?

解決

Apparently you can't "filter" on fields containing array, filtering on fields containing objects works as you sketched out. I don't think this is documented in the Facbook API docs.

See my answer here as well: FQL Query for facebook

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top