这个表,我想查询出来左边是从大到小排列 右边是排名。
我这么写的语句为什么不对啊,
select score,(select count(*) from (select distinct score from scores group by score order by score desc) as s2 where s1.score >= s2.score) as rank from (select distinct score from scores order by score desc) as s1
这是报错:
pardon110