diff options
| author | Sacheendra Talluri <sacheendra.t@gmail.com> | 2017-08-09 00:20:54 +0200 |
|---|---|---|
| committer | Sacheendra Talluri <sacheendra.t@gmail.com> | 2017-08-09 00:20:54 +0200 |
| commit | 777cb36dfb130af38fe095de6140b4a08883570d (patch) | |
| tree | 81f8c23f72a951a40e4644b664d950c6f2d7ea05 /opendc/models/room_state.py | |
| parent | 5d42f30ed30aa5b6970304569c6bd01c16078759 (diff) | |
Migrate to MariaDB
Diffstat (limited to 'opendc/models/room_state.py')
| -rw-r--r-- | opendc/models/room_state.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/opendc/models/room_state.py b/opendc/models/room_state.py index 7dd151e6..169aaa55 100644 --- a/opendc/models/room_state.py +++ b/opendc/models/room_state.py @@ -36,7 +36,7 @@ class RoomState(Model): JOIN machines ON racks.id = machines.rack_id JOIN machine_states ON machines.id = machine_states.machine_id WHERE objects.type = "RACK" - AND machine_states.experiment_id = ? + AND machine_states.experiment_id = %s GROUP BY machine_states.tick, rooms.id ''' results = database.fetchall(statement, (experiment_id,)) @@ -61,8 +61,8 @@ class RoomState(Model): JOIN machines ON racks.id = machines.rack_id JOIN machine_states ON machines.id = machine_states.machine_id WHERE objects.type = "RACK" - AND machine_states.experiment_id = ? - AND machine_states.tick = ? + AND machine_states.experiment_id = %s + AND machine_states.tick = %s GROUP BY rooms.id ''' results = database.fetchall(statement, (experiment_id, tick)) |
