I am fairly new to the Facebook APIs. I want to get a list of my friends who have also installed my app. (The idea being you can then start a game with them).
This gives
This is I believe the FQL query
$facebook->api(array('method' => 'fql.query', 'query' => "SELECT uid FROM user WHERE is_app_user = '1' AND uid IN (SELECT uid2 FROM friend WHERE uid1 = '" . $user_id . "');"));
(I use java and JS APIs so the syntax may not be exactly correct)
The documentation for the user and friend queries are here:
http://developers.facebook.com/docs/reference/fql/user/
http://developers.facebook.com/docs/reference/fql/friend/