// Show how many unsent results are committed to each HR class
// TODO: convert to use new DB interface
// TODO: document in the wiki
include_once("../inc/db.inc");
include_once("../inc/util.inc");
include_once("../inc/db_ops.inc");
include_once("../inc/util_ops.inc");
include_once("../inc/prefs.inc");
$system_string[128]="No OS";
$system_string[256]="Linux";
$system_string[384]="Windows";
$system_string[512]="Darwin";
$system_string[640]="FreeBSD";
$cpu_string[0]="Unspecified";
$cpu_string[1]="No cpu";
$cpu_string[2]="Intel";
$cpu_string[3]="AMD";
$cpu_string[4]="Macintosh";
$cpu_string[5]="AMD Athlon";
$cpu_string[6]="AMD Duron";
$cpu_string[7]="AMD Sempron";
$cpu_string[8]="AMD Opteron";
$cpu_string[9]="AMD Athlon 64";
$cpu_string[10]="AMD Athlon XP";
$cpu_string[11]="Intel Xeon";
$cpu_string[12]="Intel Celeron";
$cpu_string[13]="Intel Pentium";
$cpu_string[14]="Intel Pentium II";
$cpu_string[15]="Intel Pentium III";
$cpu_string[16]="Intel Pentium 4";
$cpu_string[17]="Intel Pentium D";
$cpu_string[18]="Intel Pentium M";
$cpu_string[19]="AMD Athlon MP";
$cpu_string[20]="AMD Turion";
$cpu_string[21]="Intel Core2";
$query="SELECT COUNT(workunit.id) AS count FROM workunit LEFT JOIN result ON workunit.id=result.workunitid WHERE result.server_state=2 AND workunit.hr_class=";