2011-05-16 79 views

回答

1

可能是由

select count(*) from `thank` t join `movie` m on t.user=m.user 
    where m.user='<specific_usr>'; 

或者如果兩者都具有相同的字段,那麼爲什麼不乾脆用

select count(*) from `thank` where user='<specific_usr>'; 

,或者如果你想指望所有用戶然後嘗試:

select user,count(*) from `thank` group by user; 
1

SELECT COUNT(*) FROM thank WHERE user='specific user';