<?php
	#NOTE: minimum 100 deaths
	$query = "SELECT id,name,rank, kills/deaths as kdr,country FROM player WHERE time > 360000 AND deaths > 100 ORDER BY kdr DESC LIMIT 5";

$query2 = "SET @n:=0";
$query3 = str_replace("FROM", ", @n:=@n+1 as num FROM", $query);
$query3 = str_replace("LIMIT 5", "", $query3);
?>