Results: Fix results_data delete.

This commit is contained in:
parouby committed 2025-10-30 16:14:41 +01:00
1 parent de7f3e63b1
commit ff9d25412c
1 file changed
+3 -2
+3 -2
View File
@@ -193,7 +193,8 @@ class Results(SQLSubModel):
f"AND solver_type = '{solver_type}'"
)
if len(old_pid) != 0:
old_pid = old_pid[0]
for pid in old_pid:
pid = pid[0]
execute(
"DELETE FROM results " +
@@ -203,7 +204,7 @@ class Results(SQLSubModel):
execute(
"DELETE FROM results_data " +
f"WHERE scenario = {self._owner_scenario} " +
f"AND results = '{old_pid}'"
f"AND result = {pid}"
)
def _db_save(self, execute, data=None):