mysql
hello_小宇
开发
展开
-
2020-12-15
原创 2020-12-15 22:01:41 · 143 阅读 · 0 评论 -
mysql分数占百分比查询
select count(1) as 排名 from 表名 where 分数字段 >= (select 分数字段 from 表名 where 姓名字段 = '用户名')微擎写法$uscore = pdo_fetch("SELECT score FROM ".tablename('game_list')." WHERE open_id = :open_id LIMIT 1", a原创 2017-05-19 19:14:53 · 7536 阅读 · 0 评论 -
分数排行榜数据库写法
select name,score,round from (select * from sqlTest order by score desc) as tab group by name having round= 1 order by score desc,name;转载 2017-05-22 15:00:27 · 803 阅读 · 0 评论