Skip to content

Commit

Permalink
Try rename
Browse files Browse the repository at this point in the history
  • Loading branch information
rowleya committed Oct 19, 2023
1 parent f853a62 commit 79c97c7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -809,7 +809,7 @@ public abstract class SQLQueries {
*/
@Parameter("change_id")
protected static final String ERROR_PENDING =
"UPDATE pending_changes SET error=1 WHERE change_id = :change_id";
"UPDATE pending_changes SET is_error=1 WHERE change_id = :change_id";

/**
* Get descriptions of how to move from a board to its neighbours.
Expand Down Expand Up @@ -862,7 +862,7 @@ public abstract class SQLQueries {
@ResultColumn("n_errors")
protected static final String COUNT_CHANGES_FOR_JOB =
"SELECT COUNT(change_id) as n_changes, "
+ "COALESCE(SUM(error), 0) as n_errors "
+ "COALESCE(SUM(is_error), 0) as n_errors "
+ "FROM pending_changes "
+ "WHERE job_id = :job_id AND from_state = :from_state "
+ "AND to_state = :to_state";
Expand Down
4 changes: 2 additions & 2 deletions SpiNNaker-allocserv/src/main/resources/spalloc-mysql.sql
Original file line number Diff line number Diff line change
Expand Up @@ -398,8 +398,8 @@ CREATE TABLE IF NOT EXISTS pending_changes (
CONSTRAINT pending_changes_fpga_nw CHECK (fpga_nw IN (0, 1)),
fpga_se INTEGER NOT NULL -- Whether to switch the southeast FPGA on
CONSTRAINT pending_changes_fpga_se CHECK (fpga_se IN (0, 1)),
error INTEGER NOT NULL DEFAULT (0)
CONSTRAINT pending_changes_error CHECK (error IN (0, 1)),
is_error INTEGER NOT NULL DEFAULT (0)
CONSTRAINT pending_changes_error CHECK (is_error IN (0, 1)),
from_state INTEGER NOT NULL DEFAULT (0),
FOREIGN KEY (from_state)
REFERENCES job_states(id) ON DELETE RESTRICT,
Expand Down

0 comments on commit 79c97c7

Please sign in to comment.