select username,(select count(noteid) from Note where userid=User.userid group by userid)d from User

解决方案 »

  1.   

    select username,(select count(noteid) from Note where userid=User.userid ) d from User
      

  2.   


    错误
    SQL 查询: SHOW KEYS FROMMySQL 返回:#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
      

  3.   

    select username,(select count(noteid) from Note where userid=User.userid ) as d from User