我正在编写一个应用程序,其中我正在使用Hackbook 示例代码获取 Facebook好友列表,但现在我想获取当前月份生日的 Facebook 好友列表,以获取我正在使用此代码的所有好友列表:
public static void requestFriends(FacebookRequest facebookRequest) {
Log.d(LOG_TAG, "requestFriends(" + ")");
String query = "select name, birthday, uid, pic_square from user where uid in (select uid2 from friend where uid1=me()) order by birthday_date";
Bundle params = new Bundle();
params.putString("method", "fql.query");
params.putString("query", query);
FacebookUtility.asyncRunner.request(null, params, new FacebookRequestListener(FacebookRequestListener.FRIENDS, facebookRequest));
}
我仍然使用下面的代码来获取当月生日的朋友列表:
Calendar c = Calendar.getInstance();
int month = c.get(Calendar.MONTH)+ 1;
String query = "select name, birthday, uid, pic_square from user where uid in " +
"(select uid2 from friend where uid1=me())AND birthday_date >= '" + month + "/01' AND birthday_date <= '" + month + "/31' ORDER BY birthday_date ASC";
但我没有得到任何记录,我在哪里失踪?