diff --git a/mxqkill.c b/mxqkill.c index 26cb79bb..b790af81 100644 --- a/mxqkill.c +++ b/mxqkill.c @@ -130,13 +130,9 @@ static int update_job_status_cancelled_by_group(struct mx_mysql *mysql, struct m assert(g->group_id); stmt = mx_mysql_statement_prepare(mysql, - "UPDATE mxq_job SET" - " job_status = " status_str(MXQ_JOB_STATUS_CANCELLED) - " WHERE group_id = ?" - " AND job_status IN (" status_str(MXQ_JOB_STATUS_INQ) "," status_str(MXQ_JOB_STATUS_ASSIGNED) ")" - " AND host_hostname = ''" - " AND server_id = ''" - " AND host_pid = 0" + "UPDATE mxq_job SET job_cancelled = TRUE" + " WHERE group_id = ?" + " AND job_status = " status_str(MXQ_JOB_STATUS_INQ) ); if (!stmt) { mx_log_err("mx_mysql_statement_prepare(): %s", mx_mysql_error());