Powergamers and achievements

(powergamers not working properly yet)
I need help with the "ORDER BY"
````
$znotePlayers = mysql_select_multi('SELECT * FROM `players` `a` JOIN `znote_players` `b` ON `a`.`id` = `b`.`id`  WHERE `a`.`group_id` < 2 ORDER BY `a`.`experience`-`b`.`exphist_lastexp` DESC LIMIT ' . $limit);
````
Currently it doesn't subtract the 'experience' from 'exphist_lastexp'
$znotePlayers = mysql_select_multi('SELECT `a`.`id`, `b`.`player_id`, `a`.`name`, `a`.`vocation`, `a`.`level`, `a`.`group_id`, `a`.`experience`, `b`.`exphist_lastexp`, `b`.`exphist1`, `b`.`exphist2`, `b`.`exphist3`, `b`.`exphist4`, `b`.`exphist5`, `b`.`exphist6`, `b`.`exphist7`, (`a`.`experience` - `b`.`exphist_lastexp`) AS `expdiff` FROM `players` `a` JOIN `znote_players` `b` ON `a`.`id` = `b`.`player_id`  WHERE `a`.`group_id` < 2 ORDER BY `exphist' . (int) $type . '` DESC LIMIT '.$limit);
Add a line note