我怎样才能获取php中的下一个等级?

时间:2015-06-08 02:53:38

标签: php mysql

我无法获得正确的查询以选择下一个排名。

以下是我的查询:

$query2  = "SELECT implement_id, total_implement, percent, FIND_IN_SET( percent, (
SELECT GROUP_CONCAT( percent
ORDER BY percent DESC ) 
FROM goal_implement )
) AS rank 
FROM goal_implement WHERE percent > (SELECT percent from goal_implement LIMIT 1)
ORDER BY percent ASC LIMIT 1
";

0 个答案:

没有答案