$min_claimed_credit and claimed_credit < $max_claimed_credit and app_version_id<>0"; if ($appid) { $query .= " and result.appid = $appid"; } if ($limit) { $query .= " limit $limit"; } $r = $db->do_query($query); $f = fopen("credit_test_data", "w"); while ($x = mysql_fetch_object($r)) { fprintf($f, "$x->id $x->workunitid $x->appid $x->hostid $x->claimed_credit $x->app_version_id $x->elapsed_time $x->flops_estimate $x->cpu_time $x->rsc_fpops_est\n"); } fclose($f); ?>