summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorDavid Baker <dave@matrix.org>2018-10-30 09:51:04 +0000
committerDavid Baker <dave@matrix.org>2018-10-30 09:51:04 +0000
commit64fa557f80edc99318aa6152c3b84c76dd455c8a (patch)
tree8a2f791f1e56959fa9ab4b189639d14bd2430d84 /synapse/storage
parentMake e2e backup versions numeric in the DB (diff)
downloadsynapse-64fa557f80edc99318aa6152c3b84c76dd455c8a.tar.xz
Try & make it work on postgres
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/schema/delta/52/e2e_room_keys.sql4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/schema/delta/52/e2e_room_keys.sql b/synapse/storage/schema/delta/52/e2e_room_keys.sql
index 754985187e..db687cccae 100644
--- a/synapse/storage/schema/delta/52/e2e_room_keys.sql
+++ b/synapse/storage/schema/delta/52/e2e_room_keys.sql
@@ -24,7 +24,7 @@ CREATE TABLE e2e_room_keys_versions_new (
 );
 
 INSERT INTO e2e_room_keys_versions_new
-    SELECT user_id, version, algorithm, auth_data, deleted FROM e2e_room_keys_versions;
+    SELECT user_id, CAST(version as BIGINT), algorithm, auth_data, deleted FROM e2e_room_keys_versions;
 
 DROP TABLE e2e_room_keys_versions;
 ALTER TABLE e2e_room_keys_versions_new RENAME TO e2e_room_keys_versions;
@@ -45,7 +45,7 @@ CREATE TABLE e2e_room_keys_new (
 );
 
 INSERT INTO e2e_room_keys_new
-    SELECT user_id, room_id, session_id, version, first_message_index, forwarded_count, is_verified, session_data FROM e2e_room_keys;
+    SELECT user_id, room_id, session_id, CAST(version as BIGINT), first_message_index, forwarded_count, is_verified, session_data FROM e2e_room_keys;
 
 DROP TABLE e2e_room_keys;
 ALTER TABLE e2e_room_keys_new RENAME TO e2e_room_keys;