0
select name, birthday 
from user 
where uid in (SELECT uid2 FROM friend WHERE uid1 = me()) 
    and birthday != null;

結果は

{
  "error": {
    "message": "(#602) NULL is not a member of the user table.", 
    "type": "OAuthException", 
    "code": 602
  }
}

どうにかして null 値を除外できますか?

4

2 に答える 2

0

str* 関数を使用する必要はありません...単に 'where field ' を使用して null 値を除外するか、'where not field ' を使用して非 null 値を除外します。この特定の例では:

誕生日とuidが入っているユーザーから名前、誕生日を選択します (SELECT uid2 FROM friend WHERE uid1 = me())

于 2013-12-18T08:04:44.187 に答える
0

これにより、その年の月に共通の文字を取得するために機能するすべてのヌルが取り出されます

SELECT name, birthday, email, uid FROM user WHERE uid in (SELECT uid2 FROM friend WHERE uid1 = me()) AND (strpos(lower(birthday),"a") >=0 OR strpos(lower(birthday),"e") >=0 OR strpos(lower(birthday),"u") >=0) ORDER BY birthday_date

于 2013-06-12T21:09:37.217 に答える