From 52d12a9c6214e6fe7de5333e2d481c62aa1be276 Mon Sep 17 00:00:00 2001 From: Piotr Gawron <piotr.gawron@uni.lu> Date: Mon, 23 Jul 2018 17:16:34 +0200 Subject: [PATCH] remove duplicate reaction ids --- persist/src/db/12.0.1/fix_db_20180723.sql | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 persist/src/db/12.0.1/fix_db_20180723.sql diff --git a/persist/src/db/12.0.1/fix_db_20180723.sql b/persist/src/db/12.0.1/fix_db_20180723.sql new file mode 100644 index 0000000000..d4a1bab394 --- /dev/null +++ b/persist/src/db/12.0.1/fix_db_20180723.sql @@ -0,0 +1,2 @@ +-- issue #461 - duplicates in reaction ids resolved +update reaction_table r set idreaction=concat(r.idreaction,'_',r.iddb) from (select idreaction, model_iddb from reaction_table group by idreaction, model_iddb having count(*)>1) t where r.idreaction=t.idreaction and r.model_iddb=t.model_iddb; -- GitLab